fvOptions: Rationalize naming convention for constraints
This commit is contained in:
@ -192,9 +192,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write the source properties
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read source dictionary
|
//- Read source dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -27,50 +27,6 @@ License
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
void Foam::fv::cellSetOption::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
option::writeData(os);
|
|
||||||
|
|
||||||
os.writeKeyword("timeStart") << timeStart_ << token::END_STATEMENT << nl;
|
|
||||||
os.writeKeyword("duration") << duration_ << token::END_STATEMENT << nl;
|
|
||||||
os.writeKeyword("selectionMode")
|
|
||||||
<< selectionModeTypeNames_[selectionMode_] << nl;
|
|
||||||
|
|
||||||
switch (selectionMode_)
|
|
||||||
{
|
|
||||||
case smPoints:
|
|
||||||
{
|
|
||||||
os.writeKeyword("points") << points_
|
|
||||||
<< token::END_STATEMENT << nl;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case smCellSet:
|
|
||||||
{
|
|
||||||
os.writeKeyword("cellSet") << cellSetName_
|
|
||||||
<< token::END_STATEMENT << nl;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case smCellZone:
|
|
||||||
{
|
|
||||||
os.writeKeyword("cellZone") << cellSetName_
|
|
||||||
<< token::END_STATEMENT << nl;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case smAll:
|
|
||||||
{
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default:
|
|
||||||
{
|
|
||||||
FatalErrorIn("option::writeData(Ostream&) const")
|
|
||||||
<< "Unknown selectionMode "
|
|
||||||
<< selectionMode_
|
|
||||||
<< abort(FatalError);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::cellSetOption::read(const dictionary& dict)
|
bool Foam::fv::cellSetOption::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (option::read(dict))
|
if (option::read(dict))
|
||||||
|
|||||||
@ -107,7 +107,7 @@ bool Foam::fv::fixedTemperatureConstraint::alwaysApply() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::fixedTemperatureConstraint::setValue
|
void Foam::fv::fixedTemperatureConstraint::constrain
|
||||||
(
|
(
|
||||||
fvMatrix<scalar>& eqn,
|
fvMatrix<scalar>& eqn,
|
||||||
const label
|
const label
|
||||||
@ -148,13 +148,6 @@ void Foam::fv::fixedTemperatureConstraint::setValue
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::fixedTemperatureConstraint::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::fixedTemperatureConstraint::read(const dictionary& dict)
|
bool Foam::fv::fixedTemperatureConstraint::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (cellSetOption::read(dict))
|
if (cellSetOption::read(dict))
|
||||||
|
|||||||
@ -142,14 +142,11 @@ public:
|
|||||||
// Set values directly
|
// Set values directly
|
||||||
|
|
||||||
//- Scalar
|
//- Scalar
|
||||||
virtual void setValue(fvMatrix<scalar>& eqn, const label fieldI);
|
virtual void constrain(fvMatrix<scalar>& eqn, const label fieldI);
|
||||||
|
|
||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -125,13 +125,6 @@ void Foam::fv::temperatureLimitsConstraint::correct(volScalarField& he)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::temperatureLimitsConstraint::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::temperatureLimitsConstraint::read(const dictionary& dict)
|
bool Foam::fv::temperatureLimitsConstraint::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (cellSetOption::read(dict))
|
if (cellSetOption::read(dict))
|
||||||
|
|||||||
@ -120,9 +120,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -69,7 +69,7 @@ Foam::fv::ExplicitSetValue<Type>::ExplicitSetValue
|
|||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
void Foam::fv::ExplicitSetValue<Type>::setValue
|
void Foam::fv::ExplicitSetValue<Type>::constrain
|
||||||
(
|
(
|
||||||
fvMatrix<Type>& eqn,
|
fvMatrix<Type>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
@ -78,7 +78,7 @@ void Foam::fv::ExplicitSetValue<Type>::setValue
|
|||||||
if (debug)
|
if (debug)
|
||||||
{
|
{
|
||||||
Info<< "ExplicitSetValue<"<< pTraits<Type>::typeName
|
Info<< "ExplicitSetValue<"<< pTraits<Type>::typeName
|
||||||
<< ">::setValue for source " << name_ << endl;
|
<< ">::constrain for source " << name_ << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
List<Type> values(cells_.size(), injectionRate_[fieldI]);
|
List<Type> values(cells_.size(), injectionRate_[fieldI]);
|
||||||
|
|||||||
@ -108,14 +108,11 @@ public:
|
|||||||
// Evaluation
|
// Evaluation
|
||||||
|
|
||||||
//- Set value on field
|
//- Set value on field
|
||||||
virtual void setValue(fvMatrix<Type>& eqn, const label fieldI);
|
virtual void constrain(fvMatrix<Type>& eqn, const label fieldI);
|
||||||
|
|
||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write the source properties
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read source dictionary
|
//- Read source dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -27,14 +27,6 @@ License
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
|
||||||
void Foam::fv::ExplicitSetValue<Type>::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
bool Foam::fv::ExplicitSetValue<Type>::read(const dictionary& dict)
|
bool Foam::fv::ExplicitSetValue<Type>::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -61,7 +61,7 @@ Foam::fv::option::option
|
|||||||
mesh_(mesh),
|
mesh_(mesh),
|
||||||
dict_(dict),
|
dict_(dict),
|
||||||
coeffs_(dict.subDict(modelType + "Coeffs")),
|
coeffs_(dict.subDict(modelType + "Coeffs")),
|
||||||
active_(dict_.lookupOrDefault<bool>("active", true)),
|
active_(dict_.lookupOrDefault<Switch>("active", true)),
|
||||||
fieldNames_(),
|
fieldNames_(),
|
||||||
applied_()
|
applied_()
|
||||||
{
|
{
|
||||||
@ -304,15 +304,15 @@ void Foam::fv::option::addSup
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::option::setValue(fvMatrix<scalar>& eqn, const label fieldI)
|
void Foam::fv::option::constrain(fvMatrix<scalar>& eqn, const label fieldI)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::option::setValue(fvMatrix<vector>& eqn, const label fieldI)
|
void Foam::fv::option::constrain(fvMatrix<vector>& eqn, const label fieldI)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::option::setValue
|
void Foam::fv::option::constrain
|
||||||
(
|
(
|
||||||
fvMatrix<sphericalTensor>& eqn,
|
fvMatrix<sphericalTensor>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
@ -320,7 +320,7 @@ void Foam::fv::option::setValue
|
|||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::option::setValue
|
void Foam::fv::option::constrain
|
||||||
(
|
(
|
||||||
fvMatrix<symmTensor>& eqn,
|
fvMatrix<symmTensor>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
@ -328,7 +328,7 @@ void Foam::fv::option::setValue
|
|||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::option::setValue(fvMatrix<tensor>& eqn, const label fieldI)
|
void Foam::fv::option::constrain(fvMatrix<tensor>& eqn, const label fieldI)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -46,6 +46,7 @@ SourceFiles
|
|||||||
#include "fvMatricesFwd.H"
|
#include "fvMatricesFwd.H"
|
||||||
#include "volFieldsFwd.H"
|
#include "volFieldsFwd.H"
|
||||||
#include "dictionary.H"
|
#include "dictionary.H"
|
||||||
|
#include "Switch.H"
|
||||||
#include "runTimeSelectionTables.H"
|
#include "runTimeSelectionTables.H"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
@ -84,7 +85,7 @@ protected:
|
|||||||
dictionary coeffs_;
|
dictionary coeffs_;
|
||||||
|
|
||||||
//- Source active flag
|
//- Source active flag
|
||||||
bool active_;
|
Switch active_;
|
||||||
|
|
||||||
//- Field names to apply source to - populated by derived models
|
//- Field names to apply source to - populated by derived models
|
||||||
wordList fieldNames_;
|
wordList fieldNames_;
|
||||||
@ -212,7 +213,7 @@ public:
|
|||||||
// Edit
|
// Edit
|
||||||
|
|
||||||
//- Return access to the source active flag
|
//- Return access to the source active flag
|
||||||
inline bool& active();
|
inline Switch& active();
|
||||||
|
|
||||||
|
|
||||||
// Checks
|
// Checks
|
||||||
@ -376,38 +377,38 @@ public:
|
|||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
// Set values directly
|
// Constraints
|
||||||
|
|
||||||
//- Scalar
|
//- Scalar
|
||||||
virtual void setValue
|
virtual void constrain
|
||||||
(
|
(
|
||||||
fvMatrix<scalar>& eqn,
|
fvMatrix<scalar>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Vector
|
//- Vector
|
||||||
virtual void setValue
|
virtual void constrain
|
||||||
(
|
(
|
||||||
fvMatrix<vector>& eqn,
|
fvMatrix<vector>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Spherical tensor
|
//- Spherical tensor
|
||||||
virtual void setValue
|
virtual void constrain
|
||||||
(
|
(
|
||||||
fvMatrix<sphericalTensor>& eqn,
|
fvMatrix<sphericalTensor>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Symmetric tensor
|
//- Symmetric tensor
|
||||||
virtual void setValue
|
virtual void constrain
|
||||||
(
|
(
|
||||||
fvMatrix<symmTensor>& eqn,
|
fvMatrix<symmTensor>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Tensor
|
//- Tensor
|
||||||
virtual void setValue
|
virtual void constrain
|
||||||
(
|
(
|
||||||
fvMatrix<tensor>& eqn,
|
fvMatrix<tensor>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
|
|||||||
@ -55,7 +55,7 @@ inline void Foam::fv::option::setApplied(const label fieldI)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
inline bool& Foam::fv::option::active()
|
inline Foam::Switch& Foam::fv::option::active()
|
||||||
{
|
{
|
||||||
return active_;
|
return active_;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -42,7 +42,11 @@ void Foam::fv::option::writeFooter(Ostream& os) const
|
|||||||
|
|
||||||
void Foam::fv::option::writeData(Ostream& os) const
|
void Foam::fv::option::writeData(Ostream& os) const
|
||||||
{
|
{
|
||||||
os.writeKeyword("active") << active_ << token::END_STATEMENT << nl;
|
os.writeKeyword("type") << type() << token::END_STATEMENT << nl;
|
||||||
|
os.writeKeyword("active") << active_ << token::END_STATEMENT << nl << nl;
|
||||||
|
|
||||||
|
os << indent << word(type() + "Coeffs");
|
||||||
|
coeffs_.write(os);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -148,7 +148,9 @@ bool Foam::fv::optionList::writeData(Ostream& os) const
|
|||||||
forAll(*this, i)
|
forAll(*this, i)
|
||||||
{
|
{
|
||||||
os << nl;
|
os << nl;
|
||||||
|
this->operator[](i).writeHeader(os);
|
||||||
this->operator[](i).writeData(os);
|
this->operator[](i).writeData(os);
|
||||||
|
this->operator[](i).writeFooter(os);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check state of IOstream
|
// Check state of IOstream
|
||||||
@ -158,17 +160,10 @@ bool Foam::fv::optionList::writeData(Ostream& os) const
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * IOstream Operators * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * IOstream Operators * * * * * * * * * * * * //
|
||||||
|
|
||||||
namespace Foam
|
Foam::Ostream& Foam::operator<<(Ostream& os, const fv::optionList& options)
|
||||||
{
|
{
|
||||||
Ostream& operator<<
|
options.writeData(os);
|
||||||
(
|
return os;
|
||||||
Ostream& os,
|
|
||||||
const fv::optionList& options
|
|
||||||
)
|
|
||||||
{
|
|
||||||
options.writeData(os);
|
|
||||||
return os;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -44,6 +44,16 @@ SourceFile
|
|||||||
|
|
||||||
namespace Foam
|
namespace Foam
|
||||||
{
|
{
|
||||||
|
|
||||||
|
// Forward declaration of friend functions and operators
|
||||||
|
|
||||||
|
namespace fv
|
||||||
|
{
|
||||||
|
class optionList;
|
||||||
|
}
|
||||||
|
|
||||||
|
Ostream& operator<<(Ostream& os, const fv::optionList& options);
|
||||||
|
|
||||||
namespace fv
|
namespace fv
|
||||||
{
|
{
|
||||||
|
|
||||||
@ -191,6 +201,7 @@ public:
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
} // End namespace fv
|
} // End namespace fv
|
||||||
|
|||||||
@ -241,7 +241,7 @@ void Foam::fv::optionList::constrain(fvMatrix<Type>& eqn)
|
|||||||
<< " to field " << eqn.psi().name() << endl;
|
<< " to field " << eqn.psi().name() << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
source.setValue(eqn, fieldI);
|
source.constrain(eqn, fieldI);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -108,9 +108,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -27,15 +27,6 @@ License
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
void Foam::fv::interRegionOption::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
option::writeData(os);
|
|
||||||
os.writeKeyword("master") << master_ << token::END_STATEMENT << nl;
|
|
||||||
os.writeKeyword("nbrRegionName") << nbrRegionName_
|
|
||||||
<< token::END_STATEMENT << nl;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::interRegionOption::read(const dictionary& dict)
|
bool Foam::fv::interRegionOption::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (option::read(dict))
|
if (option::read(dict))
|
||||||
|
|||||||
@ -158,13 +158,6 @@ void Foam::fv::actuationDiskSource::addSup
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::actuationDiskSource::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::actuationDiskSource::read(const dictionary& dict)
|
bool Foam::fv::actuationDiskSource::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (cellSetOption::read(dict))
|
if (cellSetOption::read(dict))
|
||||||
|
|||||||
@ -207,9 +207,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -308,13 +308,6 @@ void Foam::fv::effectivenessHeatExchangerSource::addSup
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::effectivenessHeatExchangerSource::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::effectivenessHeatExchangerSource::read(const dictionary& dict)
|
bool Foam::fv::effectivenessHeatExchangerSource::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (cellSetOption::read(dict))
|
if (cellSetOption::read(dict))
|
||||||
|
|||||||
@ -278,9 +278,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -123,13 +123,6 @@ void Foam::fv::explicitPorositySource::addSup
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::explicitPorositySource::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::explicitPorositySource::read(const dictionary& dict)
|
bool Foam::fv::explicitPorositySource::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (cellSetOption::read(dict))
|
if (cellSetOption::read(dict))
|
||||||
|
|||||||
@ -161,9 +161,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -214,7 +214,7 @@ void Foam::fv::pressureGradientExplicitSource::addSup
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::pressureGradientExplicitSource::setValue
|
void Foam::fv::pressureGradientExplicitSource::constrain
|
||||||
(
|
(
|
||||||
fvMatrix<vector>& eqn,
|
fvMatrix<vector>& eqn,
|
||||||
const label
|
const label
|
||||||
|
|||||||
@ -146,7 +146,7 @@ public:
|
|||||||
);
|
);
|
||||||
|
|
||||||
//- Set 1/A coefficient
|
//- Set 1/A coefficient
|
||||||
virtual void setValue
|
virtual void constrain
|
||||||
(
|
(
|
||||||
fvMatrix<vector>& eqn,
|
fvMatrix<vector>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
@ -155,9 +155,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write the source properties
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read source dictionary
|
//- Read source dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -27,18 +27,6 @@ License
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
|
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
|
||||||
|
|
||||||
void Foam::fv::pressureGradientExplicitSource::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
notImplemented
|
|
||||||
(
|
|
||||||
"void Foam::fv::pressureGradientExplicitSource::writeData"
|
|
||||||
"("
|
|
||||||
"Ostream&"
|
|
||||||
") const"
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::pressureGradientExplicitSource::read(const dictionary& dict)
|
bool Foam::fv::pressureGradientExplicitSource::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
notImplemented
|
notImplemented
|
||||||
|
|||||||
@ -111,12 +111,6 @@ void Foam::fv::radialActuationDiskSource::addSup
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::radialActuationDiskSource::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
actuationDiskSource::writeData(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::radialActuationDiskSource::read(const dictionary& dict)
|
bool Foam::fv::radialActuationDiskSource::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (actuationDiskSource::read(dict))
|
if (actuationDiskSource::read(dict))
|
||||||
|
|||||||
@ -163,9 +163,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -587,13 +587,6 @@ void Foam::fv::rotorDiskSource::addSup
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::rotorDiskSource::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::rotorDiskSource::read(const dictionary& dict)
|
bool Foam::fv::rotorDiskSource::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (cellSetOption::read(dict))
|
if (cellSetOption::read(dict))
|
||||||
|
|||||||
@ -307,9 +307,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write the source properties
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read source dictionary
|
//- Read source dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -255,9 +255,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write the source properties
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read source dictionary
|
//- Read source dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -27,13 +27,6 @@ License
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
|
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
|
||||||
|
|
||||||
void Foam::fv::solidificationMeltingSource::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::solidificationMeltingSource::read(const dictionary& dict)
|
bool Foam::fv::solidificationMeltingSource::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (cellSetOption::read(dict))
|
if (cellSetOption::read(dict))
|
||||||
|
|||||||
@ -94,13 +94,6 @@ void Foam::fv::tabulatedAccelerationSource::addSup
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::tabulatedAccelerationSource::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
option::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::tabulatedAccelerationSource::read(const dictionary& dict)
|
bool Foam::fv::tabulatedAccelerationSource::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (option::read(dict))
|
if (option::read(dict))
|
||||||
|
|||||||
@ -145,9 +145,6 @@ public:
|
|||||||
const label fieldi
|
const label fieldi
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -201,7 +201,7 @@ void Foam::fv::CodedSource<Type>::addSup
|
|||||||
|
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
void Foam::fv::CodedSource<Type>::setValue
|
void Foam::fv::CodedSource<Type>::constrain
|
||||||
(
|
(
|
||||||
fvMatrix<Type>& eqn,
|
fvMatrix<Type>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
@ -210,11 +210,11 @@ void Foam::fv::CodedSource<Type>::setValue
|
|||||||
if (debug)
|
if (debug)
|
||||||
{
|
{
|
||||||
Info<< "CodedSource<"<< pTraits<Type>::typeName
|
Info<< "CodedSource<"<< pTraits<Type>::typeName
|
||||||
<< ">::setValue for source " << name_ << endl;
|
<< ">::constrain for source " << name_ << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
updateLibrary(redirectType_);
|
updateLibrary(redirectType_);
|
||||||
redirectFvOption().setValue(eqn, fieldI);
|
redirectFvOption().constrain(eqn, fieldI);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -40,7 +40,7 @@ Description
|
|||||||
const label fieldI
|
const label fieldI
|
||||||
)
|
)
|
||||||
|
|
||||||
setValue
|
constrain
|
||||||
(
|
(
|
||||||
fvMatrix<Type}>& eqn,
|
fvMatrix<Type}>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
@ -217,7 +217,7 @@ public:
|
|||||||
);
|
);
|
||||||
|
|
||||||
//- Set value
|
//- Set value
|
||||||
virtual void setValue
|
virtual void constrain
|
||||||
(
|
(
|
||||||
fvMatrix<Type>& eqn,
|
fvMatrix<Type>& eqn,
|
||||||
const label fieldI
|
const label fieldI
|
||||||
@ -226,9 +226,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write the source properties
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read source dictionary
|
//- Read source dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -28,14 +28,6 @@ License
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
|
||||||
void Foam::fv::CodedSource<Type>::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
bool Foam::fv::CodedSource<Type>::read(const dictionary& dict)
|
bool Foam::fv::CodedSource<Type>::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -202,9 +202,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write the source properties
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read source dictionary
|
//- Read source dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -27,14 +27,6 @@ License
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
|
||||||
void Foam::fv::SemiImplicitSource<Type>::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
cellSetOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
bool Foam::fv::SemiImplicitSource<Type>::read(const dictionary& dict)
|
bool Foam::fv::SemiImplicitSource<Type>::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -288,13 +288,6 @@ void Foam::fv::interRegionExplicitPorositySource::addSup
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::interRegionExplicitPorositySource::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
interRegionOption::writeData(os);
|
|
||||||
dict_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::interRegionExplicitPorositySource::read(const dictionary& dict)
|
bool Foam::fv::interRegionExplicitPorositySource::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (interRegionOption::read(dict))
|
if (interRegionOption::read(dict))
|
||||||
|
|||||||
@ -164,9 +164,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -108,14 +108,6 @@ void Foam::fv::constantHeatTransfer::calculateHtc()
|
|||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::constantHeatTransfer::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
interRegionHeatTransferModel::writeData(os);
|
|
||||||
os << indent << type() + "Coeffs" << nl;
|
|
||||||
coeffs_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::constantHeatTransfer::read(const dictionary& dict)
|
bool Foam::fv::constantHeatTransfer::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (interRegionHeatTransferModel::read(dict))
|
if (interRegionHeatTransferModel::read(dict))
|
||||||
|
|||||||
@ -92,9 +92,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -188,9 +188,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -27,17 +27,6 @@ License
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
void Foam::fv::interRegionHeatTransferModel::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
interRegionOption::writeData(os);
|
|
||||||
|
|
||||||
os.writeKeyword("nbrModelName") << nbrModelName_
|
|
||||||
<< token::END_STATEMENT << nl;
|
|
||||||
os.writeKeyword("semiImplicit") << semiImplicit_ << token::END_STATEMENT
|
|
||||||
<< nl;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::interRegionHeatTransferModel::read(const dictionary& dict)
|
bool Foam::fv::interRegionHeatTransferModel::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (interRegionOption::read(dict))
|
if (interRegionOption::read(dict))
|
||||||
|
|||||||
@ -133,13 +133,6 @@ void Foam::fv::tabulatedHeatTransfer::calculateHtc()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::tabulatedHeatTransfer::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
interRegionHeatTransferModel::writeData(os);
|
|
||||||
coeffs_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::tabulatedHeatTransfer::read(const dictionary& dict)
|
bool Foam::fv::tabulatedHeatTransfer::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (interRegionHeatTransferModel::read(dict))
|
if (interRegionHeatTransferModel::read(dict))
|
||||||
|
|||||||
@ -109,9 +109,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict);
|
virtual bool read(const dictionary& dict);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -126,13 +126,6 @@ void Foam::fv::variableHeatTransfer::calculateHtc()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fv::variableHeatTransfer::writeData(Ostream& os) const
|
|
||||||
{
|
|
||||||
interRegionHeatTransferModel::writeData(os);
|
|
||||||
coeffs_.write(os);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::fv::variableHeatTransfer::read(const dictionary& dict)
|
bool Foam::fv::variableHeatTransfer::read(const dictionary& dict)
|
||||||
{
|
{
|
||||||
if (interRegionHeatTransferModel::read(dict))
|
if (interRegionHeatTransferModel::read(dict))
|
||||||
|
|||||||
@ -113,9 +113,6 @@ public:
|
|||||||
|
|
||||||
// IO
|
// IO
|
||||||
|
|
||||||
//- Write data
|
|
||||||
virtual void writeData(Ostream&) const;
|
|
||||||
|
|
||||||
//- Read dictionary
|
//- Read dictionary
|
||||||
virtual bool read(const dictionary& dict) ;
|
virtual bool read(const dictionary& dict) ;
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user