|
[Sponsors] |
April 23, 2014, 21:10 |
exp() function not working?
|
#1 |
Member
CHARLES
Join Date: May 2013
Posts: 46
Rep Power: 13 |
Hello,
For some reason I don't think that exp() is doing anything... can you please tell me what you think is wrong? I have the following code: Code:
argf2 = sqr(k_)/(6.0*nu()*epsilon_); f2 = 1-2/9*Foam::exp(-1.0*sqr(argf2)); However, when I bring up f2 in paraview it just shows up as 1 everywhere. If I define f2 in the following way: Code:
f2 = 99-2/9*Foam::exp(-1.0*sqr(argf2)); If I define f2 in the following way: Code:
f2 = -2/9*Foam::exp(-1.0*sqr(argf2)); I have also tried to not use "Foam::" before exp() and it doesn't make a difference. Additionally, when I look at the f2 that was output to the time directory it looks like this: Code:
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.2.0 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class volScalarField; location "0.001"; object f2; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [0 0 0 0 0 0 0]; internalField uniform 1; boundaryField { plate { type calculated; value uniform 1; } back { type empty; } front { type empty; } inlet { type calculated; value uniform 1; } outlet { type calculated; value uniform 1; } top { type calculated; value uniform 1; } symmetry { type symmetryPlane; } } // ************************************************************************* // Thank you! |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[blockMesh] non-orthogonal faces and incorrect orientation? | nennbs | OpenFOAM Meshing & Mesh Conversion | 7 | April 17, 2013 05:42 |
Can anybody help me to solve the list errors while compiling Openfoam 15 on Opensuse 103 32bit | coompressor | OpenFOAM Installation | 0 | November 12, 2008 19:53 |
Could you please help me about the VTKFoam | liugx212 | OpenFOAM Pre-Processing | 5 | February 13, 2008 11:31 |
Droplet Evaporation | Christian | Main CFD Forum | 2 | February 27, 2007 06:27 |
[OpenFOAM] Could you please help me | liugx212 | ParaView | 4 | December 22, 2005 16:55 |