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

Viscosity model in the twoPhaseEulerFoam

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 1, 2012, 00:43
Default Viscosity model in the twoPhaseEulerFoam
  #1
Member
 
Jeong Kim
Join Date: Feb 2010
Posts: 42
Rep Power: 16
enoch is on a distinguished road
I'm not using the kinetic theory for the solid-phase stress tensor, but I could borrow "viscosity models" used in the solver.

For the solid phase, the momentum equation is
dUa/dt = div( nuEffa*TAU) + ...
where nuEffa=mua/rhoa

I'd like to use the BirdCarreau viscosity model for mua. mua is a function of strainRate and alpha where mua_inf, mua_0, k, and n are constants.
I checked non-newtonian solver and its viscosity models, and I tried to implement the modified BirdCarreau viscosity model located in the folder:
../twoPhaseEulerFoamMod/kineticTheoryModels/viscosityModel/BirdCarreau

When I compiled kineticTheoryModels using wmake libso, it failed. Could you give me your direction or remedy? Attached are files for the viscosity model.
Attached Files
File Type: gz BirdCarreau.tar.gz (1.8 KB, 12 views)
File Type: txt kineticTheoryProperties.dat.txt (1.9 KB, 22 views)
enoch is offline   Reply With Quote

Old   March 1, 2012, 03:42
Default
  #2
Member
 
Laurens Van Dyck
Join Date: Jul 2011
Location: Netherlands/Germany
Posts: 34
Rep Power: 15
laurensvd is on a distinguished road
Whats the error message?
laurensvd is offline   Reply With Quote

Old   March 1, 2012, 12:09
Default
  #3
Member
 
Jeong Kim
Join Date: Feb 2010
Posts: 42
Rep Power: 16
enoch is on a distinguished road
Below is what I've got on my monitor screen.
====
.......
viscosityModel/BirdCarreau/BirdCarreauViscosity.C: At global scope:
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:91: error: prototype for ‘Foam::tmp<Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> > Foam::kineticTheoryModels::BirdCarreauViscosity::m ua(const Foam::volScalarField&, const Foam::volVectorField&) const’ does not match any in class ‘Foam::kineticTheoryModels::BirdCarreauViscos ity’
viscosityModel/BirdCarreau/BirdCarreauViscosity.H:100: error: candidates are: Foam::tmp<Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> > Foam::kineticTheoryModels::BirdCarreauViscosity::m ua(const Foam::volScalarField&, int) const
viscosityModel/BirdCarreau/BirdCarreauViscosity.H:69: error: Foam::tmp<Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> > Foam::kineticTheoryModels::BirdCarreauViscosity::m ua() const
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:110: error: ‘oam’ has not been declared
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:112: error: ISO C++ forbids declaration of ‘dictionary’ with no type
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:112: error: expected ‘,’ or ‘...’ before ‘&’ token
viscosityModel/BirdCarreau/BirdCarreauViscosity.C: In function ‘bool read(int)’:
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:115: error: ‘viscosityModel’ has not been declared
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:115: error: ‘viscosityProperties’ was not declared in this scope
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:117: error: ‘BirdCarreauViscosityCoeffs_’ was not declared in this scope
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:117: error: ‘typeName’ was not declared in this scope
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:119: error: ‘nu0_’ was not declared in this scope
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:120: error: ‘nuInf_’ was not declared in this scope
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:121: error: ‘k_’ was not declared in this scope
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:122: error: ‘n_’ was not declared in this scope
In file included from viscosityModel/BirdCarreau/BirdCarreauViscosity.H:37,
from viscosityModel/BirdCarreau/BirdCarreauViscosity.C:26:
lnInclude/viscosityModel.H: In static member function ‘static Foam::autoPtr<Foam::kineticTheoryModels::viscosity Model> Foam::kineticTheoryModels::viscosityModel::adddict ionaryConstructorToTable<viscosityModelType>::New( const Foam::dictionary&) [with viscosityModelType = Foam::kineticTheoryModels::BirdCarreauViscosity]’:
lnInclude/viscosityModel.H:86: instantiated from ‘Foam::kineticTheoryModels::viscosityModel::adddic tionaryConstructorToTable<viscosityModelType>::add dictionaryConstructorToTable(const Foam::word&) [with viscosityModelType = Foam::kineticTheoryModels::BirdCarreauViscosity]’
viscosityModel/BirdCarreau/BirdCarreauViscosity.C:42: instantiated from here
lnInclude/viscosityModel.H:77: error: cannot allocate an object of abstract type ‘Foam::kineticTheoryModels::BirdCarreauViscos ity’
viscosityModel/BirdCarreau/BirdCarreauViscosity.H:53: note: because the following virtual functions are pure within ‘Foam::kineticTheoryModels::BirdCarreauViscos ity’:
lnInclude/viscosityModel.H:109: note: virtual Foam::tmp<Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> > Foam::kineticTheoryModels::viscosityModel::mua(con st Foam::volScalarField&, const Foam::volScalarField&, const Foam::volScalarField&, const Foam::dimensionedScalar&, const Foam::dimensionedScalar&, const Foam::dimensionedScalar&) const
make: *** [Make/linuxGccDPOpt/BirdCarreauViscosity.o] Error 1
enoch is offline   Reply With Quote

Old   March 17, 2016, 10:53
Default Solved?
  #4
Member
 
Vinícius da Costa Ávila
Join Date: Jul 2015
Location: Porto Alegre, Brazil
Posts: 62
Rep Power: 11
avila.vc is on a distinguished road
Enoch, have you managed to solve the problem?
__________________
Vinícius dC.A.
avila.vc 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
Implementing new viscosity model prjohnston OpenFOAM Running, Solving & CFD 6 July 3, 2015 05:26
Yielding viscosity for Herschel Bulkley model Godwin FLUENT 1 December 12, 2011 06:42
Help with choosing a viscosity model xTamx420 FLUENT 5 July 4, 2011 18:09
Eddy Viscosity Model Parameters Tristan CFX 5 January 20, 2010 16:25
Casson Viscosity model as one user define function Zahra Rahmdel FLUENT 0 November 6, 2004 06:53


All times are GMT -4. The time now is 18:47.