CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (http://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   How about I write U by reconstruct(phi)? (http://www.cfd-online.com/Forums/openfoam-programming-development/123069-how-about-i-write-u-reconstruct-phi.html)

 sharonyue September 3, 2013 21:14

How about I write U by reconstruct(phi)?

2 Attachment(s)
Hi Foamers!

Wonderful day!

lol, AFAWK, in the algorithm, we can get the U after solving possion equation via this equation: U = HbyA - rAU*fvc::grad(p);

In OpenFOAM, We all know that phi is divergence free indtead of U, Well, how about writing U by myU = fvc::reconstruct(phi)? Shouldn't it be more precise?

I made a test on cavity, there is a little difference but not much.

 sharonyue September 5, 2013 05:21

Hello guys??

 sharonyue September 11, 2013 04:49

Any ideas?

 derkermit September 17, 2013 09:55

Shouldn't reconstruct just (linear) interpolate the face centered values of (in this case) phi to the cell centers?
Do you get the same dimensions for myU and U?

 sharonyue September 22, 2013 21:30

Quote:
 Originally Posted by derkermit (Post 452225) Shouldn't reconstruct just (linear) interpolate the face centered values of (in this case) phi to the cell centers? Do you get the same dimensions for myU and U?
Yep, its the same. And it surely interpolate the phi to the cell centers. Just as OpenFOAM make sure phi is divergence free. So I think myU would be more precise than U. but as of the algorithm, U can be get by another equation. So I'm wondering which method would be more precise.

 derkermit September 23, 2013 06:28

How can they both have the same dimensions?
As an example: reconstruct(T) would give me the linear interpolated cell centered temperature values from face centered values. That will not affect the units or am I wrong with this?
If not, why would you get the same dimensions for myU and U?

 sharonyue September 23, 2013 20:41

Quote:
 Originally Posted by derkermit (Post 453094) How can they both have the same dimensions? As an example: reconstruct(T) would give me the linear interpolated cell centered temperature values from face centered values. That will not affect the units or am I wrong with this? If not, why would you get the same dimensions for myU and U?
I dont know if you can do reconstruct(t), but you can do reconstruct(phi) then you would get U at the cell center. more details see here and welcome comments: http://www.cfd-online.com/Forums/ope...-two-same.html. so myU 's unit,which is get by reconstructing, would be the same with U.

Actually, I have to make a new file in time file. I just copy U and rename it by myU.

 All times are GMT -4. The time now is 05:39.