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

Viscoelastic Fluid Flows using OpenFOAM The solver viscoelasticFluidFoam

Register Blogs Community New Posts Updated Threads Search

Like Tree44Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 21, 2013, 00:24
Angry thanks
  #241
New Member
 
salame ama
Join Date: Dec 2012
Posts: 28
Rep Power: 14
salame is on a distinguished road
To Tushar:
thank you for your advise. in my files, the two lines was already existed.
EXE_INC = \
-I$(LIB_SRC)/twoPhaseViscoelasticMixture \
...
-I$(LIB_SRC)/transportModels/viscoelastic/lnInclude \
...

EXE_LIBS = \
...
-ldynamicFvMesh \
-ltopoChangerFvMesh \
-lviscoelasticTransportModels \
-llduSolvers
.So... still upset.

To adambarfi:

Thank u first. I met these questions:

I changed the towphaseMixture file, but did not change the transportModel.H file.

today I #include the viscoelasticModel.H and Giesekus.H in the file transportModel.H file, and change the input file transportProperties, like :
phase1
{
transportModel Giesekus;
type multiMode;

models
(
first
{
type Giesekus;
rho rho [1 -3 0 0 0 0 0] 803.87097;
.....

It told me: visitymodel have no Giesekus...

I didn't know where should i change....
salame is offline   Reply With Quote

Old   March 21, 2013, 01:09
Exclamation Hello,
  #242
Senior Member
 
T. Chourushi
Join Date: Jul 2009
Posts: 321
Blog Entries: 1
Rep Power: 18
Tushar@cfd is on a distinguished road

@salame's question:
I changed the towphaseMixture file, but did not change the transportModel.H file.

today I #include the viscoelasticModel.H and Giesekus.H in the file transportModel.H file, and change the input file transportProperties, like :
phase1
{
transportModel Giesekus;
type multiMode;

models
(
first
{
type Giesekus;
rho rho [1 -3 0 0 0 0 0] 803.87097;
.....

It told me: visitymodel have no Giesekus...

I didn't know where should i change....


------------------------
Hello salame,

In your problem, you are editing the transportProperties of your case file, but for this particular case you need to edit viscoelasticProperties file.

Option1:
This can only be overcome as described in brief by Adambarfi too.. You need to do lot of modification in your case, try something like combining the libraries of both solvers.. Best of luck for that, as it is not that easy..

Option2:
Other option is to add Giesekus model in the already available transportModel..

For both the options, you need to be extra careful as there are very high chances of incorporation of errors.

Best of luck..

Last edited by Tushar@cfd; March 21, 2013 at 04:09.
Tushar@cfd is offline   Reply With Quote

Old   March 21, 2013, 02:35
Default
  #243
Senior Member
 
adambarfi's Avatar
 
Mostafa Mahmoudi
Join Date: Jan 2012
Posts: 322
Rep Power: 15
adambarfi is on a distinguished road
Send a message via Yahoo to adambarfi Send a message via Skype™ to adambarfi
dear salame,
viscoelasticFluidFoam just returns the div(tau). so it is not a viscosity model.
if you set this solver as a base, you can modify it in a manner that could be used for multiphase problems.
my idea is: make a new solver containing both viscoelasticFluidFoam and interFoam.
but that is just my opinion ;-)
adambarfi is offline   Reply With Quote

Old   March 21, 2013, 08:10
Default
  #244
New Member
 
salame ama
Join Date: Dec 2012
Posts: 28
Rep Power: 14
salame is on a distinguished road
Thank u again, Tushar and adambarfi.
Yes, I had a new solver which combine the two solvers. At this stage, it seems to need a right file(transportProperties) to let the new solver read the properties of two phases in.
In the InterFoam, the transportProperties files write as:
phase1
{
transportModel Newtonian;
nu nu [ 0 2 -1 0 0 0 0 ] 1e-06;
rho rho [ 1 -3 0 0 0 0 0 ] 1000;
CrossPowerLawCoeffs
{
nu0 nu0 [ 0 2 -1 0 0 0 0 ] 1e-06;
nuInf nuInf [ 0 2 -1 0 0 0 0 ] 1e-06;
m m [ 0 0 1 0 0 0 0 ] 1;
n n [ 0 0 0 0 0 0 0 ] 0;
}
.....
At the same time, the viscoelasticProperties file in the viscoelasticFluidFoam write like:
rheology
{

type multiMode;

models
(
first
{
type Giesekus;
rho rho [1 -3 0 0 0 0 0] 803.87097;
etaS etaS [1 -1 -1 0 0 0 0] 0.002;
etaP etaP [1 -1 -1 0 0 0 0] 0.04;
lambda lambda [0 0 1 0 0 0 0] 0.6855;
alpha alpha [0 0 0 0 0 0 0] 0.5;
}
....

Today, i copy the Giesekus folder in the viscosity folder as Tushar said, and change the properies file, still wrong.

I felt troubled about the right style.
salame is offline   Reply With Quote

Old   March 21, 2013, 09:04
Default
  #245
Senior Member
 
adambarfi's Avatar
 
Mostafa Mahmoudi
Join Date: Jan 2012
Posts: 322
Rep Power: 15
adambarfi is on a distinguished road
Send a message via Yahoo to adambarfi Send a message via Skype™ to adambarfi
I didn't exprienced in multiphase flows. but one idea is that you can define a new viscosity model. just modify an exist viscosityModel. then you can use it in transportProperties and in momentum equation the div(tau) ca be used.
adambarfi is offline   Reply With Quote

Old   March 22, 2013, 01:17
Post Hello salame,
  #246
Senior Member
 
T. Chourushi
Join Date: Jul 2009
Posts: 321
Blog Entries: 1
Rep Power: 18
Tushar@cfd is on a distinguished road
Try to look out for the solution by applying any of the option which I have mentioned in my earlier thread.

Both the options are different:
Option2, doesn't need any viscoelasticProperties file

Option1, do need both the files but with lot of modifications

As for now, I would advice you to go for "ProgrammersGuide" for better understanding of the programing in OF.
Tushar@cfd is offline   Reply With Quote

Old   March 25, 2013, 06:42
Default
  #247
New Member
 
salame ama
Join Date: Dec 2012
Posts: 28
Rep Power: 14
salame is on a distinguished road
Quote:
Originally Posted by adambarfi View Post
I didn't exprienced in multiphase flows. but one idea is that you can define a new viscosity model. just modify an exist viscosityModel. then you can use it in transportProperties and in momentum equation the div(tau) ca be used.
Thank u! I will try the way you mentioned.
salame is offline   Reply With Quote

Old   March 25, 2013, 06:48
Default
  #248
New Member
 
salame ama
Join Date: Dec 2012
Posts: 28
Rep Power: 14
salame is on a distinguished road
Quote:
Originally Posted by Tushar@cfd View Post
Try to look out for the solution by applying any of the option which I have mentioned in my earlier thread.

Both the options are different:
Option2, doesn't need any viscoelasticProperties file

Option1, do need both the files but with lot of modifications

As for now, I would advice you to go for "ProgrammersGuide" for better understanding of the programing in OF.
Thanks! I think option2 is better one and i will try.
salame is offline   Reply With Quote

Old   March 26, 2013, 02:18
Default about the solver
  #249
New Member
 
salame ama
Join Date: Dec 2012
Posts: 28
Rep Power: 14
salame is on a distinguished road
Still, about the viscoelastcproperties of tutorials of viscoelasticFluidFoam, why it say wrong if change the name "rheology" to others? i try to change the Line 58 in viscoelasticModel.C
lawPtr_(viscoelasticLaw::New(word::null, U, phi, subDict("rheology")))
to
lawPtr_(viscoelasticLaw::New(word::null, U, phi, subDict("phase1")))

and i change the viscoelasticProperties file, "rheology" to "phase1". but it still say wrong. why? I just want to know how the viscoelasticModel work, can someone explain that? I contacted the solver just a few days, so ....maybe the question is very simple, your patience always be appreciated!
salame is offline   Reply With Quote

Old   March 26, 2013, 16:02
Default About Running
  #250
New Member
 
Erick Lorenzato
Join Date: Mar 2013
Posts: 8
Rep Power: 13
EricKl. is on a distinguished road
Hello

My name is Erick and I'm doing my thesis using OpenFoam.
It's my first contact with the program and am having some difficulties.
I want to use viscoelasticFluidFoam, programmed by Jovani.
First I run like any other program:

~ / $ OpenFoam/erika2.1.1/tutorials2/viscoelastic/viscoelasticFluidFoam/Giesekus

After running the command blockMesh. Some folders should appear, but nothing appears.


After not know what to do. Was using the methodology of the guide (icoFoam), but shows no result.

When I put paraFoam, the mesh appears, but nothing happens in the apply

Anyone know where is my mistake or what is missing?

thank you

Erick

Last edited by EricKl.; March 26, 2013 at 16:38.
EricKl. is offline   Reply With Quote

Old   March 27, 2013, 02:01
Default
  #251
New Member
 
salame ama
Join Date: Dec 2012
Posts: 28
Rep Power: 14
salame is on a distinguished road
To Erick:
Hi, i did not know "Some folders should appear" means. If you mean the files about results, you need run the command viscoelasticFluidFoam , just running "blockMesh" is not enough. Like you say, you can see the mesh from paraView, i guess you forget the step.
good luck!
salame is offline   Reply With Quote

Old   April 11, 2013, 16:37
Default Solver Problem
  #252
New Member
 
Erick Lorenzato
Join Date: Mar 2013
Posts: 8
Rep Power: 13
EricKl. is on a distinguished road
Hi

Thank you for your help.
I managed to install the program, but I have a problem.

I'm trying to run the example Giesekus
When I run the program blockMesh the wheel, but does not generate the time steps (in the tutorial folder).

Mando run solver, viscoelasticFluidFoam, an error appears.


-> FOAM FATAL IO ERROR:
Unknown asymmetric matrix solver BiCGStab

Valid asymmetric matrix solvers are:

4
(
BICCG
GAMG
PBiCG
smoothSolver
)


file: from line 47 to line 56.

From solver function lduMatrix :: New ::
in file matrices / lduMatrix / lduMatrix / lduMatrixSolver.C at line 106.

FOAM exiting



What can I do to solve?

The version of veff is the 2.1.x and 2.1.1 is my OpenFoam

I thank
EricKl. is offline   Reply With Quote

Old   April 12, 2013, 02:52
Post
  #253
Senior Member
 
T. Chourushi
Join Date: Jul 2009
Posts: 321
Blog Entries: 1
Rep Power: 18
Tushar@cfd is on a distinguished road
Quote:
Originally Posted by EricKl. View Post
Hi

Thank you for your help.
I managed to install the program, but I have a problem.

I'm trying to run the example Giesekus
When I run the program blockMesh the wheel, but does not generate the time steps (in the tutorial folder).

Mando run solver, viscoelasticFluidFoam, an error appears.


-> FOAM FATAL IO ERROR:
Unknown asymmetric matrix solver BiCGStab

Valid asymmetric matrix solvers are:

4
(
BICCG
GAMG
PBiCG
smoothSolver
)


file: from line 47 to line 56.

From solver function lduMatrix :: New ::
in file matrices / lduMatrix / lduMatrix / lduMatrixSolver.C at line 106.

FOAM exiting



What can I do to solve?

The version of veff is the 2.1.x and 2.1.1 is my OpenFoam

I thank
Hello Erickl.

Check the Solution algorithm.
In your case, you are mistaking with the symmetric & asymmetric matrices.
For more detail refer:
http://www.openfoam.org/docs/user/fvSolution.php
Tushar@cfd is offline   Reply With Quote

Old   April 16, 2013, 16:35
Default
  #254
New Member
 
Erick Lorenzato
Join Date: Mar 2013
Posts: 8
Rep Power: 13
EricKl. is on a distinguished road
Hello

Thanks for the tip.
Understand what was wrong and I'm changing.
I started reading about the solvers. Now is understanding the difference of each.

EricKl. is offline   Reply With Quote

Old   May 8, 2013, 15:54
Default
  #255
New Member
 
Erick Lorenzato
Join Date: Mar 2013
Posts: 8
Rep Power: 13
EricKl. is on a distinguished road
Good afternoon
I'm trying to install ViscoelasticInterFoam written by Jovani, but am having problems. Anyone have any tutorial on where to download and how to install?
I downloaded some files scattered but when I run it did not work. The only command that he accepted solver is viscoelasticFluidFoam.

Anyone have any ideas?

thank you
EricKl. is offline   Reply With Quote

Old   May 12, 2013, 04:39
Default Adding dissipation term to heat transfer equation of a viscoelastic fluid
  #256
Senior Member
 
adambarfi's Avatar
 
Mostafa Mahmoudi
Join Date: Jan 2012
Posts: 322
Rep Power: 15
adambarfi is on a distinguished road
Send a message via Yahoo to adambarfi Send a message via Skype™ to adambarfi
Hi everybody,

I want to add the dissipation term to my T equation. I did it as follows:
Code:
    dimensionedScalar kappa=(etaS+etaP)/(rho*Pr);

    fvScalarMatrix TEqn
    (
        fvm::div(phi, T)
      - fvm::Sp(fvc::div(phi), T)
      - fvm::laplacian(kappa, T)
      - (visco.tau() && (fvc::curl(U)))  //Dissipation Term
    );
where visco is my viscoelastic model (Giesekus) and visco.tau is a symmetric tensor.
when I wmake my solver the following errros appeared:

Code:
In file included from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/Field.C:735:0,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/Field.H:360,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/labelField.H:39,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/primitiveFields.H:37,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/pointField.H:36,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/edge.H:40,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/edgeList.H:32,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/primitiveMesh.H:57,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/polyMesh.H:44,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/finiteVolume/lnInclude/fvMesh.H:50,
                 from /home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/finiteVolume/lnInclude/fvCFD.H:7,
                 from bbvffPerfectTdepDiss2.C:36:
/home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/FieldFunctions.C: In function ‘void Foam::dotdot(Foam::Field<typename Foam::scalarProduct<Type1, Type2>::type>&, const Foam::UList<T>&, const Foam::UList<Key>&) [with Type1 = Foam::SymmTensor<double>, Type2 = Foam::Vector<double>, typename Foam::scalarProduct<Type1, Type2>::type = double]’:
/home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/GeometricFieldFunctions.C:956:1:   instantiated from ‘void Foam::dotdot(Foam::GeometricField<typename Foam::scalarProduct<Type1, Type2>::type, PatchField, GeoMesh>&, const Foam::GeometricField<TypeR, PatchField, GeoMesh>&, const Foam::GeometricField<Type1, PatchField, GeoMesh>&) [with Type1 = Foam::SymmTensor<double>, Type2 = Foam::Vector<double>, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, typename Foam::scalarProduct<Type1, Type2>::type = double]’
/home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/GeometricFieldFunctions.C:956:1:   instantiated from ‘Foam::tmp<Foam::GeometricField<typename Foam::scalarProduct<Type1, Type2>::type, PatchField, GeoMesh> > Foam::operator&&(const Foam::tmp<Foam::GeometricField<TypeR, PatchField, GeoMesh> >&, const Foam::tmp<Foam::GeometricField<Type1, PatchField, GeoMesh> >&) [with Type1 = Foam::SymmTensor<double>, Type2 = Foam::Vector<double>, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, typename Foam::scalarProduct<Type1, Type2>::type = double]’
TEqn.H:22:38:   instantiated from here
/home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/FieldFunctions.C:705:1: error: no match for ‘operator&&’ in ‘*(f2P ++) && *(f3P ++)’
/home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/FieldFunctions.C:705:1: note: candidates are: operator&&(bool, bool) <built-in>
/home/mostafa/OpenFOAM/OpenFOAM-2.1.0/src/OpenFOAM/lnInclude/dimensionSet.H:293:29: note:                 Foam::dimensionSet Foam::operator&&(const Foam::dimensionSet&, const Foam::dimensionSet&)
make: *** [Make/linuxGccDPOpt/bbvffPerfectTdepDiss2.o] Error 1
anybody knows where is the problem? I'm completely confused.

thanks
Mostafa
adambarfi is offline   Reply With Quote

Old   May 14, 2013, 07:10
Default Oscillations in solution
  #257
Senior Member
 
Sita Drost
Join Date: Mar 2009
Location: Arnhem, The Netherlands
Posts: 227
Rep Power: 18
sita is on a distinguished road
Hello everyone,

I'm having a problem with viscoelasticFluidFoam: the 4:1 contraction tutorials run smoothly, but as soon as I change my geometry, for example to a 10:1 contraction, or something with multiple outlets, my solution becomes very oscillatory or even becomes unstable before the run finishes.
The same happens with the lid-driven cavity. There it seems to be caused by the stresses in the corners near the lid becoming too high, which I could circumvent by applying a velocity profile to the lid, instead of a constant velocity.
I suspect high stresses may be the cause for my problems with the contraction geometry too, so I tried to smooth the re-entrant corners a bit. This seems to help, but it doesn't solve the problem completely.
Does anyone know a solution for these kind of problems?

Thanks in advance!
Sita

Last edited by sita; May 15, 2013 at 13:36.
sita is offline   Reply With Quote

Old   July 5, 2013, 05:59
Default
  #258
Senior Member
 
Sita Drost
Join Date: Mar 2009
Location: Arnhem, The Netherlands
Posts: 227
Rep Power: 18
sita is on a distinguished road
Anyone????
sita is offline   Reply With Quote

Old   July 9, 2013, 06:29
Default
  #259
Senior Member
 
T. Chourushi
Join Date: Jul 2009
Posts: 321
Blog Entries: 1
Rep Power: 18
Tushar@cfd is on a distinguished road
Quote:
Originally Posted by sita View Post
Anyone????
Sometimes, selection of appropriate constitutive equations plays a crucial role.

Anyways, do share your views if you happen to find the solution.
Tushar@cfd is offline   Reply With Quote

Old   July 18, 2013, 10:43
Default how to get the viscoelastic models' parameters
  #260
Member
 
Join Date: Feb 2012
Posts: 59
Rep Power: 14
Raymond.Leoi is on a distinguished road
In terms of an example of Verbeeten's data as shown in the attached snapshot, how to get the viscoelastic models' parameters such as etaS, etaP etc.?
Attached Images
File Type: jpg Verbeeten's Table 1.jpg (33.1 KB, 63 views)
Raymond.Leoi 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
VOF simulation of a viscoelastic fluid sinah OpenFOAM Running, Solving & CFD 11 December 25, 2017 04:00
FREE SURFACE VISCOELASTIC FLOWS Valdemir G. Ferreira Main CFD Forum 6 December 18, 2009 07:14
Viscoelastic flow modeling in OpenFOAM vulda OpenFOAM Running, Solving & CFD 1 March 17, 2008 08:32
Polyflow & OpenFoam on Viscoelastic flow modeling Sumeshen Main CFD Forum 0 March 14, 2008 09:29
Viscoelastic fluid codes joel davison Main CFD Forum 0 November 6, 2001 06:09


All times are GMT -4. The time now is 20:59.