CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums

Search Results

Register Blogs Community New Posts Updated Threads Search

Showing results 1 to 3 of 3
Search took 0.00 seconds.
Search: Posts Made By: Phicau
Forum: OpenFOAM November 3, 2011, 12:55
Replies: 6
Views: 1,701
Posted By Phicau
Another loop... label auxiliarLabel =...

Another loop...

label auxiliarLabel = -999999;

forAll(coord.component(2), index2)
{
if(coord.component(2)[index2]<=0.0)
{
...
Forum: OpenFOAM November 3, 2011, 11:50
Replies: 6
Views: 1,701
Posted By Phicau
Just loop the entire patch: ...

Just loop the entire patch:


vectorField coord = patch().Cf();
scalar auxiliar = 999999.0;

forAll(coord.component(2), index)
{
if(coord.component(2)[index]<=0.0)
...
Forum: OpenFOAM November 3, 2011, 11:17
Replies: 6
Views: 1,701
Posted By Phicau
I've never tried to use findMax, but this should...

I've never tried to use findMax, but this should work:

scalar whatever = findMax...;

reduce(whatever, maxOp<scalar>());

There are other options depending on your needs: minOp, sumOp...
...
Showing results 1 to 3 of 3

 
Forum Jump

All times are GMT -4. The time now is 22:08.