|
[Sponsors] |
May 4, 2012, 07:08 |
|
#101 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Thanks Philipp!
@Björn: I tried to look a bit at it, but I am still somewhat confused. However, since Dominic's version is working, maybe one of you could wrap it up including a setWaveProperties file? @All: The surface sampling utility has been extended with functionObject-functionality. See more on the wiki. Best regards, Niels |
|
May 4, 2012, 11:15 |
|
#102 |
Member
Björn Windén
Join Date: Feb 2012
Location: National Maritime Research Institute, Tokyo, Japan
Posts: 37
Rep Power: 14 |
Hi Niels and Dominic. Just to report some findings, I tried the modified stokesFirst on a very fine mesh and found a discrepancy in amplitude of <1% and a discrepancy in encounter period of <0.01%.
combinedWaves with the same setup gives a 13.5% discrepancy in amplitude and 5% discrepancy in encounter period. It would be nice if the same could be achieved with combinedWaves though since it would allow for forward speed simulations with all the other wave types as well as Stoke's first without having to derive new expressions for all of them. I suspect that the problem might be that U and alpha are corrected separately and while combinedWaves adds the velocity contributions, it doesn't add the translation of the free surface. This means that the "wrong" omega hast to be set to ensure that the surface behaves correctly. This in turn means that the waves get the wrong velocity distribution though which may be why they grow when set free from the relaxation. I may just be rambling here since I'm also confused by this so please correct me if i got something wrong. That would mean that the problem could be solved by adding a translation of eta in potentialCurrent somehow so that this behaviour in the modified stokesFirst Code:
scalar eta = H_ / 2.0 * Foam::cos(omega_ * time - (k_ & x) + (k_ & current_) * time + phi_) * factor(time) + seaLevel_; //Björn |
|
May 4, 2012, 11:28 |
|
#103 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi
First, I have to get a small detail clarified. The waveNumber in the modified stokesFirst is what waveNumber? Is it the solution to the current-corrected dispersion relation? Nonetheless, what would happen if you adopt that particular waveNumber and set the cyclic frequency equal to Code:
omega = 2 PI / period + k_ & current Kind regards, Niels P.S. Congratulations on the results, it is good accuracy! |
|
May 17, 2012, 13:20 |
|
#104 |
New Member
Rita Carvalho
Join Date: Apr 2012
Posts: 6
Rep Power: 14 |
Dear all,
I need some help. I cannot run waveFoam, command not found because I have the following error: user@gisvm:~/OpenFOAM/user-2.1.0/wav...rs21/waveFoam$ dir alphaCourantNo.H correctPhi.H pEqn.H waveDyMFoam alphaEqn.H createFields.H setDeltaT.H waveFoam.C alphaEqnSubCycle.H Make UEqn.H waveFoam.dep user@gisvm:~/OpenFOAM/user-2.1.0/wav...rs21/waveFoam$ wmake SOURCE=waveFoam.C ; g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/opt/openfoam210/src/transportModels -I/opt/openfoam210/src/transportModels/incompressible/lnInclude -I/opt/openfoam210/src/transportModels/interfaceProperties/lnInclude -I/opt/openfoam210/src/turbulenceModels/incompressible/turbulenceModel -I/opt/openfoam210/src/finiteVolume/lnInclude -DOFVERSION=20 -I./../../../../src/lnInclude -IlnInclude -I. -I/opt/openfoam210/src/OpenFOAM/lnInclude -I/opt/openfoam210/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linuxGccDPOpt/waveFoam.o In file included from waveFoam.C:84:0: alphaEqnSubCycle.H: In function ‘int main(int, char**)’: alphaEqnSubCycle.H:3:15: error: ‘piso’ was not declared in this scope /opt/openfoam210/src/finiteVolume/lnInclude/readPISOControls.H:3:15: warning: unused variable ‘nOuterCorr’ /opt/openfoam210/src/finiteVolume/lnInclude/readPISOControls.H:15:16: warning: unused variable ‘transonic’ /opt/openfoam210/src/finiteVolume/lnInclude/readPISOControls.H:3:15: warning: unused variable ‘nOuterCorr’ /opt/openfoam210/src/finiteVolume/lnInclude/readPISOControls.H:6:15: warning: unused variable ‘nCorr’ /opt/openfoam210/src/finiteVolume/lnInclude/readPISOControls.H:12:16: warning: unused variable ‘momentumPredictor’ /opt/openfoam210/src/finiteVolume/lnInclude/readPISOControls.H:15:16: warning: unused variable ‘transonic’ /opt/openfoam210/src/finiteVolume/lnInclude/readTimeControls.H:38:8: warning: unused variable ‘maxDeltaT’ make: *** [Make/linuxGccDPOpt/waveFoam.o] Error 1 user@gisvm:~/OpenFOAM/user-2.1.0/wav...rs21/waveFoam$ Anyone can help me please ? Regards, rita |
|
June 7, 2012, 17:01 |
|
#105 |
Senior Member
kumar
Join Date: Mar 2009
Posts: 112
Rep Power: 17 |
Hi Niels,
Thanks a lot for publishing a very useful tool box for the ocean engineering community.I have installed OpenFOAM-2.1.0 on a CentOS release 5.6. So I follwed the directions here (http://openfoamwiki.net/index.php/Co...2Foam#waveFoam) for modifying my interFoam.C to waveFoam.C and Make/options file and Make/files file. I am getting errors when using wmake in waveFoam /////////////////////// ERRORS with wmake ///////////////////// -bash-3.2$ wclean -bash-3.2$ pwd /share/gecko/krishnak/OpenFOAM/krishnak-2.1.0/applications/waveFoam -bash-3.2$ wmake Making dependency list for source file waveFoam.C could not open file relaxationZone.H for source file waveFoam.C could not open file readWaveProperties.H for source file waveFoam.C SOURCE=waveFoam.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/share/gecko/krishnak/OpenFOAM/OpenFOAM-2.1.0/src/transportModels -I/share/gecko/krishnak/OpenFOAM/OpenFOAM-2.1.0/src/transportModels/incompressible/lnInclude -I/share/gecko/krishnak/OpenFOAM/OpenFOAM-2.1.0/src/transportModels/interfaceProperties/lnInclude -I/share/gecko/krishnak/OpenFOAM/OpenFOAM-2.1.0/src/turbulenceModels/incompressible/turbulenceModel -I/share/gecko/krishnak/OpenFOAM/OpenFOAM-2.1.0/src/finiteVolume/lnInclude -DOFVERSION=21 -I./../../../../src/lnInclude -IlnInclude -I. -I/share/gecko/krishnak/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude -I/share/gecko/krishnak/OpenFOAM/OpenFOAM-2.1.0/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/waveFoam.o waveFoam.C:48:28: fatal error: relaxationZone.H: No such file or directory compilation terminated. make: *** [Make/linux64GccDPOpt/waveFoam.o] Error 1 /////////////////////////////////////////////////////////////// This error is very similar to Feng's but my Make/files file and Make/options file seem to be ok. my Make/files is : /////////////////////////// waveFoam.C EXE = $(FOAM_USER_APPBIN)/waveFoam ///////////////////////////////////////// my Make/options file is: ////////////////////////////////// EXE_INC = \ -I$(LIB_SRC)/transportModels \ -I$(LIB_SRC)/transportModels/incompressible/lnInclude \ -I$(LIB_SRC)/transportModels/interfaceProperties/lnInclude \ -I$(LIB_SRC)/turbulenceModels/incompressible/turbulenceModel \ -I$(LIB_SRC)/finiteVolume/lnInclude \ -DOFVERSION=21 \ -I./../../../../src/lnInclude EXE_LIBS = \ -ltwoPhaseInterfaceProperties \ -lincompressibleTransportModels \ -lincompressibleTurbulenceModel \ -lincompressibleRASModels \ -lincompressibleLESModels \ -lfiniteVolume \ -L$(FOAM_USER_LIBBIN) \ -lwaves2Foam ////////////////////////////////////////////// I have also checked that in my FOAM_USER_LIBBIN, libwaves2Foam exists. For example, when I go to the FOAM_USER_LIBBIN folder libwaves2Foam.so is present /////////////////////////////// -bash-3.2$ cd $FOAM_USER_LIBBIN -bash-3.2$ pwd /share/gecko/krishnak/OpenFOAM/krishnak-2.1.0/platforms/linux64GccDPOpt/lib -bash-3.2$ ls libwaves2Foam.so ////////////////////////////////////////////////////// This is how I compiled waves2Foam library: I went to /share/gecko/krishnak/OpenFOAM/krishnak-2.1.0/lib/waves2Foam version=21 export WM_PROJECT_VERSION_NUMBER=$version echo $WM_PROJECT_VERSION_NUMBER wmake libso and there were no errors while making libwaves2Foam.so I cannot figure out my mistake. It would be great if you can suggest a fix. Sorry about the long post. Best regards and Thanks in advance Kumar |
|
June 7, 2012, 18:57 |
|
#106 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Kumar
Luckily, it seems quite straight forward. The Code:
-I./../../../../src/lnInclude As you have placed it elsewhere, the relative path points to a non-existing or wrong directory. Move the solver or modify the inlude-path and you should be all fine. Kind regards Niels |
|
June 7, 2012, 22:13 |
|
#107 |
New Member
Stefan
Join Date: Jan 2011
Location: Bremen
Posts: 20
Rep Power: 15 |
Hi Niels and others,
after having a good time with your tool already, I am trying to apply the Matlab functions to generate some stream function waves. What are the parameters EorS and uEorS? Best regards Stefan |
|
June 7, 2012, 23:19 |
|
#108 |
Senior Member
kumar
Join Date: Mar 2009
Posts: 112
Rep Power: 17 |
Hi Niels,
Thanks so much for the fix. And the quick reply In my machine ,wave2foam is here: /share/gecko/krishnak/OpenFOAM/krishnak-2.1.0/lib/waves2Foam so i copied waveFoam, just like you suggested /share/gecko/krishnak/OpenFOAM/krishnak-2.1.0/lib/waves2Foam/applications/solvers/solvers21/waveFoam and changed the options a little bit to -I./../../../../lnInclude and everything works very well. and i am right now looking at the wave flume tutorial result. What a wonderful tool .. Best regards Kumar |
|
June 8, 2012, 03:35 |
|
#109 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Good morning to all
@Kumar: You are welcome. @Stefan: It is a flag and a scalar comtroling the wave drift, i.e. stokes or eulerian drift. The scalar can be used to superimpose a current. Please do an svn update, as I have added a header in generateStreamFile.m Kind regards, Niels |
|
June 8, 2012, 05:22 |
|
#110 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Kumar,
I have just reread your reply, and merely out of curiosity: Does it mean that all of the include files are in a commen directory in /share/gecko/krishnak/OpenFOAM/krishnak-2.1.0/lib/ ? I am asking, because you are not entering the "src" directory in waves2Foam. / Niels |
|
June 8, 2012, 16:15 |
|
#111 |
Senior Member
kumar
Join Date: Mar 2009
Posts: 112
Rep Power: 17 |
Hi Niels,
I did not make a /src folder. I actually put all the folders such as / fvPatchFields, /include , etc directly under /waves2Foam. and my waves2Foam is here: /share/gecko/krishnak/OpenFOAM/krishnak-2.1.0/lib/waves2Foam So I believe I have all the files in a common waves2Foam folder. Thanks a lot Best regards Kumar |
|
June 12, 2012, 07:35 |
inviscid wave theory V.S. viscous solver
|
#112 |
Member
Albert Tong
Join Date: Dec 2010
Location: Perth, WA, Australia
Posts: 76
Blog Entries: 1
Rep Power: 15 |
Hi Niels and all other formers,
If I am going to consider viscous wave/flow around ocean structures, is it reasonable to use waveFoam? If it is yes, then why can we use wave theories that are based on inviscid assumption for wave generating and use viscous solver at the computational domain? Thanks very much.
__________________
Kind regards, Albert |
|
June 19, 2012, 01:25 |
Mesh motion based on wave forces
|
#113 |
New Member
Nima
Join Date: Feb 2012
Location: Perth, Western Australia
Posts: 13
Rep Power: 14 |
Dear Foamers
I have recently started to work on the gap resonance effect in the narrow gaps between multiple floating structures, Previously much of the works which have been done have considered the structures to be fixed, as far as I know about the mesh motion in OpenFOAM , most of the dynamic mesh motion solvers are based on a predefined motion dictionary , was wondering how I can let the software move the floating structure and relative mesh based on the forces acting on it at the same time instead of predefined motion by giving the amplitude of motion say heave, roll etc... Regards Nima |
|
June 19, 2012, 02:58 |
|
#114 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Good morning Nima,
Yes, it should be possible. You can look into the sixDoF-library. I have never tried using it, but it is probably the best place to begin. Kind regards, Niels |
|
July 16, 2012, 06:16 |
|
#115 |
New Member
Nima
Join Date: Feb 2012
Location: Perth, Western Australia
Posts: 13
Rep Power: 14 |
Dear Foamers
Just a quick question : Has anyone tried coupling waveFoam with different turbulence models so Far ? if so have you got successful results or not? Regards Nima |
|
July 16, 2012, 06:27 |
|
#116 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Nima,
Well the short answer is yes that turbulence models have been coupled with waveFoam, however, if you strictly stick to the turbulence formulations in OpenFoam, you will get poor results, as the turbulence formulation in OF does not consider the density in the equations, hence excessive diffusion of turbulence takes place over the interface, which results in rapid decay in the wave height. Therefore, you need to formulate the turbulence equations correctly, namely including density in the turbulence equations. Best regards, Niels |
|
July 23, 2012, 01:55 |
wave incident angle
|
#117 |
New Member
Nima
Join Date: Feb 2012
Location: Perth, Western Australia
Posts: 13
Rep Power: 14 |
Dear Friends
I am interested in studying the effect of different wave incident angles on my floating structures, obviously in a rectangular domain with rectangular relaxation zone I can't rotate my objects to achieve this , I was wondering if I can use cylindrical relaxation zone or not! I have seen the square pile tutorial but I don't understand why the inlet boundary patch is all round the circle ! then how about the outlet! a bit confused ! thanks for your help Regards Nima |
|
July 23, 2012, 05:42 |
|
#118 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Nima,
The general idea behind the circular relaxation zone (or the semi-circular for that matter), is simply to have the possibility of applying different shapes as a relaxation zone, and since the relaxation zone borders the boundary, then it is actually the relaxation zone rather than the boundary itself, which act as a combined inlet/outlet. It should be noted, however, as I have also mentioned in my journal article on the matter that you have to pay particular attention to the mesh generation, if you are using a circular domain with waves, since the mesh resolution changes with the radial distance. Otherwise, you could merely have your structure in the middle inside a spherical mesh and then rotate the mesh using e.g. GGI/AMI to change the orientation of the structure relative to a fixed angle of incidence in a rectangular computational domain. Kind regards, Niels |
|
July 23, 2012, 06:35 |
|
#119 | |
New Member
Nima
Join Date: Feb 2012
Location: Perth, Western Australia
Posts: 13
Rep Power: 14 |
Quote:
Thanks for your quick response I really appreciate the time and effort you put on it I think my question was a bit vague and complicated whereas my problem is not! to make things clear: I do have two floating objects inside a rectangular wave tank and want to observe the resonant behavior in the narrow gap in between the bodies , now I want to check my case against different wave incident angles and the only Idea that hit my mind was to change the shape of the computational domain as I could not find any other option for the angle of attack, To be honest I did not understand your above statement clearly and do not have any prior experience with GCI/AMI , The preferred option for me is to keep the rectangular domain shape and find a way to tell the solver that the wave is not normal to the objects wall boundaries! Regards Nima |
||
August 3, 2012, 10:04 |
Irregular wave theory
|
#120 |
New Member
Nima
Join Date: Feb 2012
Location: Perth, Western Australia
Posts: 13
Rep Power: 14 |
Hi
seems that no one has read my previous post but hopefully someone can answer my new question. I am trying to use irregular wave for my simulation, apparently it need a file named additionalWaveProperties to run can someone let me know what should be the content of the file or post a sample of the file in here Regards Nima |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Map of the OpenFOAM Forum - Understanding where to post your questions! | wyldckat | OpenFOAM | 10 | September 2, 2021 06:29 |
Re-Project topics | protocol | STAR-CCM+ | 0 | March 22, 2016 06:25 |
Waves2Foam Related Topics | seoseonguk | OpenFOAM Running, Solving & CFD | 0 | March 1, 2016 23:18 |
Waves2Foam Related Topics | seoseonguk | OpenFOAM Running, Solving & CFD | 0 | March 1, 2016 23:14 |
Error: "Cannot find file points" related to changing parallelized code to serial? | Suyf | OpenFOAM Running, Solving & CFD | 0 | February 12, 2015 05:31 |