|
[Sponsors] |
November 19, 2013, 12:50 |
Viscosity model - Compressible flow
|
#1 |
Senior Member
Aurelien Thinat
Join Date: Jul 2010
Posts: 165
Rep Power: 16 |
Hi everyone,
I have some problems developping a viscosity model in OpenFoam-2.2.2. This model is quite simple : for a given value of the strain rate, I have a viscosity value. So this is what I'm trying : 1) copy paste "src/thermophysicalModels/specie/transport/sutherland" to "src/thermophysicalModels/specie/transport/myTotalTransport" 2) renamed everything, and cleaned the constructors and operators. 3) created a createFields.H file : Code:
#include "interpolationTable.H" interpolationTable<scalar> timeSeriesViscosity ( "constant/viscosity.dat" ); 5) Modified the function mu in the file "~I.H" Code:
template<class Thermo> inline Foam::scalar Foam::myTotalTransport<Thermo>::mu ( )const { volScalarField sr = strainRate(); return timeSeriesViscosity(sr.value()); } 7) Compiled : these are the errors - strainRate : working with incompressible models, but not here Code:
error : there are no arguments to 'strainRate' that depend on a template parameter, so a declaration of 'strainRate' must be available - interpolationTable : I have included "interpolationTable.H", so I don't understand this one : Code:
error: 'interpolationTable' does not name a type |
|
November 20, 2013, 05:33 |
|
#2 |
Senior Member
Aurelien Thinat
Join Date: Jul 2010
Posts: 165
Rep Power: 16 |
I'll start fixing the problem with the strainRate first. It seems it's not defined for compressible flow : as far as I understand the code, there is no volScalarFields defined at this level.
So I need to compute manually the value of the strain rate at the current cell. How can I get an access to - the velocity ? - symm() ? - fvc::grad() ? |
|
November 21, 2013, 05:14 |
|
#3 |
Senior Member
Aurelien Thinat
Join Date: Jul 2010
Posts: 165
Rep Power: 16 |
Hello everyone,
I did it with incompressible fluids. Then I compiled another thermo model for compressible fluids. And now I'm stuck with the selection table. Where is the file I need to modify to enable the choice ? heRhoThermo - pureMixture - myTransportModel - hconst - perfectFluid - specie - sensibleInternalEnergy I tried to modify the file /src/thermoPhysicalModels/specie/include/thermoPhysicsTypes.H, but there is no mention of perfectFluid in this file, I guess it's the wrong place. Thank you. EDIT : It seems it's the file rhoTermos.C. |
|
March 6, 2018, 08:08 |
|
#4 | |
Member
Alberto
Join Date: Sep 2013
Posts: 37
Rep Power: 13 |
Quote:
Hello Aurelien, Could you share how did you include the strain rate for compressible models?... It seems like an unanswered question everywhere. Thank you in advanced |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
compressible flow calculation error using rhoSimpleFoam solver | student4326 | OpenFOAM Running, Solving & CFD | 7 | November 2, 2015 12:34 |
Viscosity ratio in gamma-theta transition model based on k-w sst turb model | Qiaol618 | Main CFD Forum | 8 | June 9, 2012 07:43 |
modelling solids viscosity in eulerian multiphase model | derkaiser | FLUENT | 1 | December 5, 2011 04:42 |
compressible flow | maria teresa | FLUENT | 1 | September 7, 2007 17:58 |
urgent help needed with 2d compressible flow | James | FLUENT | 2 | June 20, 2007 05:22 |