View Issue Details

IDProjectCategoryView StatusLast Update
0004055OpenFOAMBugpublic2024-02-21 16:24
Reporteragustinvo Assigned Tohenry  
Status resolvedResolutionfixed 
PlatformAnyOSAnyOS VersionAny
Product Version11 
Fixed in Version11 
Summary0004055: turbulenceFields function object does not access to fluidThermophysicalTransportModel
DescriptionIt is not possible to retrieve the kappaEff field, included in the functionObject turbulenceFields, because the if-condition of line 161

is never true. The postProcess application enters into another else-condition block and it crashes because no kappaEff field is found.
Steps To Reproduce1. Run a simulation with a fluid solver
2. Run foamPostprocess with the turbulenceFields function and the field kappaEff
3. Get the error:

Invalid field selection

    From function virtual bool Foam::functionObjects::turbulenceFields::execute()
    in file turbulenceFields/turbulenceFields.C at line 269.

FOAM exiting
Additional InformationSubstituting the line 161

    if (obr_.foundObject<fluidThermophysicalTransportModel>(phaseName_))

by this one

    if (obr_.foundType<fluidThermophysicalTransportModel>(phaseName_))

has worked for me.
TagsNo tags attached.



2024-02-21 15:12

manager   ~0013198

I just tested the turbulenceFields functionObject in OpenFOAM-dev and kappaEff is generated without any problem. Could you please confirm that this issue does not occur for you with OpenFOAM-dev?


2024-02-21 15:33

reporter   ~0013199

The commit in the dev branch

does indeed add the same line than the one I indicated, but in OF-11 the bug is there.

A fix could be done into this file in OF-11 as the one in OF-dev


2024-02-21 16:24

manager   ~0013200

Resolved by commit c7c47ff3f7b39ba0240b9bf5753c7e86bddaeb92

Issue History

Date Modified Username Field Change
2024-02-21 15:04 agustinvo New Issue
2024-02-21 15:12 henry Note Added: 0013198
2024-02-21 15:33 agustinvo Note Added: 0013199
2024-02-21 16:24 henry Assigned To => henry
2024-02-21 16:24 henry Status new => resolved
2024-02-21 16:24 henry Resolution open => fixed
2024-02-21 16:24 henry Fixed in Version => 11
2024-02-21 16:24 henry Note Added: 0013200