|
[Sponsors] |
Fatal Error - incompressibleVoF massSource - OF v12 |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
August 19, 2024, 10:32 |
Fatal Error - incompressibleVoF massSource - OF v12
|
#1 |
New Member
Juan Pablo Carbajal
Join Date: Jun 2021
Posts: 23
Rep Power: 5 |
Dear all,
I am porting to OFv12 a case that worked perfectly in OFv11 (solver incompressibleVoF) that uses the massSource fvModel. Below is the OFv11 fvModels file: Code:
FoamFile { format ascii; class dictionary; location "constant"; object fvModels; } nucleation { type massSource; points ((0.0 0.0 0.0)); phase liquid; massFlowRate -2e-06; fieldValues { alpha.liquid 0; } } Code:
FoamFile { format ascii; class dictionary; location "constant"; object fvModels; } nucleation { type massSource; points ((0.0 0.0 0.0)); phase liquid; massFlowRate 2e-06; } Code:
sources { nucleation { type uniformFixedValue; uniformValue ...; } } When I try to run this case I get Code:
$ setFields && foamRun /*---------------------------------------------------------------------------*\ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org \\ / A nd | Version: 12 \\/ M anipulation | \*---------------------------------------------------------------------------*/ Build : 12-8b1612fe08a0 Exec : setFields Date : Aug 19 2024 Time : 15:27:11 ... nProcs : 1 sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE). fileModificationChecking : Monitoring run-time modified files using timeStampMaster (fileModificationSkew 10) allowSystemOperations : Allowing user-supplied system call operations // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time Create mesh for time = 0 Reading "setFieldsDict" Setting field default values Setting internal values of volScalarField alpha.liquid Setting internal values of volVectorField U Setting internal values of volScalarField p_rgh Setting field region values End /*---------------------------------------------------------------------------*\ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org \\ / A nd | Version: 12 \\/ M anipulation | \*---------------------------------------------------------------------------*/ Build : 12-8b1612fe08a0 Exec : foamRun Date : Aug 19 2024 Time : 15:27:11 ... nProcs : 1 sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE). fileModificationChecking : Monitoring run-time modified files using timeStampMaster (fileModificationSkew 10) allowSystemOperations : Allowing user-supplied system call operations // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time Create mesh for time = 0 Selecting solver incompressibleVoF Selecting viscosity model Newtonian Selecting viscosity model Newtonian No MRF models present Courant Number mean: 7.02426e-05 max: 0.000342466 Interface Courant Number mean: 0 max: 0 Selecting turbulence model type laminar Selecting laminar stress model Stokes DICPCG: Solving for pcorr, Initial residual = 1, Final residual = 9.24536e-06, No Iterations 197 Creating fvModels from "constant/fvModels" Selecting finite volume model type massSource Name: nucleation - selecting cells using points PIMPLE: No convergence criteria found PIMPLE: Operating solver in transient mode with 1 outer corrector PIMPLE: Operating solver in PISO mode Starting time loop Courant Number mean: 1.56909e-05 max: 0.000175292 Interface Courant Number mean: 0 max: 0 deltaT = 1.19999e-07 Time = 1.19999e-07s --> FOAM FATAL ERROR: Cannot add a mass source for field alpha.liquid to equation for alpha.liquid because this field's equation was not recognised as being in mass-conservative form From function void Foam::fv::massSourceBase::addSupType(Foam::VolField<Type>&, Foam::fvMatrix<Type>&) const [with Type = double; Foam::VolField<Type> = Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>] in file massSource/massSourceBase.C at line 65. FOAM exiting Any ideas welcomed. |
|
August 20, 2024, 07:25 |
|
#2 |
New Member
Juan Pablo Carbajal
Join Date: Jun 2021
Posts: 23
Rep Power: 5 |
Actually, I get the error even if I use the old configuration files without any edit.
Code:
--> FOAM FATAL ERROR: Cannot add a mass source for field alpha.liquid to equation for alpha.liquid because this field's equation was not recognised as being in mass-conservative form From function void Foam::fv::massSourceBase::addSupType(Foam::VolField<Type>&, Foam::fvMatrix<Type>&) const [with Type = double; Foam::VolField<Type> = Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>] in file massSource/massSourceBase.C at line 65. FOAM exiting Last edited by kakila; August 20, 2024 at 07:26. Reason: typo in CODE |
|
August 21, 2024, 08:24 |
|
#3 |
New Member
Juan Pablo Carbajal
Join Date: Jun 2021
Posts: 23
Rep Power: 5 |
Thanks to henry from the OpenFOAM issue tracker I could solve this.
Although massSource is listed in the table of fvModles available for the incompressibleVoF solver, it shouldn't be used with incompressible solvers (this is also noted in the documentation of massSource). To achieve injection of mass into the domain using incompressible solvers, use volumeSource instead. |
|
Tags |
mass source term, ofv12 |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
type limitTemperature problem | AdamRM | OpenFOAM Running, Solving & CFD | 6 | November 16, 2023 06:55 |
massSource of specie i into the domain | NuclearLeaf | OpenFOAM | 2 | July 25, 2022 12:24 |
Problems with PyFoam and batch file! | alfogianco | OpenFOAM Running, Solving & CFD | 0 | January 5, 2022 09:57 |
problem during mpi in server: expected Scalar, found on line 0 the word 'nan' | muth | OpenFOAM Running, Solving & CFD | 3 | August 27, 2018 05:18 |
error while compiling the USER Sub routine | CFD user | CFX | 3 | November 25, 2002 16:16 |