View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002022 | OpenFOAM | public | 2016-03-08 13:51 | 2016-03-08 14:15 | |
Reporter | alexeym | Assigned To | henry | ||
Priority | normal | Severity | text | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Fixed in Version | dev | ||||
Summary | 0002022: Strange initialization of specularityCoefficient_ and restitutionCoefficient_ in JohnsonJacksonParticle*FvPatchScalarField.C | ||||
Description | Both fields are of dimensionedScalar type, yet they are initialized like scalarField: Foam::JohnsonJacksonParticleThetaFvPatchScalarField:: JohnsonJacksonParticleThetaFvPatchScalarField ( const fvPatch& p, const DimensionedField<scalar, volMesh>& iF ) : mixedFvPatchScalarField(p, iF), restitutionCoefficient_(p.size()), specularityCoefficient_(p.size()) {} Surely it is perfectly OK to initialized scalar with label, but constructors usage are a little bit misleading. | ||||
Steps To Reproduce | 1. Checkout sources 2. Go to - applications/solvers/multiphase/twoPhaseEulerFoam/phaseCompressibleTurbulenceModels/kineticTheoryModels/derivedFvPatchFields/JohnsonJacksonParticleTheta - applications/solvers/multiphase/twoPhaseEulerFoam/phaseCompressibleTurbulenceModels/kineticTheoryModels/derivedFvPatchFields/JohnsonJacksonParticleSlip - applications/solvers/multiphase/reactingEulerFoam/reactingTwoPhaseEulerFoam/twoPhaseCompressibleTurbulenceModels/kineticTheoryModels/derivedFvPatchFields/JohnsonJacksonParticleSlip - applications/solvers/multiphase/reactingEulerFoam/reactingTwoPhaseEulerFoam/twoPhaseCompressibleTurbulenceModels/kineticTheoryModels/derivedFvPatchFields/JohnsonJacksonParticleTheta 3. Check *.C files | ||||
Additional Information | Since further in the files these fields are initialized like: restitutionCoefficient_ ( "restitutionCoefficient", dimless, dict.lookup("restitutionCoefficient") ), instead of restitutionCoefficient_(p.size()) field could be initialized like: restitutionCoefficient_("restitutionCoefficient", dimless, 0.0) | ||||
Tags | No tags attached. | ||||
Date Modified | Username | Field | Change |
---|---|---|---|
2016-03-08 13:51 | alexeym | New Issue | |
2016-03-08 14:15 | henry | Note Added: 0006015 | |
2016-03-08 14:15 | henry | Status | new => resolved |
2016-03-08 14:15 | henry | Fixed in Version | => dev |
2016-03-08 14:15 | henry | Resolution | open => fixed |
2016-03-08 14:15 | henry | Assigned To | => henry |
2016-03-11 11:44 | administrator | Category | 3.0.1 => (No Category) |