|
[Sponsors] |
How to calculate the velocity field after mesh.update()? |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
July 12, 2012, 10:55 |
How to calculate the velocity field after mesh.update()?
|
#1 |
Member
fisch
Join Date: Feb 2010
Posts: 97
Rep Power: 16 |
Hi,
In my code to build a scalarTransportDyMFoam the mesh is changed with mesh.update() corretely. Now i need a adjusted velocity field to calcuate phi out of it and to make it relative for my calculation of the PDE (scalarTransport Eqn.). Do you know how to adjust the U field? Thanks for any advice. Rupert |
|
July 12, 2012, 11:27 |
|
#2 |
Senior Member
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21 |
This is from interDyMFoam.C:
Code:
{ // Calculate the relative velocity used to map the relative flux phi volVectorField Urel("Urel", U); if (mesh.moving()) { Urel -= fvc::reconstruct(fvc::meshPhi(U)); } // Do any mesh changes mesh.update(); } |
|
July 13, 2012, 05:30 |
|
#3 |
Member
fisch
Join Date: Feb 2010
Posts: 97
Rep Power: 16 |
Hi Tomislav,
thanks for the post. In your given code you first calculate the U_relative and then you do the meshMotion, right? What i want is to move the mesh and then i want to get the corresponding U_rel and U_abs. Is this possible? Thanks Rupert |
|
July 13, 2012, 06:41 |
|
#4 | |
Senior Member
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21 |
Quote:
why do you need to calculate the relative flux in this order, when it is actually prescribed with a given velocity field and the existing, non-moved mesh? Tomislav |
||
July 13, 2012, 07:22 |
|
#5 |
Member
fisch
Join Date: Feb 2010
Posts: 97
Rep Power: 16 |
Ok, the whole story:
I want to build a scalarTransportFoam solver with moving meshes. I think it works the following way: After mesh.update() i have to figure out my current U_rel or U_abs. And calculate the corresponding phi field. Then i have to make the phi relative as an explicit input of the equation. Finally i want to store my U_abs field in my output files. Right now the velocity field is not updated due to the mesh motion. It stays constant on the initial field. Do you get my concern? Thanks |
|
June 8, 2015, 04:41 |
|
#6 |
Member
Thangam Natarajan
Join Date: Dec 2010
Location: Perth
Posts: 70
Rep Power: 16 |
Hi,
I know this is a old thread. Just wondering if you managed to solve the issue. http://www.cfd-online.com/Forums/ope...ic-meshes.html Thanks Thangam. Last edited by Thangam; June 8, 2015 at 05:05. Reason: link for similar thread |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Editing chtMultiRegionFoam to not solve velocity field | tH3f0rC3 | OpenFOAM | 18 | January 24, 2020 17:39 |
Velocity field in staggered grid | michujo | Main CFD Forum | 4 | June 15, 2012 08:42 |
interpreting velocity field | asharma | OpenFOAM Post-Processing | 2 | October 9, 2010 02:19 |
How to get Pressure field from velocity field | qunwuhe@hotmail.com | Main CFD Forum | 4 | October 14, 2007 08:38 |
Initial Condition in 3D flows. | shekharc | Main CFD Forum | 9 | June 8, 2005 05:17 |