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

[IHFOAM] The IHFOAM Thread

Register Blogs Community New Posts Updated Threads Search

Like Tree57Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 11, 2020, 13:07
Default wave and current
  #321
Member
 
Ali
Join Date: Oct 2013
Location: St John's Canada
Posts: 31
Rep Power: 12
ashim is on a distinguished road
Hello,


If anyone interested in wave and current simulation at the same time in OpenFAOM-1912, you can use the attached files. I have changed the source code directly. That mean you need to replace the original files with attached files in waveModel directory. After recompiling the code, you just need to add the following entry in your waveProperties file.



uCurrent (2.196 0.0 0.0); // values are positive



I have already tested the code for two cases. It works fine. I hope it will help someone.


Ali
Attached Files
File Type: zip waveModel.zip (5.7 KB, 38 views)
saeed.barzegar.v likes this.
ashim is offline   Reply With Quote

Old   May 11, 2020, 17:54
Default
  #322
Senior Member
 
IHFOAM Team's Avatar
 
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 120
Rep Power: 9
IHFOAM Team is on a distinguished road
Hi Saeed

Quote:
However, if you need it immediately, you can have a look at Pablo's olaFlow work
This is the IHFOAM thread, please add to this thread just open source codes that can improve IHFOAM or/and that have been fully validated.

Cheap copies of IHFOAM with well-known numerical issues and wrong implementations have their own threads.

Regards,
IHFOAM Team
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   May 11, 2020, 17:59
Default
  #323
Senior Member
 
IHFOAM Team's Avatar
 
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 120
Rep Power: 9
IHFOAM Team is on a distinguished road
Hi Ali,

Quote:
Originally Posted by ashim View Post
If anyone interested in wave and current simulation at the same time in OpenFAOM-1912, you can use the attached files. I have changed the source code directly.
This numerical approach is wrong. Please, try to validate with some laboratory data ( Kemp&Simmons [1982] or Umeyama [2005]) and you will see that it does not work.

Regards,
IHFOAM Team.
saeed.barzegar.v likes this.
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   May 26, 2020, 14:56
Default Long crested wave
  #324
New Member
 
milad
Join Date: Jun 2013
Posts: 7
Rep Power: 13
majid_m87 is on a distinguished road
Hi
I am using OpenFoam v1812 and I was wondering how I can modify waveDict that I get a Long Crested wave (irregular waves in one direction)? What is the maximum number of wave components for multidirectional irregular waves?

Thank you and I look forward to hearing from you.

Best regards

Majid
majid_m87 is offline   Reply With Quote

Old   May 29, 2020, 12:35
Default
  #325
Senior Member
 
IHFOAM Team's Avatar
 
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 120
Rep Power: 9
IHFOAM Team is on a distinguished road
Hi Majid,

Quote:
how I can modify waveDict that I get a Long Crested wave (irregular waves in one direction)? What is the maximum number of wave components for multidirectional irregular waves?
If you want to generate irregular waves in one direction, you have to define the wave frequency spectrum for the target direction, and 0 density for the others directions.

There is not a predefined maximum number of wave components. Please, take a look to the tutorial:
~/OpenFOAM/OpenFOAM-v1912/tutorials/multiphase/interFoam/laminar/waves/irregularMultiDirection/

Regards,
IHFOAM Team
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   June 3, 2020, 09:53
Post Wave simulations irregular waves
  #326
New Member
 
Jente Vercammen
Join Date: Mar 2020
Posts: 9
Rep Power: 6
Jekke123456789 is on a distinguished road
Hello IHFOAM,


I am trying to create irregular waves and calculate the wallshear stress at the bottom at a bump. This is happening in a wave flume of 25 m and the berm located at 17 m .
Can you help me to set up the correct boundary conditions? with OpenFOAM-v1812



The waves are made with a series of sinus waves which repsresent a wave train wit H_s 0.19 m and T_p = 1.8s



I have the following:
for alpha water:

Code:
dimensions      [0 0 0 0 0 0 0];

internalField   uniform 0;

boundaryField
{
    inlet
    {
        type            waveAlpha;
        value           uniform 0;
    }

    outlet
    {
        type            zeroGradient;
    }

    ground
    {
        type            zeroGradient;
    }

    sides 
    {
        type            empty;
    }

    top
    {
        type            inletOutlet;
        inletValue      uniform 0;
        value           uniform 0;
    }
}
For k:

Code:
dimensions      [0 2 -2 0 0 0 0];

internalField   uniform 0.0030375;  // or should this be better like 0.000001

boundaryField
{
    inlet
    {
        type            zeroGradient; // or a fixed value???
    }

    outlet
    {
        type            zeroGradient;
    }

    ground
    {
        type            kqRWallFunction;
        value           $internalField;
    }

    top
    {
        type            inletOutlet;
        inletValue      $internalField;
        value           $internalField;
    }

    sides
    {
        type            empty;
    }

}
for omega:

Code:
dimensions      [0 0 -1 0 0 0 0];

internalField   uniform 0.1470;


boundaryField
{
    
    inlet
    {
        type            fixedValue; // or should this be also a zero gradient
        value           $internalField;
    }

    outlet
    {
        type            zeroGradient;
    }

    top
    {
        type            inletOutlet;
        inletValue      $internalField;
        value           $internalField;
    }

    ground
    {
        type            omegaWallFunction;
        value           $internalField;
    }
    

    sides
    {
        type            empty;
    }
}
for nut

Code:
dimensions      [0 2 -1 0 0 0 0];

internalField   uniform 0; //uniform 4.822e-3;

boundaryField
{
    inlet
    {
        type            calculated;
        value           $internalField;
    }

    outlet
    {
        type            calculated;
        value           $internalField;
    }
    ground
    {
        type            nutkRoughWallFunction;
        Ks              uniform 0.0083;
        Cs              uniform 0.5;
        value           $internalField;
    }
    top
    {
        type            calculated;
        value           $internalField;
    }

    sides 
    {
        type            empty;
    }
}
for p_rgh
Code:
dimensions      [1 -1 -2 0 0 0 0];

internalField   uniform 0;

boundaryField
{
    inlet
    {
        type            fixedFluxPressure;
        value           $internalField;
    }

    outlet
    {
        type            fixedFluxPressure;
        value           $internalField;
    }

    ground
    {
        type            fixedFluxPressure;
        value           $internalField;
    }

    sides 
    {
        type            empty;
    }

    top
    {
        type            totalPressure;
        p0              $internalField;
    }
}
for U
Code:
dimensions      [0 1 -1 0 0 0 0];

internalField   uniform (0 0 0);

boundaryField
{
    inlet
    {
        type            waveVelocity;
        value           $internalField;
    }

    outlet
    {
        type            waveVelocity; //noSlip
        value           $internalField;
    }

    sides 
    {
        type            empty;
    }

    ground
    {
        type            fixedValue;
        value           $internalField;
    }


    top
    {
        type            pressureInletOutletVelocity;
        value           uniform (0 0 0);
    }
}
Is this correct or should i change some things? I don't know how I should take a value of omega and k and nut. Can you help me with that?




Thanks in advance.


Jente
Jekke123456789 is offline   Reply With Quote

Old   June 3, 2020, 10:39
Default
  #327
Senior Member
 
IHFOAM Team's Avatar
 
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 120
Rep Power: 9
IHFOAM Team is on a distinguished road
Hi Jente,

Quote:
Can you help me to set up the correct boundary conditions? with OpenFOAM-v1812
We suggest you to update to the latest version (v1912), as you can use the same boundary conditions.
We recommend you to use in the inlet the zeroGradient boundary conditions.

Quote:
I don't know how I should take a value of omega and k and nut. Can you help me with that?
You can use this script:
https://github.com/GabiBarajas/Gener...kOmegaVALUES.m

It is based on:
https://www.cfd-online.com/Wiki/Turb...ary_conditions

Regards,
IHFOAM Team
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   June 3, 2020, 10:51
Default wave simulation
  #328
New Member
 
Jente Vercammen
Join Date: Mar 2020
Posts: 9
Rep Power: 6
Jekke123456789 is on a distinguished road
Quote:
Originally Posted by IHFOAM Team View Post
Hi Jente,

We suggest you to update to the latest version (v1912), as you can use the same boundary conditions.
We recommend you to use in the inlet the zeroGradient boundary conditions.

You can use this script:
https://github.com/GabiBarajas/Gener...kOmegaVALUES.m

It is based on:
https://www.cfd-online.com/Wiki/Turb...ary_conditions

Regards,
IHFOAM Team
I am not able to update as the company is working with this version for now. The other boundary condition are correct? (Is there so much differences)

For the values of k and omega, should I use the value of the near-bad wave orbital velocity? For the turbulence length is it correct to use 0.4 * height of the water = 0.4*0.75 ? Just a small question, is this value only a initial guess and will it change during the simulation?

I will already try to run this, as I am using wall functions and this means y+ should be higher than 30 but since my mesh is very small and the bump is only 3 cm high. My value of y+ descend to 12 at the start of the berm. Should this be a problem because I read somewhere that the k omega SST could also work with lower than 30 and still give good results.


Thanks in advance,
Kind regards,
Jente
Jekke123456789 is offline   Reply With Quote

Old   June 19, 2020, 12:09
Default OpenFoam generation of waves
  #329
New Member
 
Jente Vercammen
Join Date: Mar 2020
Posts: 9
Rep Power: 6
Jekke123456789 is on a distinguished road
Hi IHFoam team,


I have done some simulations with previous shown set-ups. I have only the problem that the waves are decreasing in wave heights to much. Even with laminar turbulence model the wave height is drastically reduced. Is there some way to adjust the interaction with the air and the water to have less energy dissipation?


Further I have some small questions:
  1. I would like to have some information to read about the wave generation and absorption of IHFoam such as Stokes II and the irregular model. Are there some interesting papers ?
  2. I read something about reaxation methods and zone where the waves are build ub and than a working zone and a zone for damping.Is this the same for what interfoam does in Openfoam.com
  3. what is the role of the active wave absorption at the inlet of the wave properties
    and the absorption is only available with shallow water but my waves ar just located in transitional water. Will this play a big role?
I hope that you can help with my questions, These are more important to understand the model. I didn't found so much information for these tutorials (whereas for waves2Foam and olaflow there is some information but I think interfoam (and the tutorials from ihfoam) are somthing different)


Thanks in advance!
Kind regards
Jente
Jekke123456789 is offline   Reply With Quote

Old   July 1, 2020, 09:16
Default
  #330
New Member
 
Masoumeh
Join Date: Oct 2019
Posts: 21
Rep Power: 7
ms.hashempour is on a distinguished road
Dear IHFoam team:

In my thesis I need combination of wave and current + multiphaseInterFoam. But I cant find any tutorial of this.

Do we have any solver of wave+current?


Would you please help me?
ms.hashempour is offline   Reply With Quote

Old   July 15, 2020, 03:16
Default
  #331
Senior Member
 
IHFOAM Team's Avatar
 
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 120
Rep Power: 9
IHFOAM Team is on a distinguished road
Hi ms.hashempour,

Quote:
Do we have any solver of wave+current?
We have not released the waves&current implementation but we are planning to do it very soon.

Best Regards,
IHFOAM Team
ms.hashempour likes this.
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   July 15, 2020, 03:30
Default
  #332
Senior Member
 
IHFOAM Team's Avatar
 
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 120
Rep Power: 9
IHFOAM Team is on a distinguished road
Hi Jekkem

Quote:

Is there some way to adjust the interaction with the air and the water to have less energy dissipation?
Yes, look for Brecht Devolder thesis and the Larsen&Fuhrman Turbulence model.

Quote:
I would like to have some information to read about the wave generation and absorption of IHFoam such as Stokes II and the irregular model. Are there some interesting papers ?
Please, look at the references sub-section:
https://ihfoam.ihcantabria.com/references/

Quote:
I read something about reaxation methods and zone where the waves are build ub and than a working zone and a zone for damping.Is this the same for what interfoam does in Openfoam.com
No, waves absorption is based on Schaffer (2000), relaxation zones are a different approach.

Quote:
what is the role of the active wave absorption at the inlet of the wave properties and the absorption is only available with shallow water but my waves ar just located in transitional water. Will this play a big role?
So far, we just have released the shallow waves absorption; yes, if you use for intermediate or deep waves, it will not work properly.


Best Regards,
IHFOAM Team
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   August 31, 2020, 09:56
Default
  #333
New Member
 
milad
Join Date: Jun 2013
Posts: 7
Rep Power: 13
majid_m87 is on a distinguished road
Quote:
Originally Posted by IHFOAM Team View Post
Hi Majid,

If you want to generate irregular waves in one direction, you have to define the wave frequency spectrum for the target direction, and 0 density for the others directions.

There is not a predefined maximum number of wave components. Please, take a look to the tutorial:
~/OpenFOAM/OpenFOAM-v1912/tutorials/multiphase/interFoam/laminar/waves/irregularMultiDirection/

Regards,
IHFOAM Team

Hi,
Thank you for your help. I did as you said, but still I couldn't get the right surface elevation from IHFOAM, you can find a plot for comparison of CFD simulation with IHFoam and Target surface Elevation. I will appreciate that you take a look at the graph and help me with the waveDict configuration.


Thank you and I look forward to hearing from you


Kind regards

Majid
Attached Images
File Type: jpg Irregular_CFD_IHFOAM.jpg (55.2 KB, 25 views)
majid_m87 is offline   Reply With Quote

Old   September 2, 2020, 03:04
Default
  #334
New Member
 
Isnard Baptiste
Join Date: Jul 2020
Location: France
Posts: 11
Rep Power: 6
Baptiste is on a distinguished road
Hello IHFoam Team,
I woul like to know if it's possible to get the Random waves interaction with three moored buoys (3D) tutorial we cabs see on your website and how to download it?

Thanks for your answer.

Have a nice day.
Baptiste is offline   Reply With Quote

Old   September 14, 2020, 05:21
Default
  #335
Senior Member
 
IHFOAM Team's Avatar
 
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 120
Rep Power: 9
IHFOAM Team is on a distinguished road
Hi Baptiste,

Quote:
I woul like to know if it's possible to get the Random waves interaction with three moored buoys (3D) tutorial we cabs see on your website and how to download it?
We have not planned to open this case to general public yet, we are just sharing it with our partners.
Please, contact us here if you want to discuss a potential collaboration:
ihfoam@ihcantabria.com

Regards,
IHFOAM Team
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   September 29, 2020, 06:49
Default
  #336
Member
 
philip lu
Join Date: Aug 2019
Posts: 87
Rep Power: 7
philiplu is on a distinguished road
Hello IHFoam Team,
in the OF-wave-tutorials (e.g. v2006) of "icoFoam" under "multiphase", one result-item is
alphaPhi0.water

my question is: what it refers to exactly?


thank you in advance

PS: this question is of OF-waves, but I assume OF-waves was originally from IH, right, or?
philiplu is offline   Reply With Quote

Old   October 1, 2020, 03:51
Default
  #337
Senior Member
 
IHFOAM Team's Avatar
 
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 120
Rep Power: 9
IHFOAM Team is on a distinguished road
Hi Philip,

Quote:
this question is of OF-waves, but I assume OF-waves was originally from IH, right, or?
Yes, you are correct, the wave module included in ESI's official release is based on the work through all these years by IH Cantabria.
You can find all our tutorials in: ~/OpenFOAM/OpenFOAM-v2006/tutorials/multiphase/interFoam/laminar/waves/

However, those test cases are run with the solver namedd interFoam which does not use the variable alphaPhi0.water at all.

Best Regards,
IHFOAM Team
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   October 1, 2020, 06:49
Default
  #338
Member
 
philip lu
Join Date: Aug 2019
Posts: 87
Rep Power: 7
philiplu is on a distinguished road
Hello IHFoam Team,

first, many thanks for the reply.

yes, you'r right, interFoam and exactly I ran a wave-case unter this solver, i.e. the folder

~/OpenFOAM/OpenFOAM-v2006/tutorials/multiphase/interFoam/laminar/waves/

and got the output of 'alphaPhi0.water' as one of the results, you can try it


best
philiplu is offline   Reply With Quote

Old   October 1, 2020, 09:36
Default
  #339
Senior Member
 
IHFOAM Team's Avatar
 
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 120
Rep Power: 9
IHFOAM Team is on a distinguished road
Hi Philip,

Quote:
and got the output of 'alphaPhi0.water' as one of the results, you can try it
Yes, you are right.

Sorry! My bad! (I checked with our own simplified version that I normally run to minimize time and space).

alphaPhi0.water is needed by MULES for a correct restart (flux from previous time-step).

Best Regards,
IHFOAM Team
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   October 2, 2020, 06:23
Default
  #340
Member
 
philip lu
Join Date: Aug 2019
Posts: 87
Rep Power: 7
philiplu is on a distinguished road
Hello IHFoam Team,

thanks indeed for the reply

sure, I've now the answer, so by closing my "case", it's great, if you could brief bit the difference between the version of "IH" and the "IH" included in OF.

thank you in advance and if you're too busy to come to this, sorry in advance
philiplu is offline   Reply With Quote

Reply


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
Divergence detected in AMG solver: k when udf loaded google9002 Fluent UDF and Scheme Programming 3 November 7, 2019 23:34
udf problem jane Fluent UDF and Scheme Programming 37 February 20, 2018 04:17
UDF velocity profile willroca Fluent UDF and Scheme Programming 2 January 10, 2016 03:13
Error messages atg enGrid 7 August 30, 2013 11:16
Phase locked average in run time panara OpenFOAM 2 February 20, 2008 14:37


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