CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   Main CFD Forum (https://www.cfd-online.com/Forums/main/)
-   -   cell-based data to node-based data (https://www.cfd-online.com/Forums/main/63197-cell-based-data-node-based-data.html)

gonski March 31, 2009 18:37

cell-based data to node-based data
 
Hi all,
My CFD code provides fluid velocity on cell center. But I need velocity on grid nodes for some special calculation. So, which scheme is the best for me to interpolate the cell-based data to grid node?
Your hints would be greatly appreciated.
Cheers,
Gonski

gory March 31, 2009 20:49

Volume-weighted average, Least-squares fit (possibly with weights), etc. Or generate a dual grid whose nodes coincide to the cell centers of the original grid?

gonski March 31, 2009 21:08

Now I try to use gradient interpolation, i.e. interpolate velocity from center of cells around the considered node to the node, then average it. the gradient is calculated by a leas-square or guass method. I guess if gradient is based on least-square method, it should be least-square fit mentioned by you? I found this method produce strange results on boundaries.

RenardP March 31, 2009 21:58

You can search on NASA reports site after Neal T Frink, he presents a simple method for interpolating the cell centered values to the grid nodes. His method works very well on unstructured grids.

gonski March 31, 2009 22:02

Quote:

Originally Posted by RenardP (Post 211502)
You can search on NASA reports site after Neal T Frink, he presents a simple method for interpolating the cell centered values to the grid nodes. His method works very well on unstructured grids.

Will you please tell me which report published by Neal T Frink?
Cheers,
Gonski

RenardP April 1, 2009 00:10

Tetrahedral Finite-Volume Solutions to the Navier-Stokes Equations on Complex Configurations, Neal T Frink

this is the link:

http://ntrs.nasa.gov/search.jsp?R=24...57c1%26N%3D123

Check the formula at (3) this is the more robust.

Paul

gonski April 1, 2009 02:26

Hi Paul,
Thank you very much!
Is it possible for me to use weighting method to interpolate velocity from a cell as well as 6 neighbors (if hexadra is considered ) to some point in the cell? Or I need to do the weighting interpolation twice to achieve this. will you please present some comments here?
Cheers,
Gonski

RenardP April 1, 2009 08:19

I'm not sure I understand correctly your question. Are your using a dual mesh or some form of staggered grid for solving your problem ?

gonski April 1, 2009 08:46

Sorry! I did not explain my problem clearly enough.
Now I have two things to be done as follows:
(1) To get velocity on grid nodes from cell center which have all flow information in my code. This is mainly for visualization
(2) To get local velocity on particle position for calculating particle trajectory. Here the particle can reside anywhere in a cell.

As you suggested, I can achieve the first item by weighting interpolation.
To calculate local velocity, I may have two choices when I know which cell the particle of interest is residing:
(a) I can interpolate node based data (calculated in task ( 1)) to particle position. This means that I do two weighting interpolations. Here, I need to only consider velocities on 6 nodes of the host cell containing the considered particle.
(b) I can directly interpolate cell-based data to particle position. This means that I only do weighting interpolation once. Here, I need to consider velocity on the host cell and its 6 neighbors will be used.

Which is better to get local velocity to calculate particle trajectory?

RenardP April 1, 2009 14:12

OK,

I have experience only on point 1) - for this I can tell you that the weight based interpolation will work.

For point 2) I don't know what will be the best method, I suggest you to create an "academic example" - give some analytical form to your velocity field (I suppose your particle has the same velocity as the surrounding fluid), and test this on some simple meshes (up to 6-10 points), then check if the weight based formula gives you an accurate results on this mesh.

I think it will work, but you better check it.

Paul

gonski April 1, 2009 22:40

Hi paul,
Than you very much for your kind helps. Other guys who give me helps are also greatly appreciated. From the simulations outputs I have got in different systems. Now my code works well with inverse weight interpolation. As the simulations would finish in three weeks at least due to high solid loading, I cannot tell this interpolation can improve my code. Whatever, simulations are running as expected. This already means a lot.
Thanks again.
All the best,
Gonski


All times are GMT -4. The time now is 21:42.