CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM Mesh Utilities (
-   -   mapFields producing "nan" entry (

tlandfried July 27, 2012 09:36

mapFields producing "nan" entry
Morning all,

I've run into a requiring problem that I can't seem to fix. So, I thought I'd bring the problem here and see if anyone has some familiarity with it or any insight. Additionally, I've posted the problem on

The problem I'm having involves using the mapFields utility on a supercomputing cluster, SAM at Pitt. When I run locally, the utility has no problems. However, when I run on the cluster, the utility likes to create "nan" entries in the pressure fields. The problem then being, when I run my solver, simpleFoam in my case, errors occur when the first "nan" entry is encountered. I get the error:


wrong token type - expected Scalar, found on line 3076 the word 'nan'

file: /home/mkimber/dtl5/confinementStudies/Re_32/R08_A2000_180/1500/p at line 3076.

    From function operator>>(Istream&, Scalar&)
    in file lnInclude/Scalar.C at line 91.

Its worth noting that I've only seen this error when running large meshes, approximately 1 million cells. Additionally, this is a low speed, laminar simulation, so the velocity in some locations is very small, approximately 10^(-6).

From what I've been able to gather, the reason I only have this problem on the cluster could be due to a discrepancy between the $FOAM_SETNAN entry I have locally and on the cluster, however, when I checked the setting on both, they were the same. As of this point, I am unsure what exactly I should do. I have previously just run mapFields locally and then uploaded the newly initialized time to SAM. However, this isn't a convenient way to do it, and will be extremely time consuming in the future when I have larger, more intensive simulations.

Any help or suggestions?


tlandfried July 27, 2012 10:37

Hey, from It was suggested, that since I'm using simple, I should increase the number of nonOrthoganolCorrectors to say 3? Previously I had it at 1, any thoughts on this?


EDIT: Yea, this didn't fix my problem. Since its occurring during the mapFields utility, it makes sense it doesn't.

wyldckat August 7, 2012 07:40

Greetings Tyler,

You could have left a breadcrumb in this thread to the new thread:

I'll reply to you in the other thread in a few minutes...

Best regards,

All times are GMT -4. The time now is 10:29.