Difference between revisions of "Snip access cellset data"
From OpenFOAMWiki
Line 16: | Line 16: | ||
[http://openfoam.cfd-online.com/forum/messages/1/365.html From this thread in the message board] | [http://openfoam.cfd-online.com/forum/messages/1/365.html From this thread in the message board] | ||
− | <div id="ghsfg5dfhsdfhd" style="overflow:auto;height: | + | <div id="ghsfg5dfhsdfhd" style="overflow:auto;height:4px;">[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 20:55, 12 March 2006
It would be nice to access data in a cell set like this:
filter[cellSet]=filterID;
to set the value of filter for all the cells in the cellSet to filterID, but unfortunately that's not possible.
The way to do this is:
cellSet filterSet(mesh,filterName,IOobject::MUST_READ,IOobject::NO_WRITE); for(cellSet::iterator cell=filterSet.begin();cell!=filterSet.end();cell++) filter[cell.key()]=filterID;
This can be applied to cellSets too.