|
[Sponsors] |
[waves2Foam] Starting issues with OpenFOAM 2.1.1 and spilling breaker using wave2foam |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
January 25, 2013, 00:19 |
Starting issues with OpenFOAM 2.1.1 and spilling breaker using wave2foam
|
#1 |
New Member
Hf
Join Date: Nov 2012
Posts: 29
Rep Power: 14 |
Hello Niels,
Months ago I started to learn OpenFOAM v2.1.1 and I'm interested in wave generation and further wave-structure interaction within the framework of OF. It's great to see that you have developed a toolbox. I am trying to learn it by first running the tutorials within the wave2foam package. Currently as you said, the SVN is currently down (see: http://openfoamwiki.net/index.php/Main_Page). I downloaded the package from a source I have forgotten, but I copied the code into the my home directory and it seems that it's compiled successfully, as I can run all the tutorials except periodicSolitary and 3Dwaves. I reported part of the info below, could you please take some time to help me check what's going wrong? Thanks in advance. 1. periodicSolitary In blockMesh... Reading patches section --> FOAM Warning : From function blockMesh::createTopology(IOdictionary&) in file blockMesh/blockMeshTopology.C at line 129 Old-style cyclic definition. Splitting patch cyclic1 into two halves cyclic1_half0 and cyclic1_half1 Alternatively use new 'boundary' dictionary syntax. In setWaveField... Reading field alpha --> FOAM FATAL IO ERROR: Cannot find patchField entry for cyclic cyclic1_half0 Is your field uptodate with split cyclics? Run foamUpgradeCyclics to convert mesh and fields to split cyclics. 2. 3Dwaves faceSet /opt/openfoam211/bin/tools/RunFunctions: line 47: faceSet: command not found ==== Converting faces on zone "f0" into baffles. --> FOAM FATAL ERROR: Cannot find faceZone "f0" Valid zones are 0 ( ) From function createBaffles in file createBaffles.C at line 175. ==== setsToZones Create polyMesh for time = 0 --> FOAM FATAL ERROR: Cannot find file "" in directory "polyMesh/sets" in times 0 down to constant From function Time::findInstance(const fileName&, const word&, const IOobject::readOption, const word&) in file db/Time/findInstance.C at line 140. Last edited by jasonchen; January 25, 2013 at 00:36. |
|
January 25, 2013, 00:43 |
|
#2 |
New Member
Hf
Join Date: Nov 2012
Posts: 29
Rep Power: 14 |
Hello Niels,
Another question about the breaking wave validation case in your paper, 3.3 As there is slope in the computational domain, fig 8, did you use snappyHexMesh to generate the meshes? The geometry is rather simple, but by using snappyHexMesh, I have to prepare a STL file, and input a large number of parameters in snappyHexMeshDict. Have you got any idea to easily prepare the required files? Regards, Jason |
|
January 27, 2013, 16:37 |
|
#3 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Jason,
With respect to the cyclic and the baffles, apparently the syntax has changed to your version of OF from the version I originally developed waves2Foam in. When you have figured out how to solve it, please write me, so I can modify the tutorials. Secondly, I used my own small matlab-script to create the mesh. I will upload the mesh files here as soon as possible. Kind regards, Niels |
|
January 28, 2013, 16:48 |
|
#4 |
New Member
Hf
Join Date: Nov 2012
Posts: 29
Rep Power: 14 |
Hi Niels,
Thanks for your quick reply. Now i managed to creat a mesh using blockMesh. I modified the waveProperties file for waveFlume to simulate the spilling breaker case. The file is copied below. Is it ok to specify initializationName as inlet in this case. // A list of the relaxation zones in the simulation. The parameters are given // in <name>Coeffs below. relaxationNames (inlet); initializationName inlet; pName p_rgh; inletCoeffs { // Wave type to be used at boundary "inlet" and in relaxation zone "inlet" waveType cnoidalFirst; Tsoft 2; depth 0.400000; period 2; direction (1 0 0); height 0.125; // Specifications on the relaxation zone shape and relaxation scheme relaxationZone { relaxationScheme Spatial; relaxationShape Rectangular; beachType Empty; relaxType INLET; startX (-8 0.0 0); endX (-4 0.0 0.1); orientation (1.0 0.0 0.0); } }; Another big problem is that when i run the case using Allrun script, either w/ or w/t setWaveParameters, the waveProperties file under constant directory is automatically replaced with one using stokeFirst, which is exactly the file for waveFlume case. And for the run with setWaveParameters step, it complains that period is not specified for stokeFirst. Do you have any idea about this? Could you please help me check the file or send me your version of input file for this case? Thanks. Jason |
|
January 28, 2013, 17:04 |
|
#5 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Jason,
With respect to the initializationName, you can use whatever sub-dictionary, which you have defined. With respect to the setWaveParameters, then you have to specify input in waveProperties.input. Then a correct waveProperties file is generated, if all input is given correctly in waveProperties.input (look at section 4.1.1. on the wiki: http://openfoamwiki.net/index.php/Co...WaveParameters or the 3Dwaves tutorial). Also, please note that the Allrun script is tailored for the specific tutorial, thus since setWaveParameters is not used in that tutorial, a tailored waveProperties file is distributed with the tutorial. Kind regards, Niels P.S. Good that you got your mesh working. |
|
January 29, 2013, 04:40 |
|
#6 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
@Jason: You can find the mesh I used here: http://www.student.dtu.dk/~ngja/mesh.tar.gz
Kind regards, Niels Last edited by wyldckat; September 2, 2018 at 17:54. Reason: removed answer to another post on the main thread |
|
April 2, 2013, 12:53 |
spilling breaker using wave2foam
|
#7 | |
New Member
Hf
Join Date: Nov 2012
Posts: 29
Rep Power: 14 |
Quote:
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 |
||
April 2, 2013, 18:16 |
|
#8 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
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 |
|
April 8, 2013, 11:52 |
|
#9 | |
New Member
Hf
Join Date: Nov 2012
Posts: 29
Rep Power: 14 |
Quote:
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? |
||
April 8, 2013, 12:46 |
|
#10 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
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 |
|
July 15, 2015, 11:46 |
|
#11 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
I used waveFoam test the spilling breaker case of Kirby's experiment with k-w turbulence model. however the omega always collapse. I want to know did you use turblunce closure for wave breaking? Best regards Fan fei |
||
July 15, 2015, 12:43 |
|
#12 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
Have you solve this question now? Best regards Fan Fei |
||
|
|