CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (https://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   Error appears only with kOmegaSST in HPC, while it works fine on my workstation (https://www.cfd-online.com/Forums/openfoam-programming-development/241625-error-appears-only-komegasst-hpc-while-works-fine-my-workstation.html)

ozgunoglu March 9, 2022 10:09

Error appears only with kOmegaSST in HPC, while it works fine on my workstation
 
Hello everyone,
I have a problem while using a custom solver together with kOmegaSST model.

Summary of the problem:
When I run with kOmegaSST turb. model in remote HPC (OFv1912), it gives an error at the end of the first iteration. The error only appears with kOmegaSST model, for example, no error appears with kOmega model. Meanwhile, this problem does not arise when I run exactly the same case/setup on my personal workstation.

The problem in detail:
I have a customized OpenFOAM solver, and I am trying to make a simulation using “kOmegaSST” RANS turbulence model. I am using the code both in my personal workstation and university cluster.

Running the case on my personal workstation.

No problem arises for both compilation of the solver and running the case.

Running the case in remote HPC

No problem when I compile the solver at remote HPC, but the error below appeared at the end of the first iteration



Code:

--> FOAM FATAL ERROR: 

Cannot dereference nullptr at index 2 in range [0,8) 
    From function const T& Foam::UPtrList<T>::operator[](Foam::label) const [with T = Foam::fvPatchField<double>; Foam::label = int] 
    in file /apps/Vera/software/OpenFOAM/v1912-foss-2019b/OpenFOAM-v1912/src/OpenFOAM/lnInclude/UPtrListI.H at line 204. 

FOAM aborting 

#0  Foam::error::printStack(Foam::Ostream&) at ??:? 
#1  Foam::error::abort() at ??:? 
#2  ? at /apps/Vera/software/OpenFOAM/v1912-foss-2019b/OpenFOAM-v1912/src/OpenFOAM/lnInclude/errorManip.H:93 (discriminator 4) 
#3  ? at /apps/Vera/software/OpenFOAM/v1912-foss-2019b/OpenFOAM-v1912/src/OpenFOAM/lnInclude/UPtrListI.H:207 
#4  ? at /apps/Vera/software/OpenFOAM/v1912-foss-2019b/OpenFOAM-v1912/src/OpenFOAM/lnInclude/scalarFieldField.C:92 (discriminator 2) 
#5  void Foam::divide<Foam::fvPatchField, Foam::volMesh>(Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>&, Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&) at /apps/Vera/software/OpenFOAM/v1912-foss-2019b/OpenFOAM-v1912/src/OpenFOAM/lnInclude/GeometricScalarField.C:116 
#6  Foam::tmp<Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> > Foam::operator/<Foam::fvPatchField, Foam::volMesh>(Foam::tmp<Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> > const&, Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&) at ??:? 
#7  Foam::kOmegaSSTBase<Foam::eddyViscosity<Foam::RASModel<Foam::EddyDiffusivity<Foam::ThermalDiffusivity<Foam::DbnsCavTurbulenceModel<Foam::equilibriumCavitationModel> > > > > >::F1(Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&) const at ??:? 
#8  Foam::kOmegaSSTBase<Foam::eddyViscosity<Foam::RASModel<Foam::EddyDiffusivity<Foam::ThermalDiffusivity<Foam::DbnsCavTurbulenceModel<Foam::equilibriumCavitationModel> > > > > >::correct() at ??:? 
#9  ? at ~/OpenFOAM/applications/dbnsCavitatingFoam/dbnsCavitatingFoam.C:136 
#10  __libc_start_main in /lib64/libc.so.6 
#11  ? at ??:? 
Aborted (core dumped)

  • The error only appears with “kOmegaSST” model. I have tried other RANS models and did not encounter any problem; the case is running just fine.
  • I have tested different geometries/meshes and different initial-boundary conditions to understand if the problem is case dependent, but the error again appeared.
  • I compiled the solver for different OpenFOAM versions (v18 and v20) and the problem is persistent. Moreover, different compilation methods (compile from source code or using pre-compiled versions) did not change the result

Hope that all is clear and someone would like to help.

Thanks!

ozgunoglu March 11, 2022 05:03

Additional details

Personal workstation foam bashrc setup

export WM_PROJECT_VERSION=v1912
export WM_COMPILER_TYPE=system
export WM_PRECISION_OPTION=DP
: ${WM_LABEL_SIZE:=32}; export WM_LABEL_SIZE
export WM_COMPILE_OPTION=Opt
export WM_MPLIB=SYSTEMOPENMPI
projectDir="$HOME/OpenFOAM/OpenFOAM-$WM_PROJECT_VERSION"
export WM_PROJECT_DIR="$projectDir"
export WM_PROJECT_USER_DIR="$HOME/$WM_PROJECT/$USER-$WM_PROJECT_VERSION"

Before compiling/running the code I am using following alias:

"alias of1912="source $HOME/OpenFOAM/OpenFOAM-v1912/etc/bashrc"

HPC foam bashrc setup

export WM_PROJECT_VERSION=v1912
export WM_COMPILER_TYPE=system
export WM_PRECISION_OPTION=DP
: ${WM_LABEL_SIZE:=32}; export WM_LABEL_SIZE
: ${WM_COMPILE_OPTION:=Opt}; export WM_COMPILE_OPTION
: ${WM_MPLIB:=EASYBUILDMPI}; export WM_MPLIB
projectDir="$HOME/OpenFOAM/OpenFOAM-$WM_PROJECT_VERSION"
export WM_PROJECT_DIR="$projectDir"
export WM_PROJECT_USER_DIR="$HOME/$WM_PROJECT/$USER-$WM_PROJECT_VERSION"

Before compiling/running the code I am using following alias:

alias of1912="module load GCC/8.3.0 OpenMPI/3.1.4; module load OpenFOAM/v1912; source $FOAM_BASH"

ozgunoglu March 20, 2022 04:37

Anyone experienced a similar problem?


All times are GMT -4. The time now is 17:07.