CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Community Contributions > OpenFOAM CC Toolkits for Fluid-Structure Interaction

[solidMechanics] Support thread for "Solid Mechanics Solvers added to OpenFOAM Extend"

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree87Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 27, 2019, 09:18
Default
  #461
Super Moderator
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin, Ireland
Posts: 829
Rep Power: 28
bigphil will become famous soon enoughbigphil will become famous soon enough
Quote:
Originally Posted by ilhado View Post
Hello!

I have successfully compiled solids4foam before with foam-extend-4.1. However, I tried again in a new machine yesterday and it did not completely compile due to the following error:



The weird part is that this error appears a lot in the log, but as a warning only (I attached the log file). Did this also happen with anyone?

I tried in Ubuntu 16.04 and Ubuntu 18.04, with foam-extend-4.1.

Thanks a lot,
Iago
Hi Iago,

Which compiler are you using? My guess is that these errors are related to you using "too new" a compiler. It should work with gcc 4, 5 and 6 (as well as relatively recent Intel compilers); I have not (yet) checked with later gcc versions.

Best,
Philip
bigphil is offline   Reply With Quote

Old   June 27, 2019, 15:38
Default
  #462
New Member
 
ilhado's Avatar
 
Iago Lessa
Join Date: May 2015
Posts: 13
Rep Power: 7
ilhado is on a distinguished road
Quote:
Originally Posted by bigphil View Post
Hi Iago,

Which compiler are you using? My guess is that these errors are related to you using "too new" a compiler. It should work with gcc 4, 5 and 6 (as well as relatively recent Intel compilers); I have not (yet) checked with later gcc versions.

Best,
Philip
Hey Philip, I am using gcc, version 5.4.0.
I already compiled it before at it worked with this version.
Do you think it could be related to the foam-extend version? I noted this same kind of warning the last time I compiled it.

Bests
Iago
ilhado is offline   Reply With Quote

Old   June 29, 2019, 14:44
Default
  #463
Super Moderator
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin, Ireland
Posts: 829
Rep Power: 28
bigphil will become famous soon enoughbigphil will become famous soon enough
Quote:
Originally Posted by ilhado View Post
Hey Philip, I am using gcc, version 5.4.0.
I already compiled it before at it worked with this version.
Do you think it could be related to the foam-extend version? I noted this same kind of warning the last time I compiled it.

Bests
Iago
Hi Iago,

I am not sure about the warnings but I would not worry about them; for the error, it comes from compiler options not available with gcc5 (-Wno-ignored-attributes -Wno-misleading-indentation). I have removed these now and pushed the changes to the development branch. I will merge the changes to the master once I have performed checks.

Philip
ilhado likes this.
bigphil is offline   Reply With Quote

Old   July 2, 2019, 21:39
Default
  #464
New Member
 
ilhado's Avatar
 
Iago Lessa
Join Date: May 2015
Posts: 13
Rep Power: 7
ilhado is on a distinguished road
Quote:
Originally Posted by bigphil View Post
Hi Iago,

I am not sure about the warnings but I would not worry about them; for the error, it comes from compiler options not available with gcc5 (-Wno-ignored-attributes -Wno-misleading-indentation). I have removed these now and pushed the changes to the development branch. I will merge the changes to the master once I have performed checks.

Philip
Hello Philip,

Thank you very much! I will check the development version then!

Iago
ilhado is offline   Reply With Quote

Old   August 7, 2019, 23:26
Default
  #465
Senior Member
 
Hojatollah Gholami
Join Date: Jan 2019
Posts: 125
Rep Power: 3
Hgholami is on a distinguished road
Quote:
Originally Posted by bigphil View Post
Hi all,

FYI, a couple of recent papers on solid mechanics in OpenFOAM:
I am in the process of tidying things up and intend to publicly share the main procedures.

PDFs of the accepted articles (pre publishing) can be found at my ResearchGate:
https://www.researchgate.net/profile/Philip_Cardiff


Philip
Hi Philip,
In Article "A Lagrangian Cell-Centred Finite Volume Method for Metal Forming Simulation", Page (5), you mentioned "The relative deformation gradient is given in terms of the displacement increment as f = I + ∇(u)T". But I saw in solid mechanics book that the deformation gradient is f =I+∇(u), without transpose.
In OpenFOAM the code of deformation gradient was
Quote:
volTensorField F = I + gradD_.T();
and I think the strain had this code E=0.5(transpose(F)*F-I)=0.5(gradD_ +gradD_.T()+gradD_ & gradD_.T() )
Quote:
epsilon_ = symm(gradD_); //=0.5(gradD_+gradD_.T())
if(nonLinear == nonLinearGeometry::TOTAL_LAGRANGIAN)
{
epsilon_ += 0.5*symm(gradD_ & gradD_.T());
}
I thinks, the article wrote base on OpenFOAM definition not solid mechanics book, is it OK?
because for grad different in OpenFOAM, I found this

is it OK?
Hgholami is offline   Reply With Quote

Old   August 28, 2019, 09:09
Default friction BC without contact model
  #466
New Member
 
Denis Maier
Join Date: Aug 2019
Posts: 4
Rep Power: 2
DOMaier is on a distinguished road
Hey all,


I am working on the poro-elastoplasitc solvers by Tian Tang.
For a multitude if situations concerning geotechnical problems I need to specify a friction boundary condition.


The BC should either specify the displacement or traction (depending on the situation) for the normal component of the DU field.
For the tangential component DU should be 0 as long as the resulting shear stress doesn't exceed the maximum value given by Coulomb's friction law (maxShear proportional to normal traction).
If it does exceed, it should chance to a fixed (tangential) traction BC for that face and iteration.


I was looking at the solidContact Boundary condition, but i think it is a bit overkill for what i need, since i dont need the ability of detachment and re-attachment of the material (yet).


So i was thinking, I should be able to build on the fixedDisplacementZeroShear BC.
However i can not seem to find where the tangential components are specified.
I think the confusion stems from the whole valueFraction-issue that is quite hard to get the head around at the start.


Can someone point me to the right lines in the fixedDisplacementZeroShear to modify?


Greetings
Denis
DOMaier is offline   Reply With Quote

Old   September 17, 2019, 13:30
Default descomposePar solid problem
  #467
Senior Member
 
alberto
Join Date: Apr 2016
Location: Mexico
Posts: 102
Rep Power: 6
dewey is on a distinguished road
Hello,


I have a problem, I hope some one can help me.


I am trying to do a FSI simulation. I create a Mesh for the fluid and use the utility extrudeMesh to get the solid Mesh. When I run my case in series I dont have problem.
But when I try to run my case in parallel, and use the decomposePar utility for the solid region I get this error, and when I descompose the fluid region doesnt have problem.







Code:
 Decomposing mesh solid

Create time

Time = 0
Create mesh for region solid

Calculating distribution of cells
Selecting decompositionMethod simple

Finished decomposition in 0.02 s

Calculating original mesh data

Distributing cells to processors

Distributing faces to processors

Calculating processor boundary addressing

Distributing points to processors

Constructing processor meshes
Violación de segmento (`core' generado)
dewey is offline   Reply With Quote

Old   September 17, 2019, 15:44
Default
  #468
Member
 
Lilian Chabannes
Join Date: Apr 2017
Posts: 55
Rep Power: 5
Lookid is on a distinguished road
Quote:
Originally Posted by dewey View Post
Hello,


I have a problem, I hope some one can help me.


I am trying to do a FSI simulation. I create a Mesh for the fluid and use the utility extrudeMesh to get the solid Mesh. When I run my case in series I dont have problem.
But when I try to run my case in parallel, and use the decomposePar utility for the solid region I get this error, and when I descompose the fluid region doesnt have problem.







Code:
 Decomposing mesh solid

Create time

Time = 0
Create mesh for region solid

Calculating distribution of cells
Selecting decompositionMethod simple

Finished decomposition in 0.02 s

Calculating original mesh data

Distributing cells to processors

Distributing faces to processors

Calculating processor boundary addressing

Distributing points to processors

Constructing processor meshes
Violación de segmento (`core' generado)
Hello dewey,

I had a similar problem. My 2D mesh was imported from ICEM, but not perfectly 2D, you can check this by running checkMesh -region solid. You'll have warnings if it's not perfectly 2D, and that would most likely be the cause of your problem. However the case can still run in serial for some reasons.
To solve the problem, simply make it properly 2D.

If that is not the problem, I don't know then. Try different decomposition method (scotch method is cool).
__________________
Feel free to join the OpenFOAM Discord https://discord.gg/P9p9eHn, a live chat about OpenFOAM
Lookid is offline   Reply With Quote

Old   September 17, 2019, 21:28
Default
  #469
Senior Member
 
Hojatollah Gholami
Join Date: Jan 2019
Posts: 125
Rep Power: 3
Hgholami is on a distinguished road
Quote:
Originally Posted by dewey View Post
Hello,


I have a problem, I hope some one can help me.


I am trying to do a FSI simulation. I create a Mesh for the fluid and use the utility extrudeMesh to get the solid Mesh. When I run my case in series I dont have problem.
But when I try to run my case in parallel, and use the decomposePar utility for the solid region I get this error, and when I descompose the fluid region doesnt have problem.







Code:
 Decomposing mesh solid

Create time

Time = 0
Create mesh for region solid

Calculating distribution of cells
Selecting decompositionMethod simple

Finished decomposition in 0.02 s

Calculating original mesh data

Distributing cells to processors

Distributing faces to processors

Calculating processor boundary addressing

Distributing points to processors

Constructing processor meshes
Violación de segmento (`core' generado)
Dear dewey
maybe you describe your case, we can find your problem.
Hgholami is offline   Reply With Quote

Old   November 19, 2019, 12:01
Default fsiFoam&foam-extend4.0: Restart issue
  #470
New Member
 
Join Date: Mar 2017
Posts: 15
Rep Power: 5
paulbr is on a distinguished road
Hi to everyone,
I'm working on fsi problems with foam-extend/4.0 and Fsifoam4.0. I'm currently trying to make a restart with initial data from specific time-step. The fluid side is not a problem and I'm sure the issue comes from the solid solver. I tried several possibilities but for now, I'm stuck with this error that I can't understand:
Code:
Create time
 
Create dynamic mesh for time = 0

Selecting dynamicFvMesh dynamicMotionSolverFvMesh
Selecting motion solver: refVelocityLaplacian
--> FOAM Warning : 
    From function dlLibraryTable::open(const dictionary& dict, const word& libsEntry, const TablePtr tablePtr)
    in file /soft/foam-extend-4.0/foam/foam-extend-4.0/src/foam/lnInclude/dlLibraryTableTemplates.C at line 67
    library "libfvMotionSolver.so" did not introduce any new entries

Selecting motion diffusion: quadratic
Selecting motion diffusion: inverseDistance
 Reading stress mesh
[9] 
[9] 
[9] --> FOAM FATAL ERROR: 
[9] Cannot find file "points" in directory "constant/solid/polyMesh"
[9] 
[9]     From function Time::findInstance(const fileName&, const word&, const IOobject::readOption)
[9]     in file db/Time/findInstance.C at line 148.
[1] 
[1]
which doesn't make any sense because constant/solid/polyMesh/points does exists.

My first question is: Did anyone face the same issue ?

Meanwhile, when I post-process my solid results for parallel cases, I'm unable to reconstruct them. (With paraview, I only use Decomposed Case.) It seems that I need meshPhi to reconstruct the solid domain. For now, I have changed the IOobject in unsTotalLagrangianSolid.C with no success because meshPhi is not written.
Code:
        
// meshPhi must be present in order to reconstruction procedure works
        surfaceScalarField meshPhi
        (
            IOobject
            (
                "meshPhi",
                runTime().timeName(),
                mesh(),
                IOobject::READ_IF_PRESENT,            
                IOobject::AUTO_WRITE        
            ),
            mesh(),
            dimensionedScalar("0", dimVolume/dimTime, 0.0)
        );
        meshPhi.write();
    }
Based on any fluid solver from OpenFoam, I need to reconstruct the domain to use it as initial data for another run.
My second question is: How can I nicely reconstruct the solid domain ? (in order to make a restart possible.)

Until today, I'm executing this:
Code:
#!/bin/bash 
mkdir tmp 
cd fluid 
for proc in processor*; do 
mkdir ../tmp/$proc 
for time in $proc/*; do 
ln -s ../../fluid/$time/solid ../tmp/$time 
done 
done 
ln -s ../solid/system ../tmp/system 
ln -s ../solid/constant ../tmp/constant 
ln -s ../solid/0 ../tmp/0 
cd ../tmp 
touch solid.foam
which works fine for paraview but not for more...

Thanks in advance,

Paul
paulbr is offline   Reply With Quote

Old   November 19, 2019, 12:27
Default
  #471
Super Moderator
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin, Ireland
Posts: 829
Rep Power: 28
bigphil will become famous soon enoughbigphil will become famous soon enough
Hi Paul,

Although it will not directly solve your problem, it might be useful to try it out in solids4foam as some of these issues may have been fixed; PM me with your email address if you would like to use it.

Philip
bigphil is offline   Reply With Quote

Old   January 15, 2020, 13:32
Default
  #472
New Member
 
Kellis
Join Date: Mar 2017
Posts: 19
Rep Power: 5
Kellis is on a distinguished road
Good afternoon,


When attempting to start the elasticOrthoNonLinULSolidFoam solver from a time other than zero, it complains of not being able to locate the materialDirections file in the timestep folder. Checking the orthotropicLinearElastic.C file, the materialDirections file is set to NO_WRITE. Is there any reason it shouldn't be changed to write in the saved timestep directories, to allow for the case to restart at a non-zero time?


Thanks,
Kellis
Kellis is offline   Reply With Quote

Old   January 17, 2020, 00:29
Default
  #473
Senior Member
 
Hojatollah Gholami
Join Date: Jan 2019
Posts: 125
Rep Power: 3
Hgholami is on a distinguished road
Hi
I'm not familiar with this solver, but usually you can change IOobject to writing file in disk, it only increase storage. In general solvers, usually use NO_Write to make less storage.

Quote:
Originally Posted by Kellis View Post
Good afternoon,


When attempting to start the elasticOrthoNonLinULSolidFoam solver from a time other than zero, it complains of not being able to locate the materialDirections file in the timestep folder. Checking the orthotropicLinearElastic.C file, the materialDirections file is set to NO_WRITE. Is there any reason it shouldn't be changed to write in the saved timestep directories, to allow for the case to restart at a non-zero time?


Thanks,
Kellis
Hgholami is offline   Reply With Quote

Old   January 17, 2020, 03:55
Default Did you solve this?
  #474
Member
 
Torsten Schenkel
Join Date: Jan 2014
Posts: 42
Rep Power: 8
tschenkel is on a distinguished road
Hi,


if you did solve this, could you let us know, what combination worked?


I have the same errors.



Thanks



Quote:
Originally Posted by treem22 View Post
Phil,

I pulled from the development branch and can confirm that restarting now works.

I'll play around with the under-relaxation and/or time step from here. Thanks!
tschenkel is offline   Reply With Quote

Old   January 17, 2020, 05:07
Default
  #475
New Member
 
Erik
Join Date: Jul 2019
Posts: 7
Rep Power: 2
erik87 is on a distinguished road
Hi,


i'm currently writing my master thesis with geotechnical background.

For my thesis i'm using the elasticSolidFoam Solver.

Because of pressuretests i'm doing for my testcase models, i need to know what SI Unit foam-extend exactly uses.

So my Boundary Conditions need some pressures. I'm guessing Pa for pressure?

Has the pressure of the BC to be normalized with the density of the material?

It would be very great, if you could help me.




My BC for U looks like:

boundaryField
{
pressureside
{
type solidTraction;
traction uniform (0 0 0);

// I would like to set 80 bar pressure

pressure uniform 8e+06;
value uniform (0 0 0);
}
side with role conditon
{
type symmetryPlane;
}
}


Whats the difference between setting the pressure bc from:


traction uniform (0 0 8e+06) to my current bc setting

pressure uniform 8e+06 ? Or would the result be the same, if my pressure bc has to be set in z-direction?

As i understand traction uniform () you can set different vectors in traction uniform (), right?



Can i set the pressure bc with time variation, too?
So like to set the pressure bc with increasing pressure from 10 to 80 bar?


Sorry for so many questions i have.


Kind regards


Erik

Last edited by erik87; January 17, 2020 at 12:27.
erik87 is offline   Reply With Quote

Old   January 17, 2020, 13:00
Default
  #476
Super Moderator
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin, Ireland
Posts: 829
Rep Power: 28
bigphil will become famous soon enoughbigphil will become famous soon enough
Quote:
So my Boundary Conditions need some pressures. I'm guessing Pa for pressure?
Yes, Pa.

Quote:
Has the pressure of the BC to be normalized with the density of the material?
No, it is just Pa.

Quote:
pressureside
{
type solidTraction;
traction uniform (0 0 0);

// I would like to set 80 bar pressure

pressure uniform 8e+06;
value uniform (0 0 0);
}
Yep, that's correct, where positive means pushing in on the surface.



Quote:
Whats the difference between setting the pressure bc from:

traction uniform (0 0 8e+06) to my current bc setting

pressure uniform 8e+06 ? Or would the result be the same, if my pressure bc has to be set in z-direction?
If the patch outward-facing normal is in the negative z direction i.e. (0 0 -1), then these are both exactly the same; otherwise, they are not. Also, if you define them both then they are added together before being applied to the patch, so only set one as non-zero.

Quote:
As i understand traction uniform () you can set different vectors in traction uniform (), right?
Yes.

Quote:
Can i set the pressure bc with time variation, too?
So like to set the pressure bc with increasing pressure from 10 to 80 bar?
In solids4foam, yes; example:
Code:
myPatch
{
    type    solidTraction;
    traction  uniform (0 0 0);
    pressureSeries
    {
        fileName    "$FOAM_CASE/constant/timeVsPressure;
        outOfBounds  clamp;
    }
    value  uniform (0 0 0);
}
where for a ramp over 10 seconds, timeVsPressure looks like:
Code:
(
    (0 10e5)
    (10 80e5)
)

Philip
erik87 likes this.
bigphil is offline   Reply With Quote

Old   January 20, 2020, 17:28
Default
  #477
New Member
 
Erik
Join Date: Jul 2019
Posts: 7
Rep Power: 2
erik87 is on a distinguished road
Thank you very much Philip


Is it correct to say, that using only the nonuniform internalField from U volVectorField would be enougth for initial conditon for stress simulation?


I'm using mapFields for getting the nonuniform internalField, but in the first step of my simulations i'm just getting the U Field interpolated to my next mesh.
erik87 is offline   Reply With Quote

Old   January 20, 2020, 18:02
Default
  #478
Member
 
Torsten Schenkel
Join Date: Jan 2014
Posts: 42
Rep Power: 8
tschenkel is on a distinguished road
Quote:
Originally Posted by bigphil View Post
Yes, Pa.


No, it is just Pa.


Yep, that's correct, where positive means pushing in on the surface.
Just to clarify:

The fluid solvers in solids4Foam still use kinematic pressure [m^2/s^2], but the solid solvers do use [Pa]?
tschenkel is offline   Reply With Quote

Old   January 21, 2020, 06:15
Default
  #479
New Member
 
Join Date: Mar 2017
Posts: 15
Rep Power: 5
paulbr is on a distinguished road
Hello everyone,

While using Solids4foam for my new cases, I need to finish some works with fsifoam (and FE4.0).
I have mainly two situations:
1) I needed to refine my fluid mesh and it doesn't matter the time step value, the number of processors used for the decomposition, etc..., this kind of error appears (while my case was running with larger cells..):
Code:
[1] --> FOAM FATAL ERROR: 
[1] face 1268 area does not match neighbour by 0.102887% -- possible face ordering problem.
patch: procBoundary1to2 my area: 2.50158e-05 neighbour area: 2.49901e-05 matching tolerance: 1
Mesh face: 300506 vertices: 4((0.060402 -0.0942063 0.248161) (0.0538921 -0.0941869 0.237484) (0.053892 -0.096 0.238672) (0.060402 -0.0959902 0.250003))
Rerun with processor debug flag set for more information.
[1] 
[1]     From function processorPolyPatch::calcGeometry()
[1]     in file meshes/polyMesh/polyPatches/constraint/processor/processorPolyPatch.C at line 230.
[1] 
FOAM parallel run exiting
Now, I could increase the tolerance in processorPolyPatch.C, but I'm not sure it will definitively solve my problem. Do you have any idea how to get rid of it ?

2) As I'm not sure where my problem comes from, I tried to use the FE dynamic mesh solver, which I read gives much more robust results. I'm struggling to use it with fsiFoam and foam-extend/4.0. This error appears:
Code:
--> FOAM FATAL ERROR: 
Field size: 213 does not match number of points: 979

    From function tmp<Foam::Field<Type> >
tetPolyPatchInterpolation::pointToPointInterpolate
(
    const Field<Type>& ff
) const
    in file /soft/foam-extend-4.0/foam/foam-extend-4.0/src/tetFiniteElement/lnInclude/tetPolyPatchInterpolate.C at line 112.
I had a look to tetPolyPatchInterpolate.C
Code:
    if (ff.size() != patch_.patch().size())
    {
        FatalErrorIn
        (
            "tmp<Foam::Field<Type> >\n"
            "tetPolyPatchInterpolation::faceToPointInterpolate\n"
            "(\n"
            "    const Field<Type>& ff\n"
            ") const"
        )  << "Field size: " << ff.size() << " does not match number of faces: "
           << patch_.patch().size()
           << abort(FatalError);
    }
but... I can't understand this... Do you have any idea where it comes from ? (Btw, there are only fixedValue and slip boundary conditions in my motionU files.)

Could my second question solve the first one ?

Any help is welcome on both situation... !

Best,
Paul
paulbr is offline   Reply With Quote

Old   January 21, 2020, 18:40
Default
  #480
New Member
 
Kellis
Join Date: Mar 2017
Posts: 19
Rep Power: 5
Kellis is on a distinguished road
Paul,

Do you have your FSI boundaries declared as global face zones in the decomposeParDict for both fluid and solid? I.e.:

Code:
globalFaceZones ( fsiBoundaryPatchName )
I had a similar error and I think that's what fixed it for me.

Thanks,
Kellis
Kellis is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
GPU Linear Solvers for OpenFOAM gocarts OpenFOAM Announcements from Other Sources 36 March 29, 2017 08:05
[Virtualization] OpenFOAM oriented tutorial on using VMware Player - support thread wyldckat OpenFOAM Installation 2 July 11, 2012 16:01
New OpenFOAM Forum Structure jola OpenFOAM 2 October 19, 2011 06:55
Cross-compiling OpenFOAM 1.7.0 on Linux for Windows 32 and 64bits with Mingw-w64 wyldckat OpenFOAM Announcements from Other Sources 3 September 8, 2010 06:25
OpenFOAM Debian packaging current status problems and TODOs oseen OpenFOAM Installation 9 August 26, 2007 13:50


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