View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002240 | OpenFOAM | [All Projects] Bug | public | 2016-09-09 11:57 | 2016-09-09 12:34 |
Reporter | MattijsJ | Assigned To | henry | ||
Priority | low | Severity | minor | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Platform | GNU/Linux | OS | OpenSuSE | OS Version | 13.2 |
Product Version | dev | ||||
Fixed in Version | dev | ||||
Summary | 0002240: codedSource derives from cellSetOption but cannot use it | ||||
Description | codedSource derives from cellSetOption but the dynamically generated version does not. Hence the instantiated version cannot use the cell selection mechanism. Choices: 1. make generated version derive from cellSetOption as well 2. or have codedSource (derived from option) and new codedCellSource (derived from cellSetOption) | ||||
Tags | No tags attached. | ||||
|
codedFvOptionTemplate.C (4,722 bytes) |
|
codedFvOptionTemplate.H (4,913 bytes) |
|
CodedSource.C (5,679 bytes) |
|
CodedSource.H (5,942 bytes) |
|
fvOptions (2,131 bytes)
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: dev | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class dictionary; location "constant"; object fvOptions; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // energySource { type vectorCodedSource; //active yes; name sourceTime; vectorCodedSourceCoeffs { selectionMode all; //cellSet; //cellSet fields (U); codeInclude #{ #}; codeCorrect #{ Pout<< "**codeCorrect**" << endl; #}; codeAddSup #{ Pout<< "**codeAddSup**" << endl; const Time& time = mesh().time(); const scalarField& V = mesh_.V(); Pout<< "cells:" << cells() << endl; vectorField& heSource = eqn.source(); heSource -= sqr(time.value())*vector::one*V; #}; codeSetValue #{ Pout<< "**codeSetValue**" << endl; #}; // Dummy entry. Make dependent on above to trigger recompilation code #{ $codeInclude $codeCorrect $codeAddSup $codeSetValue #}; } sourceTimeCoeffs { $vectorCodedSourceCoeffs; } } // ************************************************************************* // |
|
I've uploaded the minimal changes for option 1. |
|
Resolved by commit 52323f8dd1db7a466e8a546996688acae84141b1 |
Date Modified | Username | Field | Change |
---|---|---|---|
2016-09-09 11:57 | MattijsJ | New Issue | |
2016-09-09 11:57 | MattijsJ | File Added: codedFvOptionTemplate.C | |
2016-09-09 11:58 | MattijsJ | File Added: codedFvOptionTemplate.H | |
2016-09-09 11:58 | MattijsJ | File Added: CodedSource.C | |
2016-09-09 11:59 | MattijsJ | File Added: CodedSource.H | |
2016-09-09 11:59 | MattijsJ | File Added: fvOptions | |
2016-09-09 12:00 | MattijsJ | Note Added: 0006851 | |
2016-09-09 12:34 | henry | Assigned To | => henry |
2016-09-09 12:34 | henry | Status | new => resolved |
2016-09-09 12:34 | henry | Resolution | open => fixed |
2016-09-09 12:34 | henry | Fixed in Version | => dev |
2016-09-09 12:34 | henry | Note Added: 0006852 |