CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   SetMotionMovingCone (http://www.cfd-online.com/Forums/openfoam-solving/59667-setmotionmovingcone.html)

maddalena June 1, 2007 11:51

Hello everybody! I have some
 
Hello everybody!
I have some problem with the specification of different diffusion coefficients for moving meshes. The general idea of my work is to specify a particular diffusion coefficient for the cells closer than a certain amount from my wing, and a distance-based diffusion (quadratic) for all the other cells. To calculate the distances, I would like to use wallDist.H, so I included it in my setMotionMovingCone.C and also I added the full path in the Make/options file: -I$(LIB_SRC)/finiteVolume/fvMesh/wallDist. I then added some more lines to do all my stuff in setMotionMovingCone.C file, saved and compiled everything. Unfortunately, I got the following error:

Making dependency list for source file setMotionMovingCone.C
could not open file volFields.H for source file setMotionMovingCone.C
could not open file cellDistFuncs.H for source file setMotionMovingCone.C

SOURCE_DIR=.
SOURCE=setMotionMovingCone.C ; g++ -m32 -Dlinux -DDP -Wall -W -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-30 -I/home/madl/OpenFOAM/OpenFOAM-1.3/src/tetDecompositionFiniteElement/lnInclude -I/home/madl/OpenFOAM/OpenFOAM-1.3/src/finiteVolume/fvMesh/wallDist -DCELL_DECOMP -I/home/madl/OpenFOAM/OpenFOAM-1.3/src/OpenFOAM/lnInclude -IlnInclude -I. -fPIC -pthread -c $SOURCE -o Make/linuxGcc4DPOpt/setMotionMovingCone.o
In file included from setMotionMovingCone.C:37:
/home/madl/OpenFOAM/OpenFOAM-1.3/src/finiteVolume/fvMesh/wallDist/wallDist.H:63: 23: error: volFields.H: No such file or directory
/home/madl/OpenFOAM/OpenFOAM-1.3/src/finiteVolume/fvMesh/wallDist/wallDist.H:64: 27: error: cellDistFuncs.H: No such file or directory
/home/madl/OpenFOAM/OpenFOAM-1.3/src/finiteVolume/fvMesh/wallDist/wallDist.H:80: error: expected class-name before ',' token
/home/madl/OpenFOAM/OpenFOAM-1.3/src/finiteVolume/fvMesh/wallDist/wallDist.H:82: error: expected class-name before '{' token
/home/madl/OpenFOAM/OpenFOAM-1.3/src/finiteVolume/fvMesh/wallDist/wallDist.H:121 : error: ISO C++ forbids declaration of 'volScalarField' with no type
/home/madl/OpenFOAM/OpenFOAM-1.3/src/finiteVolume/fvMesh/wallDist/wallDist.H:121 : error: expected ';' before '&' token
/home/madl/OpenFOAM/OpenFOAM-1.3/src/finiteVolume/fvMesh/wallDist/wallDist.H:126 : error: expected `;' before 'label'
setMotionMovingCone.C: In function 'int main(int, char**)':
setMotionMovingCone.C:57: error: expected initializer before '&' token
setMotionMovingCone.C:61: error: 'dist' was not declared in this scope
make: *** [Make/linuxGcc4DPOpt/setMotionMovingCone.o] Error 1

As you can see, everything is due to the fact that I miss volFields.H and cellDistFuncs.H files. But this is strange because they are files dependant from wallDist.H, that is an OpenFOAM file so it is supposed to be right. Do you have any suggestion for me to understand what's wrong?
I also need an explanation about C++, since my programming knowledge is really basic. What is the difference between using #include "..." before "main" and after "main"? thanks!
maddalena


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