CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

HronTurekFsi3 foam-extend3.1

Register Blogs Community New Posts Updated Threads Search

Like Tree15Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 24, 2016, 08:38
Default
  #101
New Member
 
Wojciech Gołąbek
Join Date: Dec 2013
Posts: 29
Rep Power: 12
Woj3x is on a distinguished road
I used fe-3.1 in my case and I have some problems to run your case on it...

Your mesh (fluid) is very rough, especially in the space between the "pumpkin" and "bamboo tubes" where you can assume to get really high velocity. You need to make more than 3 elements in X direction (and I would also add few in Y direction). IMO you need at least 5 elements in X direction (but it's still not enough to get good results) to test this case.

You need also to create better mesh transition between blocks (I've already wrote sth about it in this topic).

Also I don't think that starting your tests with 10 m/s is good idea. If I were you I would use 0.5 m/s (or even less then it) to see how it'll work (courant number, displacements, forces, ect.). It will be easier to improve your mesh and then you will try to find good time step for you main problem.

Kind regards
Wojciech
KarthickRajkumar likes this.
Woj3x is offline   Reply With Quote

Old   November 24, 2016, 08:43
Default
  #102
Senior Member
 
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 13
Maimouna is on a distinguished road
Quote:
Originally Posted by KarthickRajkumar View Post
Hai Maimouna and Wojciech,

Thank you for the prompt reply.

I use foam-extend 3.2 for my simulation.
My geometry is of a musical instrument. You can see the geometry I have roughly drawn under comments in the fluid/constant/polymesh/blockMeshdict for better understanding.

I have also specified in the diagram what is cylinder and plate in my case.
My aim is to see the deflection of the plate due to the flow.

Initially I tried with BeamInCross flow and then I realised it has got some other situation for the inlet velcoity.
So now I am using HronTurek case, which has similar setup as mine and I think is the better option for my simulation.

So about the BC as you asked:

U: Only change I made is the inlet velocity set to (-10 0 0) - negative since the flow is in the negative x direction.
P: No changes
pointMotionU: No changes

Additional Info

I ran the HronTurek case with the inlet as outlet and outlet as inlet, so that the flow comes from negative x direction and to ensure that the simulation runs in such a case. It does run and I see the deflection.

Things which I doubt:

1. I ran the simulation only for 2 seconds since it takes more than 10 hours due to fine mesh. So should I run the simulation for more seconds to check for the deflection?

2. The difference between the tutorial and my set up is that, cylinder is not attached to any wall in tutorial but in my case the cylinder is attached to a wall. I believe it should not affect the simulation set up. And may be because it is fixed the deflection can be zero until 2 seconds. What do you think in this case?

3. Deflection is 0 for every time step until 2 seconds and just in case you need the force in force.dat file, here it is:

Force at the end of 2 seconds is
17.0856 527.416 1

@ Wojciech: About the courant number: I didn't save the log file. Didn't know I have to. But my simulation blows up at 2 seconds due to high courant number. (I ran it with 0.00001 time step). I thought of running the simulation in the cluster wth 0.0000001 time step if it shows some deflection.
These are all my thoughts up till now. Could you please help me at it. Any comments or suggestion would really help me.

You can find the my latest case file here. Please avoid any other files I uploaded before.

Thanks,
Karthick
Hi Karthick,

don't worry, I will have a look. My case implemented in fe31, but never mind I will try to get some time to study your case. For any further information or to remind me contact via may78may@hotmail.com. Because sometimes I'm taking long and don't check the forum.

All the best
Maimouna
KarthickRajkumar likes this.
Maimouna is offline   Reply With Quote

Old   November 27, 2016, 11:14
Default
  #103
New Member
 
Karthick
Join Date: Oct 2016
Location: Munich
Posts: 18
Rep Power: 9
KarthickRajkumar is on a distinguished road
Hai,

That's right Wojciech!! Thanks for the suggestion. It really helped me a lot. I added 5 elements along X direction and 3 elements along Y direction and Inlet Velocity set to (-0.25 0 0).

The simulation runs with no deflection of plate until 2 seconds. After 2 seconds I see the deflection of the point as follows.

2.00001 2.85381e-09 -2.58931e-09 4.7758e-23
2.00002 2.53603e-09 -6.97833e-09 -9.52907e-24
2.00003 -1.7756e-07 -3.69658e-07 -8.22465e-23

Until 2.00003 s, the courant number max is below 0.2, but at 2.0004 s the Max Courant number shoots up to 22.3112 (with velocity magnitude 149 m/s) in iteration 15 and to 2499.58 (with velocity magnitude 450 m/s) in iteration 16 and the simulation had stopped.
1. Could you find possible reasons for this?

I think as the plate starts deflecting, the velocity near the gap goes up (2 way coupling) and this can cause the Co number go high. In that case, how should I avoid this? And what time step would you advise me? With 0.00001 time step it took 15 hours on my laptop.

2. My aim is to do compressible fsi for my setup along with LES modelling. So I have planned to work on HronTurek tutorial case first towards compressible fsi (which I have no idea how to implement it) and then applying it on my case.

How would you advise me to carry this out in general? Since fsiFoam is based on pisoFoam solver (incompressible), does it involve tedious coding stuff for me to do compressible fsi for my setup?

Thanks for spending time to study my case @Maimouna. And also for the mailID

Thank you for helping me out!!
Karthick
KarthickRajkumar is offline   Reply With Quote

Old   November 27, 2016, 12:09
Default
  #104
New Member
 
Wojciech Gołąbek
Join Date: Dec 2013
Posts: 29
Rep Power: 12
Woj3x is on a distinguished road
1. I had similar problem in my case (It took me really a lot of time to find solution). Adding turbulence model solved it so try it.
2. IMO the easiest way to do this will be manually adapt solver which already exist in OpenFOAM. Here you cane find some information how to do it:
http://www.tfd.chalmers.se/~hani/kur...es_vyzikas.pdf
http://www.tfd.chalmers.se/~hani/kur...FlowReport.pdf
Even if you do not know C ++ very well you still should relatively easy handel it.

I do not know if you ever used LES but this simulation can take much more time than you think
In my case (it was 3D case with really complicated geometry, k-omega model and time step: 1e-7 [s]) it took me almost two months to get results for 1.5e-4 [s] (in my case fluid domain: 579 968 elements and solid domain: 32 256 elements). LES with good mesh even in 2D can take lots of time.

Time step dependent on mesh sieze and Courant number so the best way to find it is a trial and error method. You have a constant velocity (at least I suppose) on your inlet, so it won't be take too much time to find it.

Last edited by Woj3x; November 29, 2016 at 09:46.
Woj3x is offline   Reply With Quote

Old   November 30, 2016, 03:55
Default
  #105
New Member
 
Karthick
Join Date: Oct 2016
Location: Munich
Posts: 18
Rep Power: 9
KarthickRajkumar is on a distinguished road
Quote:
Originally Posted by Woj3x View Post
1. I had similar problem in my case (It took me really a lot of time to find solution). Adding turbulence model solved it so try it.
2. IMO the easiest way to do this will be manually adapt solver which already exist in OpenFOAM. Here you cane find some information how to do it:
http://www.tfd.chalmers.se/~hani/kur...es_vyzikas.pdf
http://www.tfd.chalmers.se/~hani/kur...FlowReport.pdf
Even if you do not know C ++ very well you still should relatively easy handel it.
Hai Wojciech,

Thanks for sharing the documents. That Indeed helped me to understand how the headerfiles are linked in fsi and how fsi library is connected to central installation of foam extend.

In the document, he has implemented interflow model built from interDymFoam. So I will just quickly write down the procedure required in my case of building rhoPimpleFlow model from rhoPimpleFoam.

1. Initially the src/fluidStructureInteraction/flowModels/pisoFlow files are copied and created rhoPimpleFlow as described and compiled after adding the flow model path to Make/files file.

2. On comparing with rhoPimpleFoam solver, I have to add the missing header files to the rhoPimpleFlow. So I included turbulenceModel.H, bound.H to rhoPimpleFlow.C and basicPsiThermo.H to rhoPimpleFlow.H and compiled it again. I did this.

3. Now I have to write down the fields (from CreateFields.H in solver directory) into rhoPimpleFlow.C and declare it in the rhoPimpleFlow.H.

So I planned to add field one by one and compile it.

Here is the first field in CreateFields.H
Code:
    autoPtr<basicPsiThermo> pThermo
    (
        basicPsiThermo::New(mesh)
    );
    basicPsiThermo& thermo = pThermo();

    volScalarField& p = thermo.p();
    volScalarField& h = thermo.h();
    const volScalarField& psi = thermo.psi();
so I added the following code to rhoPimpleFlow.C
Code:
    pThermo_ // added
    (
        basicPsiThermo::New(mesh)
    ),
    basicPsiThermo& thermo_ = pThermo(),

    volScalarField& p = thermo.p(),
    volScalarField& h = thermo.h(),
    const volScalarField& psi = thermo.psi(),
and declared autoPtr<basicPsiThermo> pThermo_; in the rhoPimpleFlow.H file and compiled it.

It showed some errors as ‘Foam::basicPsiThermo’ is not a direct base of ‘Foam::flowModels::rhoPimpleFlow’ and also other errors. I have attached below both .H and .C file along with log file. This field is not similar to U or p field, so I got stuck with this. I am going to need more help before Implementing rhoPimpleFoam I suppose!!

Could you please tell where lies the problem or is there any problem with my way of approach. As in, do I have to understand everything in the solver code and then code it one by one. Also if I can learn better about all these, please share it.

Thanks,
Karthick
Attached Files
File Type: gz rhoPimpleFlow with log.tar.gz (6.0 KB, 8 views)
KarthickRajkumar is offline   Reply With Quote

Old   November 30, 2016, 10:06
Default
  #106
New Member
 
Wojciech Gołąbek
Join Date: Dec 2013
Posts: 29
Rep Power: 12
Woj3x is on a distinguished road
Unfortunately, I've never done it myself so I suppose that I won't be able to help you in this one (because my advice in this case will be more like guessing).
Maybe Bruno Santos (wyldckat) or Maimouna will be able to help you in this part.
Kind regards,
Wojciech
Woj3x is offline   Reply With Quote

Old   December 1, 2016, 13:04
Default
  #107
New Member
 
Karthick
Join Date: Oct 2016
Location: Munich
Posts: 18
Rep Power: 9
KarthickRajkumar is on a distinguished road
Hai,

Thanks for the suggestion. I think I should learn PISO algorithm ---> how the those equations are coded in icoFoam solver-----> how the turbulence equations are added to icoFoam to form PisoFoam solver ---> finally adding compressibility factor to form rhoPisoFoam solver

And gain knowledge of codes behind icoFlow and pisoFlow models in FSI library (which are directly based on icoFoam and pisoFoam solvers). With this knowledge, I hopefully can implement rhoPisoFlow or rhoPimpleFlow as a flow model.

Thanks for the help!!
Karthick
KarthickRajkumar is offline   Reply With Quote

Old   December 1, 2016, 13:23
Default
  #108
New Member
 
Wojciech Gołąbek
Join Date: Dec 2013
Posts: 29
Rep Power: 12
Woj3x is on a distinguished road
It's probably the best approach you can make now.
I could only tell you that codes behind icoFoam and pisoFoam are pretty simple so you should do it this rather fast. The only difference between pisoFlow and pisoFoam is that the time loop is out from pisoFlow (in fsiFOAM algoritm).

You also need to find how the algorithm for transferring data between solid and fluid solvers work (this is probably the most important thing to adapt rhoPimpleFoam).

Kind regards,
Wojciech
Woj3x is offline   Reply With Quote

Old   December 15, 2016, 10:29
Default
  #109
New Member
 
Karthick
Join Date: Oct 2016
Location: Munich
Posts: 18
Rep Power: 9
KarthickRajkumar is on a distinguished road
Hai,

Finally I was able to implement rhopisoFlow into FSI library. It indeed required quite some effort to make it work, but learnt a lot trying to implement this.

I checked the model with HronTurek fsi tutorial and I could simulate it under compressible flow conditions.

Thanks @Wojciech @Maimouna for all the help.

Now it's time to run it on my application.

Regards,
Karthick
KarthickRajkumar is offline   Reply With Quote

Old   December 25, 2016, 06:12
Default
  #110
New Member
 
Karthick
Join Date: Oct 2016
Location: Munich
Posts: 18
Rep Power: 9
KarthickRajkumar is on a distinguished road
Hai,

A quick question! I am running the HronTurekFSI with implemented compressible flow model. I can the deflection of the flag, but it waves slightly below the center, it doesn't wave about the center axis. I am confused whether is it the effect of compressibility factor or am I doing anything wrong.

I couldn't find how a HronTurek case behaves under compressible case to check my simulation is correct or wrong! can any1 help me out on this!

I have attached the deflection plot down below!

Thanks,
Karthick
Attached Files
File Type: gz deflection.ps.tar.gz (12.3 KB, 9 views)
KarthickRajkumar is offline   Reply With Quote

Old   April 21, 2017, 09:41
Default
  #111
Member
 
thegauravonline's Avatar
 
GS
Join Date: Mar 2016
Posts: 81
Rep Power: 10
thegauravonline is on a distinguished road
Yes. This is an issue with geometry.
You seem to be using "blockMesh" utility of openFoam.

You need to check the specified directions for the patches in blockMeshDict file.
thegauravonline is offline   Reply With Quote

Old   March 27, 2019, 14:15
Default
  #112
Senior Member
 
Hojatollah Gholami
Join Date: Jan 2019
Posts: 171
Rep Power: 7
Hgholami is on a distinguished road
Dear Singh
I run FSI2 of hronTurek Benchmark with fsiFoam. the problem is when deflection increase the solution diverge (velocity increasing). Do you any recommend for fvScheme ond fvSolution?

Last edited by Hgholami; March 28, 2019 at 08:35.
Hgholami is offline   Reply With Quote

Old   April 20, 2019, 21:11
Default validation of fsiFoam
  #113
Senior Member
 
Hojatollah Gholami
Join Date: Jan 2019
Posts: 171
Rep Power: 7
Hgholami is on a distinguished road
Dear wyldckat,
In fsiFoam solver the tutorial of Hron-Turek (FSI3) with default blockMeshDict have 12% error compared with article. With other blockMeshDict (available in tutorial with finner mesh and 0.0005 deltaT) the deflection of beam reduces and deflection is lower. Do you know, the problem is in OpenFOAM solver or the case of "Hron-Turek"? Thanks
Hgholami 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
[Other] mesh airfoil NACA0012 anand_30 OpenFOAM Meshing & Mesh Conversion 13 March 7, 2022 17:22
[blockMesh] error message with modeling a cube with a hold at the center hsingtzu OpenFOAM Meshing & Mesh Conversion 2 March 14, 2012 09:56
[blockMesh] BlockMesh FOAM warning gaottino OpenFOAM Meshing & Mesh Conversion 7 July 19, 2010 14:11
[blockMesh] Axisymmetrical mesh Rasmus Gjesing (Gjesing) OpenFOAM Meshing & Mesh Conversion 10 April 2, 2007 14:00
[Gmsh] Import gmsh msh to Foam adorean OpenFOAM Meshing & Mesh Conversion 24 April 27, 2005 08:19


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