|
[Sponsors] |
![]() |
![]() |
#1 |
New Member
Amirreza
Join Date: Mar 2020
Posts: 4
Rep Power: 5 ![]() |
I need to add as pollution source in my domain. I want to to do it by using a passiveScalar. then I used a scalerTransport class in controlDict:
HTML Code:
functions
{
pollution
{
type scalarTransport;
libs ("libsolverFunctionObjects.so");
// Optional entries
// Name of scalar field to transport, default = 's'
field s;
// Name of flux field, default = 'phi'
phi phi;
// Name of density field for compressible cases, default = 'rho'
rho rho;
// Name of phase field to constrain scalar to, default = 'none'
phase none;
// Set the scalar to zero on start/re-start
resetOnStartUp no;
// Name of field to use when looking up schemes from fvSchemes
// default = <field>
schemesField s;
// Diffusivity
// Fixed value diffusivity
D 0.0000176;
// Name of field to use as diffusivity, default = 'none'
nut nut;
// Run-time selectable sources
}
};
the problem is OpenFoam shows a fatal error: HTML Code:
[I]keyword diffusion is undefined in dictionary [/I]. |
|
![]() |
![]() |
![]() |
![]() |
#2 |
Senior Member
Join Date: Oct 2017
Posts: 115
Rep Power: 7 ![]() |
My guess is that you are using OpenFOAM from openfoam.org but the definitionen of the function object is for OpenFOAM from openfoam.com. Here you can see the explanation for the missing diffusion keyword: https://cpp.openfoam.org/v10/classFo...t.html#details (There it is written "diffusivity entry", but it should be "diffusion entry".)
|
|
![]() |
![]() |
![]() |
![]() |
#3 | |
New Member
Amirreza
Join Date: Mar 2020
Posts: 4
Rep Power: 5 ![]() |
Quote:
Thanks a million, your guess was right I corrected my code and it's done. |
||
![]() |
![]() |
![]() |
Tags |
functionobjects, scalartransport, simplefoam |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Add scalar "shift" to an already computed simulation | jcoelho5 | OpenFOAM Programming & Development | 1 | September 13, 2022 19:00 |
whats the cause of error? | immortality | OpenFOAM Running, Solving & CFD | 13 | March 24, 2021 07:15 |
Passive Scalar for particulate contamination spread | Owen2612 | Main CFD Forum | 0 | January 3, 2020 06:15 |
Is it possible add a passive scalar to an already finished simulation? | anon_q | OpenFOAM | 8 | April 3, 2018 03:06 |
Add passive scalar temperature equation to the Channelflow | YANGLIANG | OpenFOAM Running, Solving & CFD | 1 | March 9, 2010 05:23 |