|
[Sponsors] |
May 2, 2015, 08:40 |
Tensor Implementation into a Constructor
|
#1 |
Member
Paolo Capobianchi
Join Date: Sep 2014
Posts: 35
Rep Power: 11 |
Hello everyone,
I would like to ask some advices about the implementation of a new tensor into the constructor of an existing code. I have already created the tensor as an IOobject. The tensor sigma_ into this code: Code:
tau_ ( IOobject ( "tau" + name, U.time().timeName(), U.mesh(), IOobject::MUST_READ, IOobject::AUTO_WRITE ), U.mesh() ), sigma_ ( IOobject ( "sigma" + name, U.time().timeName(), U.mesh(), IOobject::MUST_READ, IOobject::AUTO_WRITE ), U.mesh() ), I_ ( dimensionedSymmTensor ( "I", dimensionSet(0, 0, 0, 0, 0, 0, 0), symmTensor ( 1, 0, 0, 1, 0, 1 ) ) ), rho_(dict.lookup("rho")), etaS_(dict.lookup("etaS")), etaP_(dict.lookup("etaP")), lambda_(dict.lookup("lambda")) { sigma_ = lambda_ * tau_ / etaP_ + I_; } Code:
sigma_ = lambda_ * tau_ / etaP_ + I_; p.s I have tried to use the options: IOobject::NO_READ, and IOobject::READ_IF_PRESENT, but I could not sort the problem out. Thank you very much. Cheers, Paolo |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[OpenFOAM.org] compile error in dynamicMesh and thermophysicalModels libraries | NickG | OpenFOAM Installation | 3 | December 30, 2019 00:21 |
Class Time constructor | maybee | OpenFOAM Programming & Development | 3 | November 25, 2013 16:05 |
MPI error with IBM XL compiler in the mesh constructor | nick.not.used | OpenFOAM Programming & Development | 0 | June 17, 2013 13:01 |
Inheriting kOmega: why can't I change the constructor? | AlmostSurelyRob | OpenFOAM | 4 | October 27, 2011 04:34 |
How does one initialise an OFstream in the constructor? | bigphil | OpenFOAM Programming & Development | 2 | August 18, 2011 08:48 |