Тёмный

Introduction to OpenFOAM programming - Lesson 4 - 8/27/2024 

Santiago Marquez Damian
Подписаться 342
Просмотров 482
50% 1

Writing a basic complete solver: myVOFFoam, VOF/homogeneous mixture solver for two phases. p-V coupling for a basic mixture solver with gravitational forces is explained before coding. A case is set and then run.

Опубликовано:

 

15 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 7   
@simosalah1389
@simosalah1389 17 дней назад
C'est magnifique .. merci infiniment
@simosalah1389
@simosalah1389 10 дней назад
Hello professor; I reproduced your code as you explained it. Then I tried to adopt another method as shown below. The two methods do not give identical results. Do you have an explanation? Thank you. ..... ..... ..... fvVectorMatrix UEqn ( fvm::ddt(rho, U) + fvm::div(rhoPhi, U) - fvm::laplacian(mu, U) - rho*g ); if (piso.momentumPredictor()) { solve(UEqn == -fvc::grad(p)); } // --- PISO loop while (piso.correct()) { volScalarField rAU(1.0/UEqn.A()); volVectorField HbyA(constrainHbyA(rAU*UEqn.H(), U, p)); surfaceScalarField phiHbyA ( "phiHbyA", fvc::flux(HbyA) + fvc::interpolate(rho*rAU)*fvc::ddtCorr(U, phi) ); ..... ..... .....
@SantiagoMarquezD
@SantiagoMarquezD 10 дней назад
What did you change specifically?
@simosalah1389
@simosalah1389 10 дней назад
@@SantiagoMarquezD just the position of the rho*g force. I had put it in the UEqn matrix, unlike what you did. See the part of the code above.
@SantiagoMarquezD
@SantiagoMarquezD 10 дней назад
If you do so you are including the gravitational force term in the H operator
@simosalah1389
@simosalah1389 10 дней назад
@@SantiagoMarquezD Yes you're right prof, the gravitational force term is included in the H operator. What I've found is that the results of the two approaches start out perfectly identical, but over time they diverge little by little. My question: in your experience, which of the two approaches is the most reliable? Thank you once again.
@SantiagoMarquezD
@SantiagoMarquezD 10 дней назад
@@simosalah1389 Never studied this particular problem in deep but all FOAM solvers are programmed with g and other source terms outside the H operator
Далее
C++ Should Be C++ - David Sankel - C++Now 2024
1:28:49
Просмотров 17 тыс.
Куда пропали ЗДРАЙВЕРЫ?
11:38
Просмотров 561 тыс.
Real respect sig
00:48
Просмотров 1,1 млн
Cursor Is Beating VS Code (...by forking it)
18:00
Просмотров 110 тыс.
TCP/IP for Programmers
3:03:31
Просмотров 10 тыс.
Simple Code, High Performance
2:50:14
Просмотров 249 тыс.