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   October 5, 2020, 13:12
Default
  #341
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:
if you could brief bit the difference between the version of "IH" and the "IH" included in OF.
In our solver we have just added the new version of the porous solver, waves plus currrents and some new boundary conditions to link with out own in-house codes. We have removed also some parts of the code that for several applications we feel that we do not need it.

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

Old   October 6, 2020, 06:15
Default
  #342
Member
 
philip lu
Join Date: Aug 2019
Posts: 87
Rep Power: 7
philiplu is on a distinguished road
Hello, IHFOAM Team,

Thank you very much for the reply and explanations.


thanks, regards
philiplu is offline   Reply With Quote

Old   October 8, 2020, 07:04
Default
  #343
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 would like to know if its possible to generate 3D waves with a angle from the inlet. And if the answer is yes what parameter in waveDict I have to modify? Or to have quarter face waves I need to rotate my object?
Thank you in advance.
Best regards,
Baptiste
Baptiste is offline   Reply With Quote

Old   October 13, 2020, 05:36
Default
  #344
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:
Or to have quarter face waves I need to rotate my object?
Yes, always the best choice is to rotate your object, as the wave paddle absorption implemented can just deal with the perpendicular incoming waves to the patch.

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

Old   October 16, 2020, 02:52
Default
  #345
Member
 
philip lu
Join Date: Aug 2019
Posts: 87
Rep Power: 7
philiplu is on a distinguished road
Hello, IHFOAM Team,
question rephrased:
in your tutorial "Breaking solitary waves on a mild slope (2D)", the "U" in "outlet" of "0.org" shall be updated to
outlet { type noSlip; }
from
outlet { type waveVelocity; value uniform (0 0 0); }
why or is it correct?

yes, the outlet in this case is on bank top, i.e. is open/air (instead of inside water), so the "type waveVelocity;" of U needs update, but why "noSlip"?


thanks, best

Last edited by philiplu; November 10, 2020 at 03:19.
philiplu is offline   Reply With Quote

Old   November 3, 2020, 05:32
Default IHFoam GUI
  #346
New Member
 
Hattab Abdelhak
Join Date: Oct 2020
Posts: 8
Rep Power: 6
Doum2 is on a distinguished road
Hello IHFoam Team,
i need your help to solve a error when i use IHFoam GUI.
When i try to launch blockMesh commande , that show me error saying : BlockMesh not found. but i'm sure i can run blockmesh commande in terminal
any help ?!!
Doum2 is offline   Reply With Quote

Old   November 5, 2020, 07:22
Default
  #347
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 There,

Quote:
... BlockMesh not found. but i'm sure i can run blockmesh commande in terminal
When using IHFOAM-GUI you must select which version you are using by clicking in:
Edit --> Preferences
and setting the correct OpenFOAM folder.

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

Old   November 5, 2020, 15:38
Default help
  #348
New Member
 
Hattab Abdelhak
Join Date: Oct 2020
Posts: 8
Rep Power: 6
Doum2 is on a distinguished road
Quote:
Originally Posted by IHFOAM Team View Post
Hi There,

When using IHFOAM-GUI you must select which version you are using by clicking in:
Edit --> Preferences
and setting the correct OpenFOAM folder.

Best Regards,
IHFOAM Team
I'm sorry once again for my questions but this time I have a new error which appears after I run the set patches names command as you can see on the screenshots
I have checked the project folder and the blockMeshDict file exists with the settings I entered on IHFoam GUI.

any Idea?
Doum2 is offline   Reply With Quote

Old   November 6, 2020, 16:50
Default irregularMultiDirectional
  #349
New Member
 
Benjamin Norris
Join Date: Oct 2020
Location: California
Posts: 17
Rep Power: 6
bknorris is on a distinguished road
Hi IHFoam Team,

I have a brief question about the waveProperties file in the irregularMultiDirection tutorial. In this file, there are four blocks of input data that correspond to the required inputs in irregularMultiDirectionalWaveModel.C: wave period, height, phase, and direction.

For example, the waveHeights entry starts with...

waveHeights
57
(
(0.0022817 0.0021584 0.0019314 0.0016349 0.0013091 0.00099161 0.00071052 0.0004816 0.00030879 0.00018729 0.00010746 5.8323e-05 2.9944e-05 2.9944e-05 5.8323e-05 0.00010746 0.00018729 0.00030879 0.0004816 0.00071052 0.00099161 0.0013091 0.0016349 0.0019314 0.0021584 0.0022817)
etc.

My question is, why are these entries 57x26 and not 57x1? I gather the 57 refers to the number of wave components (analogous to frequencies in the spectrum from which they are derived), but what is the other dimension? Is it time?

Thank you in advance for any and all insight!

Ben

Last edited by bknorris; November 18, 2020 at 14:39. Reason: Solved my other issue
bknorris is offline   Reply With Quote

Old   November 24, 2020, 09:55
Default generate current only
  #350
New Member
 
Fonzzao
Join Date: Jul 2019
Posts: 13
Rep Power: 7
Panda School is on a distinguished road
Hello IHFOAM Team,

I would like to know if it is possible to generate current only? I do not want waves but wave absorption boundaries are needed to absorb waves induced by structures in current.

Thank you in advance.

Best regards,
Fonzzao
Panda School is offline   Reply With Quote

Old   December 1, 2020, 07:59
Default
  #351
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 Ben,

Quote:
My question is, why are these entries 57x26 and not 57x1?
To describe the three-dimensional, moving waves, we use the random-phase/amplitude model (in x, y and t-space) by considering the sum of a large number of propagating harmonic waves in x,y-space, in direction θ relative to the positive x-axis.

All the variables used for the OpenFOAM implementation of the three-dimensional definition of the free surface are defined as matrix X i, j, with “i” rows for the frequencies and “j” columns for the directions.
Based on the directional wave spectrum and the definitions given above (sum of harmonic waves), it is necessary to define:
  • Hrms i,j: Root mean square wave height (m): Hrms i,j = 2 * a i,j
  • T i,j: Wave period (s)
  • θ i,j: Wave Direction (º)
  • i,j : Phase (rad)

We hope we have clarified you how to define the input data.

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

Old   December 1, 2020, 08:03
Default
  #352
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 Fonzzao,

Quote:
I would like to know if it is possible to generate current only?
Yes, it is possible, but we have not released yet:
Wave-*‐current generation with OpenFOAM. Application to coastal and offshore structures

Please, contact us here if you want to discuss a potential collaboration:
ihfoam@ihcantabria.com

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

Old   December 1, 2020, 08:08
Default
  #353
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 Hattab
Quote:
any Idea?
Please, post it in the correct thread (here) to help you.

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

Old   December 2, 2020, 15:41
Default Hot-starting a wave model
  #354
New Member
 
Benjamin Norris
Join Date: Oct 2020
Location: California
Posts: 17
Rep Power: 6
bknorris is on a distinguished road
Hi IHFoam Team,

Quote:
Originally Posted by IHFOAM Team View Post
We hope we have clarified you how to define the input data.
Yes you did, thank you very much!

I have another basic question for you if I may. If I first run my wave model with a large rampTime to initialize conditions (where rampTime > the longest wave period), I'd then like to run a subsequent model from the latestTime of the first to simulate conditions. My question is, do I need to set rampTime = 0 before running the second model?

Thank you again for your help.

Ben
bknorris is offline   Reply With Quote

Old   December 3, 2020, 07:19
Default
  #355
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 Ben,

Quote:
I'd then like to run a subsequent model from the latestTime of the first to simulate conditions. My question is, do I need to set rampTime = 0 before running the second model?
If it is a restart, you do not need a ramp time.

The rampTime filter was created to be able to replicate what happens in laboratory, where first waves are normally filtered.

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

Old   December 3, 2020, 09:49
Question numerical diffusion error
  #356
Member
 
Grivalszki Péter
Join Date: Mar 2019
Location: Budapest, Hungary
Posts: 39
Rep Power: 7
GrivalszkiP is on a distinguished road
Hi!

I'm trying to simulate our wave flume with flap wavemaker. In my simulations, waves smearing quite quick. How can I decrease this numerical diffusion error?

Main parameters:

- flap wavemaker:
motionType flap;
x0 (0 0 0);
n (1 0 0);
waveHeight 0.05;
initialDepth 0.15;
wavePeriod 0.55;
rampTime 2.0;
wavePhase 0;

- k-Omega SST turbulence model
- 5 mm gridsize around water surface (flume is 0,5 m wide)
- MULES, (isoAdvector makes weird errors...) with
nAlphaCorr 2;
nAlphaSubCycles 3;
cAlpha 2;

Thank you:

Peter
GrivalszkiP is offline   Reply With Quote

Old   December 9, 2020, 10:19
Default
  #357
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 Peter

Quote:
Originally Posted by GrivalszkiP View Post
How can I decrease this numerical diffusion error?
A first idea would be to deal with the over-prediction of the turbulence kinetic energy. Please, take a look to the "New multiphase turbulence stabilization" (link), based on the works B.Devolder and B.E.Larsen & D.R.Fuhrman.

Best Regards,
IHFOAM Team
GrivalszkiP and bknorris like this.
__________________
http://ihfoam.ihcantabria.com/
IHFOAM Team is offline   Reply With Quote

Old   January 20, 2021, 16:46
Default
  #358
New Member
 
Benjamin Norris
Join Date: Oct 2020
Location: California
Posts: 17
Rep Power: 6
bknorris is on a distinguished road
Hi IHFOAM team,

I have another question regarding the Irregular Wave Model if I may.

I have set up an irregular wave model with 156 wave components that were discretized from a spectrum of water surface elevations recorded by a pressure gauge. The input spectrum initially consists of 320 components, but I limit the output to 156 components by filtering out very long-period waves (f < 0.0156 Hz) and very short-period waves (f > 0.5 Hz). [Please refer to attached figure]. Accordingly, the waveProperties input for the model has periods ranging from 64 s to 2 s, with corresponding heights, and phases. I've set the directions = 0 because the model is quasi-2D in the y-dimension, and waves propagate along the x-z dimension.

I first run a "hot start" model using a rampTime = 128 (2*largest wave period), save the last output of the model ('reconstructPar -time 128'), and then run another model from this time until 512 s has elapsed. I've included a plot of the modeled water surface elevations at the model inlet and at the point in the domain that I'm interested in sampling ('Location of Observations'). It looks to me like the largest waves occur around 60 s and 400 s (orange line), so the max period is 320 s and not 64 s.

Do you have any insight as to what might be causing this behavior?

Thank you in advance, and again for fielding my other questions!

Best,

Ben
Attached Images
File Type: png HR_V4_irregularWaveModelInputSpectrum.png (18.8 KB, 30 views)
File Type: png HR_V4_Model_WSEs.png (56.5 KB, 27 views)
Attached Files
File Type: c waveProperties.c (11.8 KB, 12 views)

Last edited by bknorris; February 1, 2021 at 17:45. Reason: formatting
bknorris is offline   Reply With Quote

Old   April 2, 2021, 05:58
Default 2D irregular wave motion in waveProperties?
  #359
New Member
 
Victor Baconnet
Join Date: Apr 2021
Location: Cannes, France
Posts: 9
Rep Power: 5
victor13165 is on a distinguished road
Quote:
Originally Posted by IHFOAM Team View Post
Hi Ben,

To describe the three-dimensional, moving waves, we use the random-phase/amplitude model (in x, y and t-space) by considering the sum of a large number of propagating harmonic waves in x,y-space, in direction θ relative to the positive x-axis.

All the variables used for the OpenFOAM implementation of the three-dimensional definition of the free surface are defined as matrix X i, j, with “i” rows for the frequencies and “j” columns for the directions.
Based on the directional wave spectrum and the definitions given above (sum of harmonic waves), it is necessary to define:
  • Hrms i,j: Root mean square wave height (m): Hrms i,j = 2 * a i,j
  • T i,j: Wave period (s)
  • θ i,j: Wave Direction (º)
  • i,j : Phase (rad)

We hope we have clarified you how to define the input data.

Regards,
IHFOAM Team



Hello IHFOAM Team,


Thank you for your work and this fantastic irregular wave model.

I understand that the input data has to be in the form of matrices with i lines and j columns, to generate 3D irregular waves.

Is it possible to "mimic" 2D irregular waves (only in the x direction) by giving the input data as column matrices with 1 column and i lines? In this case, the waveDirs vector would be only zeros.

As an example, this is what such a file would look like, with i=50 (i deleted the majority of the lines to make it shorter, but you get the idea):


Code:
/*---------------------------------------------------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  v2006                                 |
|   \\  /    A nd           | Website:  www.openfoam.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "constant";
    object      waveProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

INLET
{

    alpha            alpha.water;

    waveModel        irregularMultiDirectional;

    nPaddle          1;

    rampTime         18.0;

    activeAbsorption yes;

    wavePeriods
    50
    (
(0.9910438094089652)
.
.
.
(2.299969595420805)
    );

    waveHeights
    50
    (
(0.0038454296589595753)
.
.
.
(0.0025547066897806297)
    );

    wavePhases
    50
    (
(4.419270036678733)
.
.
.
(2.246040856529946)
    );

    waveDirs
    50
    (
(0.0)
.
.
.
(0.0)
    );

}
What do you think? Should I still give input data as matrices but make all the columns the same, while setting waveDirs as 0?


I hope that my enquiry is clear enough. I'm happy to give more details if needed.




Cheers,


Victor


EDIT: My question is pretty much similar to Benjamin's question above, sorry for that. After some testing, it looks like the simulation is running with 1-column matrices as inputs, and waveDirs(i,j) = 0 (also thanks to Benjamin's attached waveProperties file), but I am running into the same issue of maximum period being too large compared to the desired maximum period.

Last edited by victor13165; April 9, 2021 at 05:36. Reason: Similar question posted above : clarifications
victor13165 is offline   Reply With Quote

Old   April 20, 2021, 10:10
Default mangroveInteraction
  #360
New Member
 
Dylan James
Join Date: Dec 2020
Posts: 7
Rep Power: 5
dylan_OF is on a distinguished road
hi,IHFOAM Team,
Thank you for your work.
I want to simulate plants and wave interaction.
I can run the case mangroveInterantion on OpenFOAM-v2012 smoothly, But my simulation results can not match the results in the paper.(Maza, M., et al., Tsunami wave interaction with mangrove forests: A 3-D numerical approach, Coast. Eng. (2015), http://dx.doi.org/10.1016/j.coastaleng.2015.01.002)

as shown
G6 point of paper

G6 point of my


I just only modified the number of grids in the grid file, and other files did not change, the code is as follows.
blockMeshDict
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  v2012                                 |
|   \\  /    A nd           | Website:  www.openfoam.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    object      blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

scale   1;

vertices
(
    ( 0.0 0.0 0.0)
    ( 7.0 0.0 0.0)
    ( 7.0 0.55 0.0)
    ( 0.0 0.55 0.0)
    ( 0.0 0.0 0.5)
    ( 7.0 0.0 0.5)
    ( 7.0 0.55 0.5)
    ( 0.0 0.55 0.5)
);

blocks
(
    hex (0 1 2 3 4 5 6 7) (700 14 50) simpleGrading (1 1 1)
);

edges
(
);

boundary
(
    left
    {
        type patch;
        faces
        (
            (0 4 7 3)
        );
    }
    right
    {
        type patch;
        faces
        (
            (1 5 6 2)
        );
    }
    ground
    {
        type wall;
        faces
        (
            (0 1 2 3)
        );
    }
    top
    {
        type patch;
        faces
        (
            (4 5 6 7)
        );
    }
    sides
    {
        type patch;
        faces
        (
            (0 1 5 4)
            (3 2 6 7)
        );
    }
);

mergePatchPairs
(
);

// ************************************************************************* //
controDict
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  v2012                                 |
|   \\  /    A nd           | Website:  www.openfoam.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    object      blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

scale   1;

vertices
(
    ( 0.0 0.0 0.0)
    ( 7.0 0.0 0.0)
    ( 7.0 0.55 0.0)
    ( 0.0 0.55 0.0)
    ( 0.0 0.0 0.5)
    ( 7.0 0.0 0.5)
    ( 7.0 0.55 0.5)
    ( 0.0 0.55 0.5)
);

blocks
(
    hex (0 1 2 3 4 5 6 7) (700 14 50) simpleGrading (1 1 1)
);

edges
(
);

boundary
(
    left
    {
        type patch;
        faces
        (
            (0 4 7 3)
        );
    }
    right
    {
        type patch;
        faces
        (
            (1 5 6 2)
        );
    }
    ground
    {
        type wall;
        faces
        (
            (0 1 2 3)
        );
    }
    top
    {
        type patch;
        faces
        (
            (4 5 6 7)
        );
    }
    sides
    {
        type patch;
        faces
        (
            (0 1 5 4)
            (3 2 6 7)
        );
    }
);

mergePatchPairs
(
);

// ************************************************************************* //
fvOptions
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  v2012                                 |
|   \\  /    A nd           | Website:  www.openfoam.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "constant";
    object      fvOptions;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

Mangroves
{
    type            multiphaseMangrovesSource;
    active          yes;

    multiphaseMangrovesSourceCoeffs
    {
        regions
        {
            region1
            {
                cellZone        c0;
                a               0.01;
                N               560;
                Cm              1;
                Cd              1.52;
            }
        }
    }
}


TurbulenciaMangroves
{
    type            multiphaseMangrovesTurbulenceModel;
    active          yes;

    multiphaseMangrovesTurbulenceModelCoeffs
    {
        regions
        {
            region1
            {
                cellZone        c0;
                a               0.01;
                N               560;
                Ckp             1;
                Cep             3.5;
                Cd              1.52;
            }
        }
    }
}

// ************************************************************************* //

The version I used is OF-V2012,
How can I modify this example so that my results match those of the paper?
dylan_OF 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 8, 2019 00:34
udf problem jane Fluent UDF and Scheme Programming 37 February 20, 2018 05:17
UDF velocity profile willroca Fluent UDF and Scheme Programming 2 January 10, 2016 04:13
Error messages atg enGrid 7 August 30, 2013 12:16
Phase locked average in run time panara OpenFOAM 2 February 20, 2008 15:37


All times are GMT -4. The time now is 12:13.