|
[Sponsors] |
Generate the irregular wave with piston wavemaker in OpenFOAM ESI |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
March 27, 2020, 19:36 |
Generate the irregular wave with piston wavemaker in OpenFOAM ESI
|
#1 |
New Member
Alex
Join Date: Mar 2020
Posts: 2
Rep Power: 0 |
Hi
I am trying to make a focused wave by using a piston wavemaker in OpenFOAM, but apparently I can only enter scaler input for the wave period. Thus, my question is that is it possible to make the irregular waves with a piston wavemaker without changing the BC source code or I have to edit the source code for it? Thank you in advance Please help me. |
|
July 10, 2020, 04:16 |
|
#2 |
New Member
Join Date: Jun 2020
Posts: 3
Rep Power: 6 |
Hello Foamers!
I'm trying to understand the "WavePistonMaker" tutorial (OF_19.12). where can I find documentation about it? I read the source code but still have several doubts. |
|
May 11, 2021, 08:02 |
Piston irregular wave motion from tabulated data file
|
#3 | |
New Member
Victor Baconnet
Join Date: Apr 2021
Location: Cannes, France
Posts: 9
Rep Power: 5 |
Quote:
This is a bit of a late answer, but maybe it can help somebody else. You can check out olaFlow and the wavemakerFlume tutorial : https://github.com/phicau/olaFlow/tr...wavemakerFlume. This would be the "cleanest" way to do it. If you are doing coastal engineering, olaFlow is great and has lots of great tools. You may want to check out IHFoam as well. If you don't want to use olaFlow, here is what I have tried. I'm using OpenFOAM v2006. EDIT : My original post did not reproduce the piston movement properly. I edited the right way to do it. Here is an overview of all the steps I did: 1. You need a file (.dat, .csv...) that contains the irregular motion of the piston. The irregular motion is usually generated from a theoretical spectrum (in my case, JONSWAP). This file has to be formatted in the following way: Code:
( //Format (time (displacement_x displacement_y displacement_z)) (0.0 (0.0 0 0)) (0.005 (0.000112 0 0)) (0.01 (0.000229 0 0)) (0.015 (0.000351 0 0)) (0.02 (0.000476 0 0)) (0.025 (0.000606 0 0)) (0.03 (0.000739 0 0)) (0.035 (0.000876 0 0)) // etc... //go until (tfinal (x_final y_final z_final)) ); A few additional things: - tfinal has to be equal or greater than your simulation time. - The timestep between each entry doesn't really matter, because the values will be interpolated. For example, if your simulation happens at t = 0.0075, the motion will be interpolated from the values given at 0.005 and 0.01. Still, make sure the timestep between each entry is small enough so that interpolated values would still follow the irregular motion you want to achieve. 2. Copy the waveMakerPiston case from $FOAM_TUTORIALS/multiphase/interFoam/laminar/waves/waveMakerPiston Code:
cp -r $FOAM_TUTORIALS/multiphase/interFoam/laminar/waves/waveMakerPiston . Code:
leftwall { type uniformFixedValue; uniformValue tableFile; file "meshMotionData.dat"; //Path to your file outOfBounds clamp; } This should do the trick. Let me know if you would like more information on how to generate the irregular motion data file, or anything else you can think of that is unclear. Happy to help. Cheers, Victor Last edited by victor13165; May 17, 2021 at 03:46. Reason: First answer didn't give the correct result |
||
May 18, 2021, 04:16 |
Questions about pointDisplacement
|
#4 | |
Member
Haoran Zhou
Join Date: Nov 2019
Posts: 51
Rep Power: 7 |
Quote:
I'm using olaFlow to do coastal engineering as well but I have a question about the pointDisplacement. AFAIK, the .dat file contains the rigid movement of the whole boundary. However, I want to add specific displacement on different mesh nodes on the boundary (like the figure in the attachment). How can I specify the nodes and how to give them different displacements? Thank you in advance! |
||
May 18, 2021, 04:32 |
|
#5 |
New Member
Victor Baconnet
Join Date: Apr 2021
Location: Cannes, France
Posts: 9
Rep Power: 5 |
Hello!
Can the motion of each point be described by a mathematical function? For example, if it's a wave it would be something like cos(wt - kx)? If that is the case, you can refer to this tutorial https://www.youtube.com/watch?v=C1NCtBJ0BtM. It uses swak2Foam and groovyBC boundary conditions. EDIT : This tutorial https://www.youtube.com/watch?v=3zcTxGHxuok might be easier to understand. It uses the codedFixedValue and doesn't require you to download anything. However, if you want to give an individual motion to each cell point, I have to say I don't know how that can be done. I would love to get more information on what you are trying to do and about the motion you are trying to input on the nodes. Cheers, Victor |
|
May 18, 2021, 04:50 |
|
#6 | |
Member
Haoran Zhou
Join Date: Nov 2019
Posts: 51
Rep Power: 7 |
Quote:
I've seen this video and it's not what I really need. I am trying to do partitioned FSI coupling by adopting OpenFOAM (fluid solver) and our in-house solver (solid solver). Recently I found a useful library called "preCICE" which is able to do CHT and FSI coupling. It employs ALE method to make the mesh nodes on the interface move according to the displacement increment obtained from the solid solver (https://precice.discourse.group/t/fs...e-solver/522/5). Since this mesh deformation is managed in OpenFOAM rather than preCICE, I've been searching for more details about pointDisplacement but I hardly get some helpful information. If you're interested in partitioned coupling, you can go to this link https://precice.org to check it out. Best regards, Stan |
||
May 18, 2021, 04:54 |
|
#7 |
New Member
Victor Baconnet
Join Date: Apr 2021
Location: Cannes, France
Posts: 9
Rep Power: 5 |
Hi Stan,
Very cool stuff! I will definitely check it out for my personal projects. Maybe someone knows the appropriate tools for this. Cheers and good luck, Victor |
|
February 11, 2023, 16:07 |
Irregular motion data file
|
#8 | |
New Member
Freddie Lawie
Join Date: Feb 2023
Posts: 1
Rep Power: 0 |
Quote:
Hi, I'm trying to do something similar to this - creating a .dat file to specify the piston motion. How did you generate the file for the JONSWAP spectrum? Thanks, Freddie |
||
January 19, 2024, 07:28 |
|
#9 | |
Senior Member
IHFOAM The Environmental Hydraulics Institute "IHCantabria"
Join Date: Sep 2017
Location: Santander (Spain)
Posts: 121
Rep Power: 9 |
HI Jonas
Quote:
(Chapter 7) Best, IHFOAM Team
__________________
http://ihfoam.ihcantabria.com/ |
||
Tags |
focus waves, irregular waves, openfoam, piston motion, wavemaker |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Getting Started with OpenFOAM | wyldckat | OpenFOAM | 26 | June 21, 2024 07:54 |
generate Waves in openfoam | anon_c | OpenFOAM | 30 | November 16, 2016 02:48 |
OpenFOAM Training Jan-Apr 2017, Virtual, London, Houston, Berlin | cfd.direct | OpenFOAM Announcements from Other Sources | 0 | September 21, 2016 12:50 |
Suggestion for a new sub-forum at OpenFOAM's Forum | wyldckat | Site Help, Feedback & Discussions | 20 | October 28, 2014 10:04 |
New OpenFOAM Forum Structure | jola | OpenFOAM | 2 | October 19, 2011 07:55 |