View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0004201 | OpenFOAM | Bug | public | 2025-01-15 13:02 | 2025-01-15 13:56 |
Reporter | jcallaham | Assigned To | henry | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | closed | Resolution | no change required | ||
Product Version | dev | ||||
Summary | 0004201: viscousHeating fails with VoF | ||||
Description | Build: dev-78c0718aeca6 When used with VoF, the viscousHeating model attempts to open a phase-specific momentumTransport dictionary: ``` void Foam::fv::viscousHeating::addSup ( const volScalarField& alpha, const volScalarField& rho, const volScalarField& he, fvMatrix<scalar>& eqn ) const { const compressible::momentumTransportModel& momentumTransport = mesh().lookupType<compressible::momentumTransportModel>(phaseName_); volVectorField& U = const_cast<volVectorField&>(momentumTransport.U()); mesh().schemes().setFluxRequired(U.name()); eqn -= fvc::div ( fvc::dotInterpolate(momentumTransport.divDevTau(U)->flux(), U) ); } ``` So it might look for a file named momentumTransport.water, for instance | ||||
Steps To Reproduce | Add the viscousHeating model to tutorials/compressibleVoF/damBreak: constant/fvModels ``` /*--------------------------------*- C++ -*----------------------------------*\ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org \\ / A nd | Version: dev \\/ M anipulation | \*---------------------------------------------------------------------------*/ FoamFile { format ascii; class dictionary; location "constant"; object fvModels; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // turbulenceDamping { type compressible::VoFTurbulenceDamping; delta 1e-4; } viscousHeating { type viscousHeating; phase water; } //************************************************************************* // ``` | ||||
Additional Information | This appears to be resolved by removing the phaseName_ argument to the momentumTransport lookup: ``` const compressible::momentumTransportModel& momentumTransport = mesh().lookupType<compressible::momentumTransportModel>(); ``` If I'm misunderstanding and there is supposed to be an independent momentumTransport file for each phase, could you point me to any documentation or examples that show how to properly configure this? | ||||
Tags | No tags attached. | ||||