CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Community Contributions

[waves2Foam] Waves2Foam Related Topics

Register Blogs Community New Posts Updated Threads Search

Like Tree162Likes

Closed Thread
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 11, 2012, 05:14
Default
  #161
New Member
 
Feng
Join Date: Oct 2011
Posts: 6
Rep Power: 14
fg118 is on a distinguished road
Hi Niels,

I have try to generate focus wave as post #47 suggested with combineWaves. The focus wave is really generated, but I am confused with the focus time and focus point. With newwave method, when you input focus time and focus point, the focus wave will be generated at focus point on focus time. But with combineWaves, the focus time and focus point seems not on the input value. I have shift each wave phase with omega(i)*t(focus)-k(i)*x(focus). Any suggestion?

Best Regards

Feng
fg118 is offline  

Old   October 11, 2012, 10:23
Default 5th order Stokes wave issue
  #162
Senior Member
 
Kevin Smith
Join Date: Mar 2009
Posts: 104
Rep Power: 17
kev4573 is on a distinguished road
Hi Niels,

I am trying to use the 5th order Stokes theory to simulate deep water waves. However it seems that the mean water level gets shifted by about the amplitude of the wave. I'd expect some shift of the mean level on the order of the second/third order wave amplitudes, but the results I am seeing seem odd to me.

Case: https://www.dropbox.com/s/q60gv6pcuq9z2k8/wfd_5th_problem.tar.gz

Kind regards,
Kevin
Attached Files
File Type: pdf alldata_set3.pdf (50.2 KB, 105 views)
kev4573 is offline  

Old   October 12, 2012, 10:22
Default
  #163
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Hi Kevin,

I agree, it does look weird - do not think I ever tried running 5th order - merely implemented it for fun

I am out of the office for a couple of days, but I will try to get a change to look into it. If you stumble over a bug before that time, please report it here.

Kind regards,

Niels

P.S. What is the vertical resolution/sample accuracy relative to the reported error?
ngj is offline  

Old   October 15, 2012, 10:24
Default
  #164
Senior Member
 
Kevin Smith
Join Date: Mar 2009
Posts: 104
Rep Power: 17
kev4573 is on a distinguished road
Niels,

The cell size in the vertical is 0.00333m and the shift in mean water level is about equal to the wave amplitude (0.0125m).

Cheers,
Kevin
kev4573 is offline  

Old   October 15, 2012, 20:10
Default
  #165
New Member
 
ross
Join Date: Aug 2012
Posts: 16
Rep Power: 13
rosswin is on a distinguished road
Quote:
Originally Posted by ngj View Post
Hi Ross,

If you have tried the standard tutorial "damBreak", then you will see that you will get a directory for each time data is outputted.

If you do not have those in the output, when running waveFoam, then something is wrong. If you are running in 1.7.1. then all you need to do is to execute "./Allwmake" to compile library, utilities and solvers and nothing else; and it has proven to work.

Which tutorials in waves2Foam have you been running?

/ Niels
Hi Niels,

Sorry for the late reply and thank you for trying to help me out.

I have uninstalled all openFOAM versions and reinstalled OpenFOAM 171. AS of yet I haven't run any waves2Foam tutorials but I have managed to run A few OpenFOAM tutorials and they worked.
At the moment I am reinstalling waves2Foam: I am stuck on Instruction 2 of this installation https://github.com/ogoe/waves2Foam

I have run ./Allwmake and I get this response
Code:
make: Target `application' not remade because of errors.
I then changed my directory to /opt/openfoam171 and executed ./Allwmake again
for which I got this response
Code:
make: Target `application' not remade because of errors.
after a long list of errors.


Regards
Ross
rosswin is offline  

Old   October 16, 2012, 09:48
Default
  #166
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Hi all,

@Kevin: You are using a solution to the linear dispersion relation, however, you are using a fifth order stokes theory. This does not match, which results in a negative stokes drift in your case, hence a lowering of the water level.

In the attached figure, the black line is with correct k(period,depth,height), whereas the white line is the incorrect linear dispersion relation.

@Ross: You give far too little information to resolve your problem and furthermore, you have achieved the source code from a to me unknown source. Try download the latest release directly from the SVN given on the wiki.

Kind regards,

Niels
Attached Images
File Type: jpg mwlSlope.jpg (13.5 KB, 133 views)
ngj is offline  

Old   October 16, 2012, 11:16
Default
  #167
Senior Member
 
Kevin Smith
Join Date: Mar 2009
Posts: 104
Rep Power: 17
kev4573 is on a distinguished road
Hi Niels,

Great, thank you for taking the time to look at this. I noticed the negative flow from the domain and now it makes sense.

Kind regards,
Kevin
kev4573 is offline  

Old   October 16, 2012, 11:36
Default
  #168
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
No problem - I can really recommend using setWaveParameters, because it does resolve this type of problems, and the dispersion relation for the specific wave theory is already implemented.

/ Niels
ngj is offline  

Old   October 16, 2012, 12:03
Default
  #169
Senior Member
 
Kevin Smith
Join Date: Mar 2009
Posts: 104
Rep Power: 17
kev4573 is on a distinguished road
That's what I started using for the fifth order waves and it seems to be working well now.

By the way, I did take a good look through the 5th order theory implementation and was unable to find any mistakes .
ngj likes this.
kev4573 is offline  

Old   October 17, 2012, 03:15
Default
  #170
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Kevin,

Did you find the time to test the compilation of waveFoam based on 2.1 on 2.1.1?

/ Niels
ngj is offline  

Old   October 18, 2012, 09:40
Default
  #171
Senior Member
 
Kevin Smith
Join Date: Mar 2009
Posts: 104
Rep Power: 17
kev4573 is on a distinguished road
Niels,

Yes the waveFoam solver based on 2.1.0 is cross compatible with 2.1.1 (no changes required).

Kevin
kev4573 is offline  

Old   October 18, 2012, 10:52
Default
  #172
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Hi Massoud,

I have been going through the solitary and as I see it, it is implemented as it is given in the reference already discussed.
I have updated the header, and it will come out later today with a large update. Please see the announcement thread.

Kind regards,

Niels
ngj is offline  

Old   October 22, 2012, 10:21
Default
  #173
Member
 
Nick
Join Date: Nov 2011
Location: Tongji University,Shanghai,China
Posts: 33
Blog Entries: 6
Rep Power: 14
sunliming is on a distinguished road
Hi,ngj:
I'm now working on wind-wave interaction problems for wind engineering application as my master's thesis, and my foremost concern is wind profile over waves rather than wave itself. I've read your paper about the wave generation toolbox, very nice job. But I wonder whether your toolbox can take into account of wind forces on waves(given a natural wind field rather than a uniform zero) and whether the coupling effect of air and water can be considered. I wanna use LES but your toolbox is based on RANS(if I'm right), is that compatible with LES for upper wind field?
Thank you in advance!
sunliming is offline  

Old   October 22, 2012, 11:16
Default
  #174
Senior Member
 
Dave
Join Date: Jul 2010
Posts: 100
Rep Power: 15
daveatstyacht is on a distinguished road
Sunliming,
Currently only uniform wind velocity has been implemented by adding:
wind (0 0 0) into the waveProperties file (default is uniform zero if omitted).

The addition of uniform wind was made primarily with moving objects (ships) in mind as before then only uniform zero was present. You could utilize existing boundary conditions like swak4foam to produce a wind gradient, however you would likely have to develop a modified version of wave2foam to avoid the profile being overwritten in the domain. Regarding LES and RANS, wave2foam is built on the interFoam solver which is generic in the choice of turbulence model (RANS, LES, Laminar).
daveatstyacht is offline  

Old   October 22, 2012, 23:47
Default
  #175
Member
 
Nick
Join Date: Nov 2011
Location: Tongji University,Shanghai,China
Posts: 33
Blog Entries: 6
Rep Power: 14
sunliming is on a distinguished road
Quote:
Originally Posted by daveatstyacht View Post
Sunliming,
Currently only uniform wind velocity has been implemented by adding:
wind (0 0 0) into the waveProperties file (default is uniform zero if omitted).

The addition of uniform wind was made primarily with moving objects (ships) in mind as before then only uniform zero was present. You could utilize existing boundary conditions like swak4foam to produce a wind gradient, however you would likely have to develop a modified version of wave2foam to avoid the profile being overwritten in the domain. Regarding LES and RANS, wave2foam is built on the interFoam solver which is generic in the choice of turbulence model (RANS, LES, Laminar).
Hi, Dave:
Thank you for your reply! But I'm still a little bit confused of "swak4foam to produce a wind gradient", I want to add uniform pressure gradient as a driving force for wind (like in channelFoam), can swak4Foam fullfil that? In interFoam two-phase flow is solved using a general U-equation, how to add the pressure gradient to air alone excluding the water part since the interface is unknown brefore solving?
sunliming is offline  

Old   October 23, 2012, 16:51
Default
  #176
Senior Member
 
Dave
Join Date: Jul 2010
Posts: 100
Rep Power: 15
daveatstyacht is on a distinguished road
Sunliming,
Swak4foam is a library that combines groovyBC and funkysetfields. It is a very flexible way to define boundary conditions and field values. This would be your best bet for being able to define a pressure gradient for air and not water (you could define a function for it). I can't really offer any specifics on how you actually go about setting up this with swak4foam since I haven't really used it. There is plenty of post about swak4foam and a OF wiki article on it.
daveatstyacht is offline  

Old   October 24, 2012, 03:33
Default
  #177
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Good morning,

Another option is that the boundary condition, wavePressure, in waves2Foam is based on the mixed type boundary condition, so it is relatively easy to give a pressure gradient in the air or an absolute value of the pressure.

How this would interact with the relaxation zones is not very clear on the other hand, but an inlet relaxation zone might not be of your interest?

Anyway, good luck

Niels
ngj is offline  

Old   October 24, 2012, 23:30
Default
  #178
Member
 
Nick
Join Date: Nov 2011
Location: Tongji University,Shanghai,China
Posts: 33
Blog Entries: 6
Rep Power: 14
sunliming is on a distinguished road
Dave and Niels,
Thank you for your advice, I'll try it out.
sunliming is offline  

Old   November 2, 2012, 09:14
Default
  #179
New Member
 
John Peng
Join Date: Oct 2012
Location: NL
Posts: 7
Rep Power: 13
janepen is on a distinguished road
Hi, Ngj,

I am quite curious which nonlinear dispersion formulae or codes used for fifth stokes wave. Could you please pass me some references or codes?


Regards,

John



Quote:
Originally Posted by ngj View Post
Hi all,

@Kevin: You are using a solution to the linear dispersion relation, however, you are using a fifth order stokes theory. This does not match, which results in a negative stokes drift in your case, hence a lowering of the water level.

In the attached figure, the black line is with correct k(period,depth,height), whereas the white line is the incorrect linear dispersion relation.

@Ross: You give far too little information to resolve your problem and furthermore, you have achieved the source code from a to me unknown source. Try download the latest release directly from the SVN given on the wiki.

Kind regards,

Niels
janepen is offline  

Old   November 2, 2012, 09:48
Default
  #180
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Hi John

Yes, I have found out that I lack some information in the header files. Here is the reference:

Code:
@article{ ISI:A1985AEB7500005,
Author = {FENTON, JD},
Title = {{A 5TH-ORDER STOKES THEORY FOR STEADY WAVES}},
Journal = {{JOURNAL OF WATERWAY PORT COASTAL AND OCEAN ENGINEERING-ASCE}},
Year = {{1985}},
Volume = {{111}},
Number = {{2}},
Pages = {{216-234}},
Publisher = {{ASCE-AMER SOC CIVIL ENGINEERS}},
Address = {{345 E 47TH ST, NEW YORK, NY 10017-2398}},
Type = {{Article}},
Language = {{English}},
Affiliation = {{FENTON, JD (Reprint Author), UNIV NEW S WALES,SCH MATH,KENSINGTON,NSW 2033,AUSTRALIA..}},
ISSN = {{0733-950X}},
Research-Areas = {{Engineering; Water Resources}},
Web-of-Science-Categories  = {{Engineering, Civil; Engineering, Ocean; Water Resources}},
Number-of-Cited-References = {{13}},
Times-Cited = {{134}},
Journal-ISO = {{J. Waterw. Port Coast. Ocean Eng.-ASCE}},
Doc-Delivery-Number = {{AEB75}},
Unique-ID = {{ISI:A1985AEB7500005}},
}
The code is all implemented in waves2Foam.

Kind regards,

Niels
ngj is offline  

Closed Thread


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 Off
Pingbacks are On
Refbacks are On


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 05:29
Re-Project topics protocol STAR-CCM+ 0 March 22, 2016 05:25
Waves2Foam Related Topics seoseonguk OpenFOAM Running, Solving & CFD 0 March 1, 2016 22:18
Waves2Foam Related Topics seoseonguk OpenFOAM Running, Solving & CFD 0 March 1, 2016 22:14
Error: "Cannot find file points" related to changing parallelized code to serial? Suyf OpenFOAM Running, Solving & CFD 0 February 12, 2015 04:31


All times are GMT -4. The time now is 06:49.