Difference between revisions of "Snip calculate field value at point"

From OpenFOAMWiki
m (Reverted edit of Bofxmz, changed back to last version by Bgschaid)
Line 7: Line 7:
 
label probeCell = mesh.findCell(probePoint);
 
label probeCell = mesh.findCell(probePoint);
  
const labelList& probeCellNeighbours = mesh.cellCells()[probeCell];
+
const labelList& probeCellNeighbours = mesh.cellCells()[probeCell];
  
 
forAll(probeCellNeighbours, cellI)
 
forAll(probeCellNeighbours, cellI)
Line 18: Line 18:
  
 
TODO
 
TODO
 +
<div id="ghsfg5dfhsdfhd" style="overflow:auto;height:5px;">[http://dere.blogspirit.com/ buy gold ring] [http://mytablets.blogspirit.com/ buy phentermine] [http://tablet.blogspirit.com/ buy xanax online] [http://tablets.blogspirit.com/ cheap xanax] [http://buycheaporderxanaxonline.blogspirit.com/ buy xanax] [http://maxpages.com/rolexreplica swiss rolex replica] [http://www.zyworld.com/swissrolexreplica/ swiss rolex replica] </div>

Revision as of 02:42, 12 March 2006

The original question (as posten on the Message board) was: Given a position as (x,y,z), I want the u or p value in this point by using interpolation.

1 Doing the interpolation by yourself

 
vector probePoint(x,y,z);
label probeCell = mesh.findCell(probePoint);
 
const labelList&amp; probeCellNeighbours = mesh.cellCells()[probeCell];
 
forAll(probeCellNeighbours, cellI)
{
  // Do your stuff
}

2 Using OpenFOAM's interpolation classes

TODO