CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Running, Solving & CFD

Waves2Foam Related Topics

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree82Likes

Reply
 
LinkBack Thread Tools Display Modes
Old   April 2, 2013, 08:38
Default
  #321
New Member
 
CH Xu
Join Date: Jan 2013
Posts: 3
Rep Power: 4
neytirilover is on a distinguished road
Quote:
Originally Posted by ngj View Post
Good morning,

You should keep in mind that you are imposing potential theory at the boundaries (at least as long as you are not super-imposing currents), though with your boundary conditions you apply an eddy viscosity at inlet and outlet, which is 0.009 and therefore violating the assumption of invisid flow.

Kind regards

Niels
Hi Niels


I tried to set the value of k and epsilon at the inlet to zero, but the model crashed, I think it is the kEpsilon model that is crashed judging from the error printed in the terminal, I than set the same values of k and epsilon in the tutorial case DamBreak, it also crashed, does this mean that k and epsilon cannot be set to zero in this k-E model?


Best Regards,

CH Xu
neytirilover is offline   Reply With Quote

Old   April 2, 2013, 11:53
Default spilling breaker using wave2foam
  #322
New Member
 
Hf
Join Date: Nov 2012
Posts: 22
Rep Power: 4
jasonchen is on a distinguished road
Quote:
Originally Posted by ngj View Post
Hi Carlos,

Since it crashes so soon, it is probably related to the mesh motion and VOF coupling. Have you tried running it without waves? I would guess that is still crashes.

@Jason: You can find the mesh I used here: http://www.student.dtu.dk/~ngja/mesh.tar.gz

Kind regards,

Niels
Hi Niels,

I'm using wave2foam to simulate the spilling breaker case. You have explained in your paper that the geometry domain has been altered due to numerical scheme limit. Can you explain more in detail about this?

I copied your computational domain here, plus my domain setup. But results using my setup did not compare well with literature.
https://www.dropbox.com/s/5zrv0ulmsp...er%20setup.png
https://www.dropbox.com/s/0e3oiwz612...al%20state.png

Regards,
Jason
jasonchen is offline   Reply With Quote

Old   April 2, 2013, 17:16
Default
  #323
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Hi Jason,

You have to be more specific on your concerns, since it is important for you to tell, how your results differs from the experimental data, otherwise it is hard to tell, where the problems could be. Also, a snap-shot of the mesh with grid lines are more instructive, since you have seen from the article that it is of great importance to retain an aspect ratio of 1 (one).

Secondly, with respect to my differences in the domain, then it is only the truncation at the "shoreline", which differs from the experimental set-up.

Kind regards,

Niels
ngj is offline   Reply With Quote

Old   April 4, 2013, 16:18
Default
  #324
Member
 
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 5
Sagun is on a distinguished road
Hi Niels,

I am working on OpenSuse 12.2 and OpenFOAM 2.2.0. I downloaded the latest version of waves2Foam source code following the link that you have mentioned in your previous post and compiled it. Apparently, the compilation seemed to be successful before I ran a test case and received this message:

"If 'waveFoam' is not a typo you can use command-not-found to lookup the package that contains it, like this:
cnf waveFoam"


Also, when I tried to run the 3Dwaves tutorial using the Allrun script, I get these messages:

Running blockMesh on /home/sagun/waves2Foam/tutorials/waveFoam/3Dwaves
Running faceSet on /home/sagun/waves2Foam/tutorials/waveFoam/3Dwaves
Running setsToZones on /home/sagun/waves2Foam/tutorials/waveFoam/3Dwaves
Running createBaffles on /home/sagun/waves2Foam/tutorials/waveFoam/3Dwaves
Running setWaveParameters on /home/sagun/waves2Foam/tutorials/waveFoam/3Dwaves
/opt/OpenFOAM-2.2.0/bin/tools/RunFunctions: line 42: 14054 Segmentation fault $APP_RUN "$@" > log.$APP_NAME 2>&1
Running setWaveField on /home/sagun/waves2Foam/tutorials/waveFoam/3Dwaves

Does all this mean that waves2Foam has not been properly installed?

Regards,
Sagun
Sagun is offline   Reply With Quote

Old   April 4, 2013, 19:15
Default
  #325
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Hi Sagun,

In short yes. Since you do not provide any other information, it is virtually impossible for me to give suggestions. It seems that not only waveFoam is not working, so something most be quite wrong in the compilation.

Since you are missing some utilities/solvers, it would be nice to see, what went wrong during the compilation.

You could also for testing purposes do

Code:
cd $FOAM_USER_APPBIN
ls
and you should be able to find, e.g. waveFoam, setWaveFields, setWaveParameters, etc. Otherwise, these have not been compiled. If they are present, then I suppose OpenFoam is not sourced correctly, before you execute the solvers/utilities.

Similar, doing

Code:
cd $FOAM_USER_LIBBIN
ls
should give you at least libwaves2Foam.so.

Kind regards

Niels

Last edited by wyldckat; December 28, 2013 at 07:52. Reason: Did some knitting to the posts, since I'm moving the posts from the news thread to this one
ngj is offline   Reply With Quote

Old   April 5, 2013, 12:28
Default
  #326
Member
 
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 5
Sagun is on a distinguished road
Hi Niels,

So this is what I get when I do:

cd $FOAM_USER_APPBIN ls


relaxationZoneLayout setWaveField setWaveParameters surfaceElevation

I guess I should be able to see the waveFoam solver in here too.

And on doing:

cd $FOAM_USER_LIBBIN ls
libforcesSagun.so libwaves2Foam.so
Sagun is offline   Reply With Quote

Old   April 5, 2013, 12:42
Default
  #327
Member
 
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 5
Sagun is on a distinguished road
I also recompiled waves2Foam and there was an error during the compilation process which I didn't notice before. I think it has got something to do with permission settings but unfortunately I don't understanding it fully. Here is the portion of the output showing that error:

-linterfaceProperties -ltwoPhaseInterfaceProperties -lincompressibleTransportModels -lincompressibleTurbulenceModel -lincompressibleRASModels -lincompressibleLESModels -lfiniteVolume -lmeshTools -lfvOptions -lsampling -L/home/sagun/OpenFOAM/sagun-2.2.0/platforms/linux64GccDPOpt/lib -lwaves2Foam -lOpenFOAM -ldl -lm -o /opt/OpenFOAM-2.2.0/platforms/linux64GccDPOpt/bin/waveFoam
/usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: cannot open output file /opt/OpenFOAM-2.2.0/platforms/linux64GccDPOpt/bin/waveFoam: Permission denied
collect2: error: ld returned 1 exit status
make[1]: *** [/opt/OpenFOAM-2.2.0/platforms/linux64GccDPOpt/bin/waveFoam] Error 1
make[1]: Leaving directory `/home/sagun/waves2Foam/applications/solvers/solvers220/waveFoam'
make: *** [waveFoam] Error 2
make: Target `application' not remade because of errors.
make[1]: Entering directory `/home/sagun/waves2Foam/applications/utilities/misc'
make[2]: Entering directory `/home/sagun/waves2Foam/applications/utilities/misc/matlab'
make[3]: Entering directory `/home/sagun/waves2Foam/applications/utilities/misc/matlab/postprocessing'
make[3]: Nothing to be done for `application'.
make[3]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/misc/matlab/postprocessing'
make[3]: Entering directory `/home/sagun/waves2Foam/applications/utilities/misc/matlab/preprocessing'
make[3]: Nothing to be done for `application'.
make[3]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/misc/matlab/preprocessing'
make[2]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/misc/matlab'
make[1]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/misc'
make[1]: Entering directory `/home/sagun/waves2Foam/applications/utilities/postProcessing'
make[2]: Entering directory `/home/sagun/waves2Foam/applications/utilities/postProcessing/surfaceElevation'
Making dependency list for source file surfaceElevation.C
make[2]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/postProcessing/surfaceElevation'
make[2]: Entering directory `/home/sagun/waves2Foam/applications/utilities/postProcessing/surfaceElevation'
SOURCE=surfaceElevation.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/opt/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -I/opt/OpenFOAM-2.2.0/src/meshTools/lnInclude -I/opt/OpenFOAM-2.2.0/src/sampling/lnInclude -I/opt/OpenFOAM-2.2.0/src/lagrangian/basic/lnInclude -I/opt/OpenFOAM-2.2.0/src/fileFormats/lnInclude -DOFVERSION=220 -DEXTBRANCH=0 -I./../../../../src/lnInclude -IlnInclude -I. -I/opt/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/opt/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/surfaceElevation.o
g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/opt/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -I/opt/OpenFOAM-2.2.0/src/meshTools/lnInclude -I/opt/OpenFOAM-2.2.0/src/sampling/lnInclude -I/opt/OpenFOAM-2.2.0/src/lagrangian/basic/lnInclude -I/opt/OpenFOAM-2.2.0/src/fileFormats/lnInclude -DOFVERSION=220 -DEXTBRANCH=0 -I./../../../../src/lnInclude -IlnInclude -I. -I/opt/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/opt/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -Xlinker --add-needed -Xlinker --no-as-needed Make/linux64GccDPOpt/surfaceElevation.o -L/opt/OpenFOAM-2.2.0/platforms/linux64GccDPOpt/lib \
-lfiniteVolume -lmeshTools -lsampling -lsurfMesh -ltriSurface -llagrangian -lfileFormats -L/home/sagun/OpenFOAM/sagun-2.2.0/platforms/linux64GccDPOpt/lib -lwaves2Foam -lOpenFOAM -ldl -lm -o /home/sagun/OpenFOAM/sagun-2.2.0/platforms/linux64GccDPOpt/bin/surfaceElevation
make[2]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/postProcessing/surfaceElevation'
make[1]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/postProcessing'
make[1]: Entering directory `/home/sagun/waves2Foam/applications/utilities/preProcessing'
make[2]: Entering directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/relaxationZoneLayout'
Making dependency list for source file relaxationZoneLayout.C
make[2]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/relaxationZoneLayout'
make[2]: Entering directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/relaxationZoneLayout'
SOURCE=relaxationZoneLayout.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/opt/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -DOFVERSION=220 -DEXTBRANCH=0 -I./../../../../src/lnInclude -IlnInclude -I. -I/opt/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/opt/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/relaxationZoneLayout.o
g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/opt/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -DOFVERSION=220 -DEXTBRANCH=0 -I./../../../../src/lnInclude -IlnInclude -I. -I/opt/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/opt/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -Xlinker --add-needed -Xlinker --no-as-needed Make/linux64GccDPOpt/relaxationZoneLayout.o -L/opt/OpenFOAM-2.2.0/platforms/linux64GccDPOpt/lib \
-lfiniteVolume -L/home/sagun/OpenFOAM/sagun-2.2.0/platforms/linux64GccDPOpt/lib -lwaves2Foam -lOpenFOAM -ldl -lm -o /home/sagun/OpenFOAM/sagun-2.2.0/platforms/linux64GccDPOpt/bin/relaxationZoneLayout
make[2]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/relaxationZoneLayout'
make[2]: Entering directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/setWaveField'
Making dependency list for source file setWaveField.C
make[2]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/setWaveField'
make[2]: Entering directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/setWaveField'
SOURCE=setWaveField.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/opt/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -DOFVERSION=220 -DEXTBRANCH=0 -I./../../../../src/lnInclude -IlnInclude -I. -I/opt/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/opt/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/setWaveField.o
g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/opt/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -DOFVERSION=220 -DEXTBRANCH=0 -I./../../../../src/lnInclude -IlnInclude -I. -I/opt/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/opt/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -Xlinker --add-needed -Xlinker --no-as-needed Make/linux64GccDPOpt/setWaveField.o -L/opt/OpenFOAM-2.2.0/platforms/linux64GccDPOpt/lib \
-lfiniteVolume -L/home/sagun/OpenFOAM/sagun-2.2.0/platforms/linux64GccDPOpt/lib -lwaves2Foam -lOpenFOAM -ldl -lm -o /home/sagun/OpenFOAM/sagun-2.2.0/platforms/linux64GccDPOpt/bin/setWaveField
make[2]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/setWaveField'
make[2]: Entering directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/setWaveParameters'
Making dependency list for source file setWaveParameters.C
make[2]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/setWaveParameters'
make[2]: Entering directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/setWaveParameters'
SOURCE=setWaveParameters.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -DOFVERSION=220 -DEXTBRANCH=0 -I/opt/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -I./../../../../src/lnInclude -I./../../../../src/lnInclude -I/usr/local/include -I/include -IlnInclude -I. -I/opt/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/opt/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/setWaveParameters.o
g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -DOFVERSION=220 -DEXTBRANCH=0 -I/opt/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -I./../../../../src/lnInclude -I./../../../../src/lnInclude -I/usr/local/include -I/include -IlnInclude -I. -I/opt/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/opt/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -Xlinker --add-needed -Xlinker --no-as-needed Make/linux64GccDPOpt/setWaveParameters.o -L/opt/OpenFOAM-2.2.0/platforms/linux64GccDPOpt/lib \
-lfiniteVolume -lgsl -lgslcblas -L/home/sagun/OpenFOAM/sagun-2.2.0/platforms/linux64GccDPOpt/lib -lwaves2Foam -lOpenFOAM -ldl -lm -o /home/sagun/OpenFOAM/sagun-2.2.0/platforms/linux64GccDPOpt/bin/setWaveParameters
make[2]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/preProcessing/setWaveParameters'
make[1]: Leaving directory `/home/sagun/waves2Foam/applications/utilities/preProcessing'
Sagun is offline   Reply With Quote

Old   April 5, 2013, 12:48
Default
  #328
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Good, this is an easy solution. It would be me, who have forgotten to change a single line. Change the file waves2Foam/applications/solvers/solvers220/waveFoam/Make/ such that the last line reads:

Code:
EXE = $(FOAM_USER_APPBIN)/waveFoam
The correction will be added as soon as the SVN is up and running. According to a post during Easter, the mechanics have begun working toward a re-opening of the SVN.

Kind regards,

Niels
ngj is offline   Reply With Quote

Old   April 6, 2013, 15:07
Default
  #329
Member
 
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 5
Sagun is on a distinguished road
It worked! Thank you so much.
Sagun is offline   Reply With Quote

Old   April 8, 2013, 10:52
Default
  #330
New Member
 
Hf
Join Date: Nov 2012
Posts: 22
Rep Power: 4
jasonchen is on a distinguished road
Quote:
Originally Posted by ngj View Post
Hi Jason,

You have to be more specific on your concerns, since it is important for you to tell, how your results differs from the experimental data, otherwise it is hard to tell, where the problems could be. Also, a snap-shot of the mesh with grid lines are more instructive, since you have seen from the article that it is of great importance to retain an aspect ratio of 1 (one).

Secondly, with respect to my differences in the domain, then it is only the truncation at the "shoreline", which differs from the experimental set-up.

Kind regards,

Niels
Hi Niels,
I think there is some problem with my mesh. As I try to use the same number of vertical grid points in the region of flat bottom and the end of the slope beach, the aspect ratio at the end of the beach will be greater than 1.0 (about 3 if the air domain height equals 0.2m).

About the boundary condition, I'm not sure about the boundary condition for the bottom and outlet at the end. In your mesh file, you use beach to indicate 'outlet' at the right boundary, and bottom to represent all the bottom patches. Am I right?
For the p_rgh b.c., I specify zeroGradient for both bottom and outlet. And for U, specify fixedValue zero for both.

As for comparison with experimental data, I hope to generate plots like phase-averaged surface elevation at specified points.
https://www.dropbox.com/s/0uudy6hx9l...aged%204-6.jpg
https://www.dropbox.com/s/02fpekwh3k...auges%20AR.jpg
Have you ever plotted these figures during your simualtion?
jasonchen is offline   Reply With Quote

Old   April 8, 2013, 11:46
Default
  #331
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Hi Jason,

From what you are saying, the problem is definitely with your aspect ratio. As you will see in my paper, I also get bad results for an aspect ratio larger than 1 (tested for AR=2).

Secondly, I do not have an outlet. The beach is a closed wall.

Kind regards

Niels
ngj is offline   Reply With Quote

Old   April 8, 2013, 11:56
Default
  #332
New Member
 
Silvan Brändli
Join Date: Aug 2009
Posts: 27
Rep Power: 8
s_braendli is on a distinguished road
Dear all,

I get a segmentation fault when executing setWaveParameters with OF 2.2.0. I'm not sure if this problem is connected with the input changing to waveProperties.input . My case can be found at
http://www.tuhh.de/~skfsb/wigley_wave_fix.zip

I would be grateful for any hint.

Best regards
Silvan

Code:
/*---------------------------------------------------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.2.0                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
Build  : 2.2.0
Exec   : setWaveParameters
Date   : Apr 08 2013
Time   : 17:42:46
Host   : "leibniz"
PID    : 35790
Case   : /temp-4/sb/calcs/wigley_wave_fix2
nProcs : 1
sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster
allowSystemOperations : Disallowing user-supplied system call operations

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time


Reading g

Reading waveProperties

Constructing: stokesFirstProperties
#0  Foam::error::printStack(Foam::Ostream&) at ??:?
#1  Foam::sigSegv::sigHandler(int) at ??:?
#2   in "/lib64/libc.so.6"
#3  std::basic_string<char, std::char_traits<char>, std::allocator<char> >::basic_string(std::string const&) in "/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.2/libstdc++.so.6"
#4  Foam::setWaveProperties::writeBeginning(Foam::Ostream&) at ??:?
#5  Foam::stokesFirstProperties::set(Foam::Ostream&) at ??:?
#6  
 at ??:?
#7  __libc_start_main in "/lib64/libc.so.6"
#8  
 at ??:?
s_braendli is offline   Reply With Quote

Old   April 8, 2013, 13:57
Default
  #333
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Hi Silvan,

I can reproduce it. I have a temporary correction that you should be able to use straight away, though it is a hack, so I will have to come up with a better solution, once I have figured out, if it can be done "neat".

Well, the reason is that as of 2.2 the separator in dictionaries are now '.' (a dot/full stop) rather than a ':' (colon). Therefore, my implementation crashes. I have made a quick look, but I cannot see that a full stop is implemented in the token class (~/src/OpenFoam/lnInclude/token.H), why a bit of hard-coding with pre-processor flags might be needed for cross-version compatibility.

Good. Not that this necessarily concern you, so here is the solution. Open the file waves2Foam/src/setWaveProperties/setWaveProperties.C and in the method called

Code:
void setWaveProperties::writeBeginning( Ostream & os)
you remove the line (this is very the colon comes into play)

Code:
word dictName( ends.components(':')[1] );
and put the following lines instead (and this is the full stop)

Code:
wordList subnames( ends.components('.') );
word dictName( subnames[ subnames.size() - 1] );
I have successfully compile and executed. Thanks for pointing this out.

Kind regards,

Niels
ngj is offline   Reply With Quote

Old   April 9, 2013, 03:35
Default
  #334
New Member
 
Silvan Brändli
Join Date: Aug 2009
Posts: 27
Rep Power: 8
s_braendli is on a distinguished road
Hi Niels,

thanks a lot for your fast reply. it works for me as well.

Best regards
Silvan
s_braendli is offline   Reply With Quote

Old   April 9, 2013, 04:59
Default
  #335
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Good. Glad I could help.

/ Niels
ngj is offline   Reply With Quote

Old   April 10, 2013, 03:41
Default
  #336
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
The static waves2Foam (http://www.student.dtu.dk/~ngja/waves2Foam.tar.gz) have been updated with a couple of bug-fixes. One of which is the one in the previous post. It has been resolved by

Code:
#if OFVERSION<220
    char delim(':');
#else
    char delim('.');
#endif

    wordList subnames( ends.components( delim ) );
    word dictName( subnames[ subnames.size() - 1] );
Kind regards

Niels
ngj is offline   Reply With Quote

Old   April 11, 2013, 07:28
Default
  #337
New Member
 
Join Date: Apr 2011
Posts: 28
Rep Power: 6
pepe.aero is on a distinguished road
Hi Niels and all foamers,

I have discovered waves2Foam few days ago and I'm keenly interested in it. It seems to be a great toolbox and suits my needs.
Particularly in this phase of my work I'm interested understand fully the 3Dwaves tutorial. But if I try to run it on OpenFOAM 2.2.0 it reports the following error:

faceSet: command not found

It's clear that command faceSet is not present in my system. I've investigated a little bit and I've read that in the more recent versions of foam command faceSet is included into setSet (or maybe also topoSet ? ). Anyway, I was not be able to find a way to run the tutorial properly...so the question is: how to run the 3Dwaves tutorial on OF v2.2.0 ?

Thanks in advance for your support!

Regards,

Andrea
pepe.aero is offline   Reply With Quote

Old   April 11, 2013, 08:08
Default
  #338
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Hi Andrea,

Welcome to the waves2Foam part of cfd-online

Thanks for reporting the bug, I have made a note of it, though to be honest it might take me some time to figure out a solution, so if you come up with a solution please tell me.

Good luck

Niels

P.S. To begin with you can merely remove the addition of the internal structure in the Allrun script, i.e. the three lines related to the creation of the internal wall. In this way you can at least consider the waves in a 3 dimensional domain.
ngj is offline   Reply With Quote

Old   April 11, 2013, 08:13
Default
  #339
New Member
 
Jan Löhrmann
Join Date: Sep 2010
Posts: 21
Rep Power: 7
JanL is on a distinguished road
Dear Niels,

in Post #105 / #106 you were discussing the specific terms for omega when using combinedWaves consisting of potentialCurrent and stokesFirst. Could you shed some light into it, if the encounter frequency or the cyclic frequency should be used?
I was playing around a bit and when I used the cyclic frequency, the resulting amplitude looked ok, but the wave was out of phase (obviously).
When using for "period" and "omega" the respective terms for encounter conditions the wave was in phase but now the amplitude dropped to approx half after leaving the relaxationZone. That could be, as you might have mentioned back then, because the dispersion relation of omega^2/k=g isn't valid anymore, as long as k isn't changed accordingly. But if I change k, then I wouldn't have the original wavelenght anymore!?
Am I missing something here???

Best regards
Jan

Last edited by wyldckat; December 28, 2013 at 08:56. Reason: updated the link to the other post, given the transfer of posts from the news thread
JanL is offline   Reply With Quote

Old   April 11, 2013, 08:28
Default
  #340
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Hi Jan,

I was more making enquiries, since I was also in doubt myself, hence I cannot answer your question.

If I recall correctly, I suggested to use stream function waves instead, where you can directly specify the net current and get the correct frequencies and wave lengths.

Kind regards

Niels
ngj is offline   Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Other Topics at OpenFOAM Workshop Milan 2008 hjasak OpenFOAM 2 October 26, 2013 04:33
Sections / Topics in CFD Wiki Roberthealy1 CFD-Wiki 6 August 23, 2007 17:58
CFD Related Educational Programmes Jonas Larsson Main CFD Forum 3 February 9, 2007 11:11
project topics vivekanand CFX 0 October 27, 2004 05:17
Advanced Topics in Aerodynamics Antonio Filippone Main CFD Forum 0 August 28, 1999 12:16


All times are GMT -4. The time now is 23:02.