Merge branch 'comp-generated-methods' into 'develop'

Generated methods

See merge request Development/openfoam!335
This commit is contained in:
Andrew Heather
2020-01-30 12:39:48 +00:00
101 changed files with 878 additions and 1021 deletions

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2017-2019 OpenCFD Ltd.
Copyright (C) 2017-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -105,7 +105,7 @@ SourceFiles
namespace Foam
{
// Forward declarations
// Forward Declarations
template<unsigned Width> class PackedList;
class labelRange;
@ -230,7 +230,7 @@ public:
// Constructors
//- Null constructor
//- Default construct, zero-sized and no allocation
inline constexpr PackedList() noexcept;
//- Construct for given number of elements, initializes values to 0
@ -451,6 +451,7 @@ public:
class reference
{
protected:
friend class PackedList; // Access for parent
void operator&() = delete; // Refuse to provide its address
@ -472,10 +473,16 @@ public:
public:
//- Copy construct
reference(const reference&) = default;
//- Move construct
reference(reference&&) = default;
//- Value assignment
inline void operator=(const reference& other);
//- Value assignment.
//- Value assignment
inline void operator=(const unsigned int val);
//- Conversion operator.

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2019 OpenCFD Ltd.
Copyright (C) 2018-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -54,7 +54,7 @@ See also
namespace Foam
{
// Forward declarations
// Forward Declarations
class bitSet;
class labelRange;
@ -131,13 +131,14 @@ public:
class const_iterator;
typedef unsigned int const_reference;
//- Define class name and debug
//- Declare type-name (with debug switch)
ClassName("bitSet");
// Constructors
//- Construct an empty, zero-sized set
//- Default construct an empty, zero-sized set
inline bitSet() noexcept;
//- Construct from Istream
@ -438,6 +439,7 @@ public:
public PackedList<1>::reference
{
protected:
friend class bitSet; // Access for parent
void operator&() = delete; // Refuse to provide its address
@ -447,6 +449,12 @@ public:
public:
//- Copy construct
reference(const reference&) = default;
//- Move construct
reference(reference&&) = default;
//- Flip the bit at the position, no range-checking
inline void flip();
@ -474,7 +482,7 @@ public:
//- Global position of the current \a on bit
label pos_;
//- Construct null - an end iterator
//- Default construct - an end iterator
inline const_iterator() noexcept;
//- Construct begin iterator

View File

@ -206,7 +206,7 @@ public:
// Constructors
//- Construct null with default (128) table capacity
//- Default construct with default (128) table capacity
HashTable();
//- Construct given initial table capacity
@ -550,6 +550,7 @@ protected:
class Iterator
{
public:
// Typedefs
using iterator_category = std::forward_iterator_tag;
using difference_type = this_type::difference_type;
@ -671,6 +672,7 @@ public:
public Iterator<false>
{
public:
// Typedefs
using iterator_category = std::forward_iterator_tag;
using difference_type = this_type::difference_type;
@ -684,8 +686,8 @@ public:
// Constructors
//- Construct null (end iterator)
inline iterator() = default;
//- Default construct (end iterator)
iterator() = default;
//- Copy construct from similar access type
inline explicit iterator(const Iterator<false>& iter)
@ -729,6 +731,7 @@ public:
public Iterator<true>
{
public:
// Typedefs
using iterator_category = std::forward_iterator_tag;
using difference_type = this_type::difference_type;
@ -741,8 +744,11 @@ public:
// Constructors
//- Construct null (end iterator)
inline const_iterator() = default;
//- Default construct (end iterator)
const_iterator() = default;
//- Copy construct
const_iterator(const const_iterator&) = default;
//- Copy construct from similar access type
inline explicit const_iterator(const Iterator<true>& iter)
@ -781,8 +787,10 @@ public:
inline const_iterator& operator++();
inline const_iterator operator++(int);
// Assignment
//- Copy assignment
const_iterator& operator=(const const_iterator&) = default;
// Allow assign from iterator to const_iterator
@ -805,6 +813,7 @@ public:
public Iter
{
public:
using value_type = this_type::key_type;
using reference = const Key&;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2017-2019 OpenCFD Ltd.
Copyright (C) 2017-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -72,7 +72,7 @@ public:
//- Pointer to next entry in list
link* next_ = nullptr;
//- Null construct
//- Default construct
link() = default;
//- Check if the node is registered with the list
@ -85,7 +85,7 @@ public:
private:
// Private Member Data
// Private Data
//- Pointer to first element
link *first_ = nullptr;
@ -97,15 +97,6 @@ private:
label size_ = 0;
// Private Member Functions
//- No copy construct
DLListBase(const DLListBase&) = delete;
//- No copy assignment
void operator=(const DLListBase&) = delete;
protected:
// Protected Member Functions
@ -142,14 +133,19 @@ public:
friend class const_iterator;
// Constructors
// Generated Methods
//- Null construct
//- Default construct
DLListBase() = default;
//- No copy construct
DLListBase(const DLListBase&) = delete;
//- Destructor
~DLListBase() = default;
//- No copy assignment
void operator=(const DLListBase&) = delete;
//- Destructor
~DLListBase() = default;
// Member Functions
@ -233,6 +229,9 @@ public:
public:
//- Copy construct
iterator(const iterator&) = default;
//- Construct for a node on a list
inline iterator(DLListBase* list, link* item);
@ -280,15 +279,15 @@ public:
public:
//- Copy construct
const_iterator(const const_iterator&) = default;
//- Construct for a node on a list
inline const_iterator(const DLListBase* list, const link* item);
//- Copy construct from a non-const iterator
inline const_iterator(const DLListBase::iterator& iter);
//- Copy construct
const_iterator(const const_iterator&) = default;
//- The storage node
inline const link* get_node() const;
@ -308,6 +307,7 @@ public:
//- Move forward through list
inline void next();
//- Copy assignment
const_iterator& operator=(const const_iterator&) = default;
inline bool operator==(const const_iterator&) const;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2017-2019 OpenCFD Ltd.
Copyright (C) 2017-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -69,14 +69,14 @@ public:
//- Pointer to next entry in list
link* next_ = nullptr;
//- Null construct
//- Default construct
link() = default;
};
private:
// Private Member Data
// Private Data
//- A pointer to the last element.
// last_->next_ points to first element, i.e. circular storage
@ -86,15 +86,6 @@ private:
label size_ = 0;
// Private Member Functions
//- No copy construct
SLListBase(const SLListBase&) = delete;
//- No copy assignment
void operator=(const SLListBase&) = delete;
protected:
// Protected Member Functions
@ -130,14 +121,19 @@ public:
friend class const_iterator;
// Constructors
// Generated Methods
//- Null construct
//- Default construct
SLListBase() = default;
//- No copy construct
SLListBase(const SLListBase&) = delete;
//- Destructor
~SLListBase() = default;
//- No copy assignment
void operator=(const SLListBase&) = delete;
//- Destructor
~SLListBase() = default;
// Member Functions
@ -209,6 +205,9 @@ public:
public:
//- Copy construct
iterator(const iterator&) = default;
//- Construct for a node on the list
inline iterator(SLListBase* list, link* item);
@ -231,6 +230,7 @@ public:
//- Move forward through list
inline void next();
//- Copy assignment
inline void operator=(const iterator& iter);
inline bool operator==(const iterator& iter) const;
@ -254,15 +254,15 @@ public:
public:
//- Copy construct
const_iterator(const const_iterator&) = default;
//- Construct for a node on the list
inline const_iterator(const SLListBase* list, const link* item);
//- Construct from a non-const iterator
inline const_iterator(const SLListBase::iterator& iter);
//- Copy construct
const_iterator(const const_iterator&) = default;
//- The storage node
inline const link* get_node() const;
@ -282,6 +282,7 @@ public:
//- Move forward through list
inline void next();
//- Copy assignment
const_iterator& operator=(const const_iterator&) = default;
inline bool operator==(const const_iterator& iter) const;
@ -306,7 +307,6 @@ public:
//- No reverse iteration
const const_iterator& crend() const = delete;
};

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2017-2019 OpenCFD Ltd.
Copyright (C) 2017-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -135,7 +135,7 @@ public:
typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
// Static Member Functions
// Static Functions
//- Return a null FixedList
inline static const FixedList<T, N>& null();
@ -143,8 +143,8 @@ public:
// Constructors
//- Null constructor
inline FixedList() = default;
//- Default construct
FixedList() = default;
//- Construct and initialize all entries to given value
inline explicit FixedList(const T& val);
@ -155,7 +155,7 @@ public:
//- Copy construct from C-array
inline explicit FixedList(const T list[N]);
//- Copy constructor
//- Copy construct
inline FixedList(const FixedList<T, N>& list);
//- Move construct by using move assignment for the individual

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2017-2019 OpenCFD Ltd.
Copyright (C) 2017-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -50,7 +50,7 @@ SourceFiles
namespace Foam
{
// Forward declarations
// Forward Declarations
template<class T> class SubList;
// Common list types
@ -70,12 +70,18 @@ class SubList
{
public:
// Static Member Functions
// Static Functions
//- Return a null SubList
inline static const SubList<T>& null();
// Generated Methods
//- Copy construct
SubList(const SubList&) = default;
// Constructors
//- Construct from UList, the entire size
@ -122,7 +128,7 @@ public:
//- Copy assign entries from given sub-list
inline void operator=(const SubList<T>& list);
//- Copy assign entries to the given list
//- Copy assign entries from given list
inline void operator=(const UList<T>& list);
//- Assign all entries to the given value

View File

@ -66,7 +66,7 @@ SourceFiles
namespace Foam
{
// Forward declarations
// Forward Declarations
class labelRange;
template<class T> class List;
template<class T> class SubList;
@ -87,7 +87,7 @@ typedef UList<label> labelUList; //!< A UList of labels
template<class T>
class UList
{
// Private data
// Private Data
//- Number of elements in UList
label size_;
@ -167,13 +167,13 @@ public:
friend class SubList<T>;
// Static Member Functions
// Static Functions
//- Return a UList reference to a nullObject
inline static const UList<T>& null();
// Public classes
// Public Classes
//- A list compare binary predicate for normal sort
struct less
@ -208,9 +208,15 @@ public:
};
// Generated Methods
//- Copy construct
UList(const UList<T>&) = default;
// Constructors
//- Null constructor
//- Default construct, zero-sized and nullptr
inline constexpr UList() noexcept;
//- Construct from components
@ -331,7 +337,7 @@ public:
void deepCopy(const UList<T>& list);
// Member operators
// Member Operators
//- Return element of UList
inline T& operator[](const label i);

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -73,7 +74,7 @@ class pTraits<List<T>>
public:
typedef label cmptType;
pTraits(Istream& is)
explicit pTraits(Istream& is)
:
List<T>(is)
{}
@ -87,7 +88,7 @@ class pTraits<UList<T>>
public:
typedef label cmptType;
pTraits(Istream& is)
explicit pTraits(Istream& is)
:
UList<T>(is)
{}
@ -101,7 +102,7 @@ class pTraits<Field<T>>
public:
typedef label cmptType;
pTraits(Istream& is)
explicit pTraits(Istream& is)
:
Field<T>(is)
{}
@ -115,7 +116,7 @@ class pTraits<face>
public:
typedef label cmptType;
pTraits(Istream& is)
explicit pTraits(Istream& is)
:
face(is)
{}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016-2017 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -58,11 +58,13 @@ class Barycentric
{
public:
//- Equivalent type of labels used for valid component indexing
typedef Barycentric<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef Barycentric<label> labelType;
// Member constants
// Member Constants
//- Rank of Barycentric is 1
static constexpr direction rank = 1;
@ -72,15 +74,18 @@ public:
enum components { A, B, C, D };
// Constructors
// Generated Methods
//- Construct null
inline Barycentric();
//- Default construct
Barycentric() = default;
// Constructors
//- Construct initialized to zero
inline Barycentric(const Foam::zero);
//- Construct given four components
//- Construct from components
inline Barycentric
(
const Cmpt& va,

View File

@ -27,11 +27,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::Barycentric<Cmpt>::Barycentric()
{}
template<class Cmpt>
inline Foam::Barycentric<Cmpt>::Barycentric(const Foam::zero)
:

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -61,11 +61,13 @@ class BarycentricTensor
{
public:
//- Equivalent type of labels used for valid component indexing
typedef Tensor<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef Tensor<label> labelType;
// Member constants
// Member Constants
//- Rank of BarycentricTensor is 2
static constexpr direction rank = 2;
@ -75,16 +77,19 @@ public:
enum components { XA, XB, XC, XD, YA, YB, YC, YD, ZA, ZB, ZC, ZD };
// Generated Methods
//- Default construct
BarycentricTensor() = default;
// Constructors
//- Construct null
BarycentricTensor();
//- Construct initialised to zero
BarycentricTensor(const Foam::zero);
inline BarycentricTensor(const Foam::zero);
//- Construct given three barycentric components (rows)
BarycentricTensor
inline BarycentricTensor
(
const Barycentric<Cmpt>& x,
const Barycentric<Cmpt>& y,
@ -92,7 +97,7 @@ public:
);
//- Construct given four vector components (columns)
BarycentricTensor
inline BarycentricTensor
(
const Vector<Cmpt>& a,
const Vector<Cmpt>& b,

View File

@ -27,11 +27,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::BarycentricTensor<Cmpt>::BarycentricTensor()
{}
template<class Cmpt>
inline Foam::BarycentricTensor<Cmpt>::BarycentricTensor(const Foam::zero)
:

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -30,7 +31,7 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::barycentric barycentric01
static inline Foam::barycentric barycentric01Impl
(
Foam::scalar s,
Foam::scalar t,
@ -71,13 +72,11 @@ Foam::barycentric barycentric01
Foam::barycentric Foam::barycentric01(Random& rndGen)
{
return
::barycentric01
(
rndGen.sample01<scalar>(),
rndGen.sample01<scalar>(),
rndGen.sample01<scalar>()
);
const scalar s(rndGen.sample01<scalar>());
const scalar t(rndGen.sample01<scalar>());
const scalar u(rndGen.sample01<scalar>());
return barycentric01Impl(s, t, u);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -58,11 +58,13 @@ class Barycentric2D
{
public:
//- Equivalent type of labels used for valid component indexing
typedef Barycentric2D<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef Barycentric2D<label> labelType;
// Member constants
// Member Constants
//- Rank of Barycentric2D is 1
static constexpr direction rank = 1;
@ -72,15 +74,18 @@ public:
enum components { A, B, C };
// Constructors
// Generated Methods: copy construct/assignment
//- Construct null
inline Barycentric2D();
//- Default construct
Barycentric2D() = default;
// Constructors
//- Construct initialized to zero
inline Barycentric2D(const Foam::zero);
//- Construct given four components
//- Construct from components
inline Barycentric2D
(
const Cmpt& va,
@ -109,7 +114,6 @@ public:
//- True if any coordinates are negative
inline bool outside() const;
};

View File

@ -28,11 +28,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::Barycentric2D<Cmpt>::Barycentric2D()
{}
template<class Cmpt>
inline Foam::Barycentric2D<Cmpt>::Barycentric2D(const Foam::zero)
:

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -30,7 +31,7 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::barycentric2D barycentric2D01
static inline Foam::barycentric2D barycentric2D01Impl
(
Foam::scalar s,
Foam::scalar t
@ -53,12 +54,10 @@ Foam::barycentric2D barycentric2D01
Foam::barycentric2D Foam::barycentric2D01(Random& rndGen)
{
return
::barycentric2D01
(
rndGen.sample01<scalar>(),
rndGen.sample01<scalar>()
);
const scalar s(rndGen.sample01<scalar>());
const scalar t(rndGen.sample01<scalar>());
return barycentric2D01Impl(s, t);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -58,14 +58,15 @@ class DiagTensor
:
public VectorSpace<DiagTensor<Cmpt>, Cmpt, 3>
{
public:
//- Equivalent type of labels used for valid component indexing
typedef DiagTensor<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef DiagTensor<label> labelType;
// Member constants
// Member Constants
//- Rank of DiagTensor is 2
static constexpr direction rank = 2;
@ -75,10 +76,19 @@ public:
enum components { XX, YY, ZZ };
// Constructors
// Generated Methods
//- Construct null
inline DiagTensor();
//- Default construct
DiagTensor() = default;
//- Copy construct
DiagTensor(const DiagTensor&) = default;
//- Copy assignment
DiagTensor& operator=(const DiagTensor&) = default;
// Constructors
//- Construct initialized to zero
inline DiagTensor(const Foam::zero);
@ -91,7 +101,7 @@ public:
inline DiagTensor(const Cmpt& txx, const Cmpt& tyy, const Cmpt& tzz);
//- Construct from Istream
inline DiagTensor(Istream&);
inline explicit DiagTensor(Istream& is);
// Member Functions

View File

@ -30,11 +30,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::DiagTensor<Cmpt>::DiagTensor()
{}
template<class Cmpt>
inline Foam::DiagTensor<Cmpt>::DiagTensor(const Foam::zero)
:
@ -289,7 +284,10 @@ inline Cmpt tr(const DiagTensor<Cmpt>& dt)
template<class Cmpt>
inline SphericalTensor<Cmpt> sph(const DiagTensor<Cmpt>& dt)
{
return 0.5*tr(dt);
return SphericalTensor<Cmpt>
(
1.0/3.0*tr(dt)
);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -60,34 +60,35 @@ class MatrixSpace
:
public VectorSpace<Form, Cmpt, Mrows*Ncols>
{
public:
//- MatrixSpace type
typedef MatrixSpace<Form, Cmpt, Mrows, Ncols> msType;
// Typedefs
//- MatrixSpace type
typedef MatrixSpace<Form, Cmpt, Mrows, Ncols> msType;
// Member constants
// Member Constants
static constexpr direction mRows = Mrows;
static constexpr direction nCols = Ncols;
// Static member functions
// Static Member Functions
//- Return the number of rows
//- The number of rows
static direction m() noexcept
{
return Mrows;
}
//- Return the number of columns
//- The number of columns
static direction n() noexcept
{
return Ncols;
}
//- Return the identity matrix for square matrix spaces
//- An identity matrix for square matrix-spaces
inline static msType identity();
@ -149,13 +150,13 @@ public:
static const direction mRows = SubTensor::mRows;
static const direction nCols = SubTensor::nCols;
//- Return the number of rows in the block
//- The number of rows in the block
static direction m()
{
return mRows;
}
//- Return the number of columns in the block
//- The number of columns in the block
static direction n()
{
return nCols;
@ -199,10 +200,13 @@ public:
};
// Constructors
// Generated Methods
//- Construct null
inline MatrixSpace();
//- Default construct
MatrixSpace() = default;
// Constructors
//- Construct initialized to zero
inline MatrixSpace(const Foam::zero);
@ -227,7 +231,7 @@ public:
);
//- Construct from Istream
MatrixSpace(Istream&);
explicit MatrixSpace(Istream& is);
// Member Functions

View File

@ -29,11 +29,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Form, class Cmpt, Foam::direction Mrows, Foam::direction Ncols>
inline Foam::MatrixSpace<Form, Cmpt, Mrows, Ncols>::MatrixSpace()
{}
template<class Form, class Cmpt, Foam::direction Mrows, Foam::direction Ncols>
inline Foam::MatrixSpace<Form, Cmpt, Mrows, Ncols>::MatrixSpace
(

View File

@ -70,18 +70,19 @@ class pTraits<Scalar>
public:
//- Component type
typedef Scalar cmptType;
// Typedefs
//- Magnitude type
typedef Scalar magType;
//- Component type
typedef Scalar cmptType;
//- Equivalent type of labels used for valid component indexing
typedef label labelType;
//- Magnitude type
typedef Scalar magType;
//- Equivalent type of labels used for valid component indexing
typedef label labelType;
// Member constants
// Member Constants
//- Dimensionality of space
static constexpr direction dim = 3;
@ -93,7 +94,7 @@ public:
static constexpr direction nComponents = 1;
// Static data members
// Static Data Members
static const char* const typeName;
static const char* const componentNames[];
@ -108,11 +109,11 @@ public:
// Constructors
//- Construct from primitive
//- Copy construct from primitive
explicit pTraits(const Scalar& val);
//- Construct from Istream
pTraits(Istream& is);
//- Read construct from Istream
explicit pTraits(Istream& is);
// Member Functions

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -57,20 +57,21 @@ class SphericalTensor
:
public VectorSpace<SphericalTensor<Cmpt>, Cmpt, 1>
{
public:
//- Equivalent type of labels used for valid component indexing
typedef SphericalTensor<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef SphericalTensor<label> labelType;
// Member constants
// Member Constants
//- Rank of SphericalTensor is 2
static constexpr direction rank = 2;
// Static data members
// Static Data Members
static const SphericalTensor I;
static const SphericalTensor oneThirdI;
@ -81,10 +82,19 @@ public:
enum components { II };
// Constructors
// Generated Methods
//- Construct null
inline SphericalTensor();
//- Default construct
SphericalTensor() = default;
//- Copy construct
SphericalTensor(const SphericalTensor&) = default;
//- Copy assignment
SphericalTensor& operator=(const SphericalTensor&) = default;
// Constructors
//- Construct initialized to zero
inline SphericalTensor(const Foam::zero);
@ -97,10 +107,10 @@ public:
);
//- Construct given the component
inline SphericalTensor(const Cmpt& tii);
inline explicit SphericalTensor(const Cmpt& tii);
//- Construct from Istream
inline SphericalTensor(Istream&);
inline explicit SphericalTensor(Istream& is);
// Member Functions
@ -111,7 +121,7 @@ public:
inline Cmpt& ii();
//- Transpose
//- Transpose (no-op)
inline const SphericalTensor<Cmpt>& T() const;
};

View File

@ -29,11 +29,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::SphericalTensor<Cmpt>::SphericalTensor()
{}
template<class Cmpt>
inline Foam::SphericalTensor<Cmpt>::SphericalTensor(const Foam::zero)
:

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -57,16 +57,21 @@ class SphericalTensor2D
:
public VectorSpace<SphericalTensor2D<Cmpt>, Cmpt, 1>
{
public:
// Member constants
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef SphericalTensor2D<label> labelType;
// Member Constants
//- Rank of SphericalTensor2D is 2
static constexpr direction rank = 2;
// Static data members
// Static Data Members
static const SphericalTensor2D I;
static const SphericalTensor2D oneThirdI;
@ -77,10 +82,19 @@ public:
enum components { II };
// Constructors
// Generated Methods
//- Construct null
inline SphericalTensor2D();
//- Default construct
SphericalTensor2D() = default;
//- Copy construct
SphericalTensor2D(const SphericalTensor2D&) = default;
//- Copy assignment
SphericalTensor2D& operator=(const SphericalTensor2D&) = default;
// Constructors
//- Construct initialized to zero
inline SphericalTensor2D(const Foam::zero);
@ -92,10 +106,10 @@ public:
);
//- Construct given the component
inline SphericalTensor2D(const Cmpt& tii);
inline explicit SphericalTensor2D(const Cmpt& tii);
//- Construct from Istream
inline SphericalTensor2D(Istream&);
inline explicit SphericalTensor2D(Istream& is);
// Member Functions

View File

@ -29,11 +29,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::SphericalTensor2D<Cmpt>::SphericalTensor2D()
{}
template<class Cmpt>
inline Foam::SphericalTensor2D<Cmpt>::SphericalTensor2D(const Foam::zero)
:

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -59,20 +59,21 @@ class SymmTensor
:
public VectorSpace<SymmTensor<Cmpt>, Cmpt, 6>
{
public:
//- Equivalent type of labels used for valid component indexing
typedef SymmTensor<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef SymmTensor<label> labelType;
// Member constants
// Member Constants
//- Rank of SymmTensor is 2
static constexpr direction rank = 2;
// Static data members
// Static Data Members
static const SymmTensor I;
@ -81,10 +82,19 @@ public:
enum components { XX, XY, XZ, YY, YZ, ZZ };
// Constructors
// Generated Methods
//- Construct null
inline SymmTensor();
//- Default construct
SymmTensor() = default;
//- Copy construct
SymmTensor(const SymmTensor&) = default;
//- Copy assignment
SymmTensor& operator=(const SymmTensor&) = default;
// Constructors
//- Construct initialized to zero
inline SymmTensor(const Foam::zero);
@ -105,7 +115,7 @@ public:
);
//- Construct from Istream
inline SymmTensor(Istream&);
inline explicit SymmTensor(Istream& is);
// Member Functions

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -30,11 +30,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::SymmTensor<Cmpt>::SymmTensor()
{}
template<class Cmpt>
inline Foam::SymmTensor<Cmpt>::SymmTensor(const Foam::zero)
:
@ -56,9 +51,9 @@ inline Foam::SymmTensor<Cmpt>::SymmTensor
template<class Cmpt>
inline Foam::SymmTensor<Cmpt>::SymmTensor(const SphericalTensor<Cmpt>& st)
{
this->v_[XX] = st.ii(); this->v_[XY] = 0; this->v_[XZ] = 0;
this->v_[YY] = st.ii(); this->v_[YZ] = 0;
this->v_[ZZ] = st.ii();
this->v_[XX] = st.ii(); this->v_[XY] = 0; this->v_[XZ] = 0;
this->v_[YY] = st.ii(); this->v_[YZ] = 0;
this->v_[ZZ] = st.ii();
}
@ -313,7 +308,10 @@ inline Cmpt tr(const SymmTensor<Cmpt>& st)
template<class Cmpt>
inline SphericalTensor<Cmpt> sph(const SymmTensor<Cmpt>& st)
{
return (1.0/3.0)*tr(st);
return SphericalTensor<Cmpt>
(
(1.0/3.0)*tr(st)
);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -59,20 +59,21 @@ class SymmTensor2D
:
public VectorSpace<SymmTensor2D<Cmpt>, Cmpt, 3>
{
public:
//- Equivalent type of labels used for valid component indexing
typedef SymmTensor2D<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef SymmTensor2D<label> labelType;
// Member constants
// Member Constants
//- Rank of SymmTensor2D is 2
static constexpr direction rank = 2;
// Static data members
// Static Data Members
static const SymmTensor2D I;
@ -81,10 +82,19 @@ public:
enum components { XX, XY, YY };
// Constructors
// Generated Methods
//- Construct null
inline SymmTensor2D();
//- Default construct
SymmTensor2D() = default;
//- Copy construct
SymmTensor2D(const SymmTensor2D&) = default;
//- Copy assignment
SymmTensor2D& operator=(const SymmTensor2D&) = default;
// Constructors
//- Construct initialized to zero
inline SymmTensor2D(const Foam::zero);
@ -103,7 +113,7 @@ public:
);
//- Construct from Istream
inline SymmTensor2D(Istream&);
inline explicit SymmTensor2D(Istream& is);
// Member Functions

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -30,11 +30,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::SymmTensor2D<Cmpt>::SymmTensor2D()
{}
template<class Cmpt>
inline Foam::SymmTensor2D<Cmpt>::SymmTensor2D(const Foam::zero)
:
@ -56,7 +51,7 @@ template<class Cmpt>
inline Foam::SymmTensor2D<Cmpt>::SymmTensor2D(const SphericalTensor2D<Cmpt>& st)
{
this->v_[XX] = st.ii(); this->v_[XY] = 0;
this->v_[YY] = st.ii();
this->v_[YY] = st.ii();
}
@ -252,7 +247,10 @@ inline Cmpt tr(const SymmTensor2D<Cmpt>& st)
template<class Cmpt>
inline SphericalTensor2D<Cmpt> sph(const SymmTensor2D<Cmpt>& st)
{
return (1.0/2.0)*tr(st);
return SphericalTensor2D<Cmpt>
(
0.5*tr(st)
);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2018-2019 OpenCFD Ltd.
Copyright (C) 2018-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -67,20 +67,21 @@ class Tensor
:
public MatrixSpace<Tensor<Cmpt>, Cmpt, 3, 3>
{
public:
//- Equivalent type of labels used for valid component indexing
typedef Tensor<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef Tensor<label> labelType;
// Member constants
// Member Constants
//- Rank of Tensor is 2
static constexpr direction rank = 2;
// Static data members
// Static Data Members
static const Tensor I;
@ -89,10 +90,19 @@ public:
enum components { XX, XY, XZ, YX, YY, YZ, ZX, ZY, ZZ };
// Constructors
// Generated Methods
//- Construct null
inline Tensor();
//- Default construct
Tensor() = default;
//- Copy construct
Tensor(const Tensor&) = default;
//- Copy assignment
Tensor& operator=(const Tensor&) = default;
// Constructors
//- Construct initialized to zero
inline Tensor(const Foam::zero);
@ -150,7 +160,7 @@ public:
);
//- Construct from Istream
inline Tensor(Istream& is);
inline explicit Tensor(Istream& is);
// Member Functions

View File

@ -30,11 +30,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::Tensor<Cmpt>::Tensor()
{}
template<class Cmpt>
inline Foam::Tensor<Cmpt>::Tensor(const Foam::zero)
:
@ -66,12 +61,10 @@ inline Foam::Tensor<Cmpt>::Tensor
template<class Cmpt>
inline Foam::Tensor<Cmpt>::Tensor(const SphericalTensor<Cmpt>& st)
:
Tensor::msType(Zero)
{
this->v_[XX] = st.ii();
this->v_[YY] = st.ii();
this->v_[ZZ] = st.ii();
this->v_[XX] = st.ii(); this->v_[XY] = 0; this->v_[XZ] = 0;
this->v_[YX] = 0; this->v_[YY] = st.ii(); this->v_[YZ] = 0;
this->v_[ZX] = 0; this->v_[ZY] = 0; this->v_[ZZ] = st.ii();
}
@ -706,7 +699,10 @@ inline Cmpt tr(const Tensor<Cmpt>& t)
template<class Cmpt>
inline SphericalTensor<Cmpt> sph(const Tensor<Cmpt>& t)
{
return (1.0/3.0)*tr(t);
return SphericalTensor<Cmpt>
(
(1.0/3.0)*tr(t)
);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2018-2019 OpenCFD Ltd.
Copyright (C) 2018-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -61,20 +61,21 @@ class Tensor2D
:
public VectorSpace<Tensor2D<Cmpt>, Cmpt, 4>
{
public:
//- Equivalent type of labels used for valid component indexing
typedef Tensor2D<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef Tensor2D<label> labelType;
// Member constants
// Member Constants
//- Rank of Tensor2D is 2
static constexpr direction rank = 2;
// Static data members
// Static Data Members
static const Tensor2D I;
@ -82,11 +83,18 @@ public:
//- Component labeling enumeration
enum components { XX, XY, YX, YY };
// Generated Methods
//- Construct null
//- Default construct
Tensor2D() = default;
//- Copy construct
Tensor2D(const Tensor2D&) = default;
//- Copy assignment
Tensor2D& operator=(const Tensor2D&) = default;
// Constructors
@ -117,7 +125,7 @@ public:
);
//- Construct from Istream
inline Tensor2D(Istream&);
inline explicit Tensor2D(Istream& is);
// Member Functions

View File

@ -55,11 +55,9 @@ inline Foam::Tensor2D<Cmpt>::Tensor2D(const SymmTensor2D<Cmpt>& st)
template<class Cmpt>
inline Foam::Tensor2D<Cmpt>::Tensor2D(const SphericalTensor2D<Cmpt>& st)
:
Tensor2D::vsType(Zero)
{
this->v_[XX] = st.ii();
this->v_[YY] = st.ii();
this->v_[XX] = st.ii(); this->v_[XY] = 0;
this->v_[YX] = 0; this->v_[YY] = st.ii();
}
@ -467,7 +465,10 @@ inline Cmpt tr(const Tensor2D<Cmpt>& t)
template<class Cmpt>
inline SphericalTensor2D<Cmpt> sph(const Tensor2D<Cmpt>& t)
{
return 0.5*tr(t);
return SphericalTensor2D<Cmpt>
(
0.5*tr(t)
);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -75,8 +75,8 @@ public:
// Constructors
//- Construct null
inline Tuple2() = default;
//- Default construct
Tuple2() = default;
//- Copy construct from components
inline Tuple2(const T1& f, const T2& s)

View File

@ -64,14 +64,15 @@ class Vector
:
public VectorSpace<Vector<Cmpt>, Cmpt, 3>
{
public:
//- Equivalent type of labels used for valid component indexing
typedef Vector<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef Vector<label> labelType;
// Member constants
// Member Constants
//- Rank of Vector is 1
static constexpr direction rank = 1;
@ -81,10 +82,19 @@ public:
enum components { X, Y, Z };
// Constructors
// Generated Methods
//- Construct null
inline Vector();
//- Default construct
Vector() = default;
//- Copy construct
Vector(const Vector&) = default;
//- Copy assignment
Vector& operator=(const Vector&) = default;
// Constructors
//- Construct initialized to zero
inline Vector(const Foam::zero);
@ -97,7 +107,7 @@ public:
inline Vector(const Cmpt& vx, const Cmpt& vy, const Cmpt& vz);
//- Construct from Istream
inline Vector(Istream& is);
inline explicit Vector(Istream& is);
// Member Functions
@ -130,7 +140,6 @@ public:
(
const Foam::List<Vector<Cmpt>>&
) const;
};

View File

@ -28,11 +28,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::Vector<Cmpt>::Vector()
{}
template<class Cmpt>
inline Foam::Vector<Cmpt>::Vector(const Foam::zero)
:

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2018-2019 OpenCFD Ltd.
Copyright (C) 2018-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -57,14 +57,15 @@ class Vector2D
:
public VectorSpace<Vector2D<Cmpt>, Cmpt, 2>
{
public:
//- Equivalent type of labels used for valid component indexing
typedef Vector2D<label> labelType;
// Typedefs
//- Equivalent type of labels used for valid component indexing
typedef Vector2D<label> labelType;
// Member constants
// Member Constants
//- Rank of Vector2D is 1
static constexpr direction rank = 1;
@ -74,10 +75,19 @@ public:
enum components { X, Y };
// Constructors
// Generated Methods
//- Construct null
inline Vector2D();
//- Default construct
Vector2D() = default;
//- Copy construct
Vector2D(const Vector2D&) = default;
//- Copy assignment
Vector2D& operator=(const Vector2D&) = default;
// Constructors
//- Construct initialized to zero
inline Vector2D(const Foam::zero);
@ -89,7 +99,7 @@ public:
inline Vector2D(const Cmpt& vx, const Cmpt& vy);
//- Construct from Istream
inline Vector2D(Istream& is);
inline explicit Vector2D(Istream& is);
// Member Functions
@ -113,7 +123,6 @@ public:
//- Perp dot product (dot product with perpendicular vector)
inline scalar perp(const Vector2D<Cmpt>& b) const;
};

View File

@ -28,11 +28,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Cmpt>
inline Foam::Vector2D<Cmpt>::Vector2D()
{}
template<class Cmpt>
inline Foam::Vector2D<Cmpt>::Vector2D(const Foam::zero)
:

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -52,7 +52,7 @@ SourceFiles
namespace Foam
{
// Forward declarations
// Forward Declarations
template<class Form, class Cmpt, direction Ncmpts> class VectorSpace;
@ -149,17 +149,17 @@ public:
};
// Constructors
// Generated Methods
//- Construct null
inline VectorSpace();
//- Default construct
VectorSpace() = default;
// Constructors
//- Construct initialized to zero
inline VectorSpace(const Foam::zero);
//- Construct from Istream
VectorSpace(Istream& is);
//- Copy construct
inline VectorSpace(const VectorSpace<Form, Cmpt, Ncmpts>& vs);
@ -167,11 +167,17 @@ public:
template<class Form2, class Cmpt2>
inline explicit VectorSpace(const VectorSpace<Form2, Cmpt2, Ncmpts>&);
//- Construct from Istream
explicit VectorSpace(Istream& is);
// Member Functions
//- Return the number of elements in the VectorSpace = Ncmpts.
inline static constexpr direction size();
//- The number of elements in the VectorSpace = Ncmpts.
static constexpr direction size() noexcept
{
return Ncmpts;
}
inline const Cmpt& component(const direction) const;
inline Cmpt& component(const direction);
@ -255,7 +261,7 @@ public:
};
// * * * * * * * * * * * * * * Global functions * * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * Global Functions * * * * * * * * * * * * * * //
//- A word representation of a VectorSpace
template<class Form, class Cmpt, direction Ncmpts>

View File

@ -32,14 +32,8 @@ License
#include "ops.H"
#include <type_traits>
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Form, class Cmpt, Foam::direction Ncmpts>
inline Foam::VectorSpace<Form, Cmpt, Ncmpts>::VectorSpace()
{}
template<class Form, class Cmpt, Foam::direction Ncmpts>
inline Foam::VectorSpace<Form, Cmpt, Ncmpts>::VectorSpace(const Foam::zero)
{
@ -88,13 +82,6 @@ inline Foam::VectorSpace<Form, Cmpt, Ncmpts>::ConstBlock<SubVector, BStart>
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class Form, class Cmpt, Foam::direction Ncmpts>
inline constexpr Foam::direction Foam::VectorSpace<Form, Cmpt, Ncmpts>::size()
{
return Ncmpts;
}
template<class Form, class Cmpt, Foam::direction Ncmpts>
inline const Cmpt& Foam::VectorSpace<Form, Cmpt, Ncmpts>::component
(

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -43,11 +43,10 @@ SourceFiles
namespace Foam
{
// Forward Declarations
class Istream;
class Ostream;
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Istream& operator>>(Istream& is, bool& b);
Ostream& operator<<(Ostream& os, const bool b);
@ -72,14 +71,16 @@ class pTraits<bool>
public:
//- Component type
typedef bool cmptType;
// Typedefs
//- Magnitude type
typedef bool magType;
//- Component type
typedef bool cmptType;
//- Magnitude type
typedef bool magType;
// Member constants
// Member Constants
//- Dimensionality of space
static constexpr direction dim = 3;
@ -91,7 +92,7 @@ public:
static constexpr direction nComponents = 1;
// Static data members
// Static Data Members
static const char* const typeName;
static const char* const componentNames[];
@ -101,11 +102,11 @@ public:
// Constructors
//- Construct from primitive
//- Copy construct from primitive
explicit pTraits(const bool& p);
//- Construct from Istream
pTraits(Istream& is);
//- Read construct from Istream
explicit pTraits(Istream& is);
// Member Functions

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2014 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -90,14 +90,26 @@ class complex
public:
// Generated Methods
//- Copy construct
complex(const complex&) = default;
//- Copy assignment
complex& operator=(const complex&) = default;
//- Move construct
complex(complex&&) = default;
//- Move assignment
complex& operator=(complex&&) = default;
// Constructors
//- Construct null as zero-initialized
//- Default construct, as zero-initialized
inline constexpr complex() noexcept;
//- Default copy constructor
complex(const complex&) = default;
//- Construct zero-initialized from zero class
inline constexpr complex(const Foam::zero) noexcept;
@ -173,9 +185,6 @@ public:
}
//- Copy assignment
inline void operator=(const complex& c);
//- Assign zero
inline void operator=(const Foam::zero);
@ -250,14 +259,16 @@ class pTraits<complex>
public:
//- Component type
typedef complex cmptType;
// Typedefs
//- Magnitude type
typedef scalar magType;
//- Component type
typedef complex cmptType;
//- Equivalent type of labels used for valid component indexing
typedef label labelType;
//- Magnitude type
typedef scalar magType;
//- Equivalent type of labels used for valid component indexing
typedef label labelType;
// Member Constants
@ -287,11 +298,11 @@ public:
// Constructors
//- Construct from primitive
//- Copy construct from primitive
explicit pTraits(const complex& val);
//- Construct from Istream
pTraits(Istream& is);
//- Read construct from Istream
explicit pTraits(Istream& is);
// Member Functions

View File

@ -116,13 +116,6 @@ inline Foam::complex Foam::complex::conjugate() const
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
inline void Foam::complex::operator=(const complex& c)
{
re = c.re;
im = c.im;
}
inline void Foam::complex::operator=(const Foam::zero)
{
re = 0;

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -63,18 +64,21 @@ class Uniform
:
public Constant<Type>
{
// Private Member Functions
public:
//- Declare type-name, virtual type (with debug switch)
TypeName("uniform");
// Generated Methods
//- Copy construct
Uniform<Type>(const Uniform&) = default;
//- No copy assignment
void operator=(const Uniform<Type>&) = delete;
public:
// Runtime type information
TypeName("uniform");
// Constructors
//- Construct from entry name and dictionary

View File

@ -34,33 +34,21 @@ Foam::Polynomial<PolySize>::Polynomial()
:
VectorSpace<Polynomial<PolySize>, scalar, PolySize>(),
logActive_(false),
logCoeff_(0.0)
logCoeff_(0)
{
for (int i = 0; i < PolySize; ++i)
{
this->v_[i] = 0.0;
this->v_[i] = 0;
}
}
template<int PolySize>
Foam::Polynomial<PolySize>::Polynomial
(
const Polynomial<PolySize>& poly
)
:
VectorSpace<Polynomial<PolySize>, scalar, PolySize>(poly),
logActive_(poly.logActive_),
logCoeff_(poly.logCoeff_)
{}
template<int PolySize>
Foam::Polynomial<PolySize>::Polynomial(const scalar coeffs[PolySize])
:
VectorSpace<Polynomial<PolySize>, scalar, PolySize>(),
logActive_(false),
logCoeff_(0.0)
logCoeff_(0)
{
for (int i=0; i<PolySize; i++)
{
@ -74,7 +62,7 @@ Foam::Polynomial<PolySize>::Polynomial(const UList<scalar>& coeffs)
:
VectorSpace<Polynomial<PolySize>, scalar, PolySize>(),
logActive_(false),
logCoeff_(0.0)
logCoeff_(0)
{
if (coeffs.size() != PolySize)
{
@ -96,7 +84,7 @@ Foam::Polynomial<PolySize>::Polynomial(Istream& is)
:
VectorSpace<Polynomial<PolySize>, scalar, PolySize>(is),
logActive_(false),
logCoeff_(0.0)
logCoeff_(0)
{}
@ -105,7 +93,7 @@ Foam::Polynomial<PolySize>::Polynomial(const word& name, Istream& is)
:
VectorSpace<Polynomial<PolySize>, scalar, PolySize>(),
logActive_(false),
logCoeff_(0.0)
logCoeff_(0)
{
word isName(is);

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -63,11 +64,10 @@ SourceFiles
namespace Foam
{
// Forward declaration of classes
// Forward Declarations
template<int PolySize>
class Polynomial;
// Forward declaration of friend functions
template<int PolySize>
Ostream& operator<<
(
@ -87,7 +87,7 @@ class Polynomial
{
static_assert(PolySize > 0, "Size must be positive (non-zero)");
// Private data
// Private Data
//- Include the log term? - only activated using integralMinus1()
bool logActive_;
@ -98,19 +98,20 @@ class Polynomial
public:
typedef Polynomial<PolySize> polyType;
// Public Typedefs
typedef Polynomial<PolySize+1> intPolyType;
typedef Polynomial<PolySize> polyType;
typedef Polynomial<PolySize+1> intPolyType;
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct null, with all coefficients = 0.0
//- Default construct, with all coefficients = 0
Polynomial();
//- Copy constructor
Polynomial(const Polynomial&);
//- Construct from C-array of coefficients
explicit Polynomial(const scalar coeffs[PolySize]);
@ -118,10 +119,10 @@ public:
explicit Polynomial(const UList<scalar>& coeffs);
//- Construct from Istream
Polynomial(Istream&);
explicit Polynomial(Istream& is);
//- Construct from name and Istream
Polynomial(const word& name, Istream&);
Polynomial(const word& name, Istream& is);
// Member Functions

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -51,7 +52,6 @@ namespace Foam
{
// Forward Declarations
class vectorTensorTransform;
Istream& operator>>(Istream& is, vectorTensorTransform&);
Ostream& operator<<(Ostream& os, const vectorTensorTransform& C);
@ -63,7 +63,7 @@ Ostream& operator<<(Ostream& os, const vectorTensorTransform& C);
class vectorTensorTransform
{
// private data
// Private Data
//- Translation vector
vector t_;
@ -79,7 +79,7 @@ class vectorTensorTransform
public:
// Static data members
// Static Data
static const char* const typeName;
@ -88,13 +88,30 @@ public:
static const vectorTensorTransform I;
// Generated Methods
//- Copy construct
vectorTensorTransform(const vectorTensorTransform&) = default;
//- Copy assignment
vectorTensorTransform&
operator=(const vectorTensorTransform&) = default;
//- Move construct
vectorTensorTransform(vectorTensorTransform&&) = default;
//- Move assignment
vectorTensorTransform&
operator=(vectorTensorTransform&&) = default;
// Constructors
//- Construct null
//- Default construct - no translation, identity rotation.
inline vectorTensorTransform();
//- Construct given a translation vector, rotation tensor and
// hasR bool
//- hasR bool
inline vectorTensorTransform
(
const vector& t,
@ -103,18 +120,18 @@ public:
);
//- Construct a pure translation vectorTensorTransform given a
// translation vector
//- translation vector
inline explicit vectorTensorTransform(const vector& t);
//- Construct a pure rotation vectorTensorTransform given a
// rotation tensor
//- rotation tensor
inline explicit vectorTensorTransform(const tensor& R);
//- Construct from Istream
vectorTensorTransform(Istream&);
explicit vectorTensorTransform(Istream&);
// Member functions
// Member Functions
// Access
@ -151,11 +168,11 @@ public:
tmp<Field<Type>> transform(const Field<Type>&) const;
// Member operators
// Member Operators
inline void operator=(const vectorTensorTransform&);
inline void operator&=(const vectorTensorTransform&);
//- Assign translation
inline void operator=(const vector&);
inline void operator+=(const vector&);
inline void operator-=(const vector&);
@ -164,7 +181,7 @@ public:
inline void operator&=(const tensor&);
// IOstream operators
// IOstream Operators
friend Istream& operator>>(Istream& is, vectorTensorTransform&);

View File

@ -173,17 +173,6 @@ inline Foam::pointField Foam::vectorTensorTransform::invTransformPosition
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
inline void Foam::vectorTensorTransform::operator=
(
const vectorTensorTransform& tr
)
{
t_ = tr.t_;
R_ = tr.R_;
hasR_ = tr.hasR_;
}
inline void Foam::vectorTensorTransform::operator&=
(
const vectorTensorTransform& tr

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2014-2016 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -47,7 +47,6 @@ SourceFiles
#include "pTraits.H"
#include "direction.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam
@ -139,14 +138,16 @@ class pTraits<int32_t>
public:
//- Component type
typedef int32_t cmptType;
// Typedefs
//- Magnitude type
typedef int32_t magType;
//- Component type
typedef int32_t cmptType;
//- Magnitude type
typedef int32_t magType;
// Member constants
// Member Constants
//- Dimensionality of space
static constexpr direction dim = 3;
@ -158,7 +159,7 @@ public:
static constexpr direction nComponents = 1;
// Static data members
// Static Data Members
static const char* const typeName;
static const char* const componentNames[];
@ -176,7 +177,7 @@ public:
explicit pTraits(const int32_t& val);
//- Read construct from Istream
pTraits(Istream& is);
explicit pTraits(Istream& is);
// Member Functions

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2014-2016 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -137,14 +137,16 @@ class pTraits<int64_t>
public:
//- Component type
typedef int64_t cmptType;
// Typedefs
//- Magnitude type
typedef int64_t magType;
//- Component type
typedef int64_t cmptType;
//- Magnitude type
typedef int64_t magType;
// Member constants
// Member Constants
//- Dimensionality of space
static constexpr direction dim = 3;
@ -156,7 +158,7 @@ public:
static constexpr direction nComponents = 1;
// Static data members
// Static Data Members
static const char* const typeName;
static const char* const componentNames[];
@ -174,7 +176,7 @@ public:
explicit pTraits(const int64_t& val);
//- Read construct from Istream
pTraits(Istream& is);
explicit pTraits(Istream& is);
// Member Functions

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2014-2016 OpenFOAM Foundation
Copyright (C) 2016-2017 OpenCFD Ltd.
Copyright (C) 2016-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -127,11 +127,13 @@ class pTraits<uint32_t>
public:
//- Component type
typedef uint32_t cmptType;
// Typedefs
//- Component type
typedef uint32_t cmptType;
// Member constants
// Member Constants
//- Dimensionality of space
static constexpr direction dim = 3;
@ -143,7 +145,7 @@ public:
static constexpr direction nComponents = 1;
// Static data members
// Static Data Members
static const char* const typeName;
static const char* const componentNames[];
@ -161,7 +163,7 @@ public:
explicit pTraits(const uint32_t& val);
//- Read construct from Istream
pTraits(Istream& is);
explicit pTraits(Istream& is);
// Member Functions

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2014-2016 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -136,11 +136,13 @@ class pTraits<uint64_t>
public:
//- Component type
typedef uint64_t cmptType;
// Typedefs
//- Component type
typedef uint64_t cmptType;
// Member constants
// Member Constants
//- Dimensionality of space
static constexpr direction dim = 3;
@ -152,7 +154,7 @@ public:
static constexpr direction nComponents = 1;
// Static data members
// Static Data Members
static const char* const typeName;
static const char* const componentNames[];
@ -170,7 +172,7 @@ public:
explicit pTraits(const uint64_t& val);
//- Read construct from Istream
pTraits(Istream& is);
explicit pTraits(Istream& is);
// Member Functions

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -43,6 +44,7 @@ Description
namespace Foam
{
// Forward Declarations
class Istream;
/*---------------------------------------------------------------------------*\
@ -54,19 +56,18 @@ class pTraits
:
public PrimitiveType
{
public:
// Constructors
//- Construct from primitive
pTraits(const PrimitiveType& p)
//- Copy construct from primitive
explicit pTraits(const PrimitiveType& p)
:
PrimitiveType(p)
{}
//- Construct from Istream
pTraits(Istream& is)
explicit pTraits(Istream& is)
:
PrimitiveType(is)
{}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -127,10 +127,25 @@ public:
static const quaternion I;
// Constructors
// Generated Methods
//- Construct null
inline quaternion();
//- Default construct
quaternion() = default;
//- Copy construct
quaternion(const quaternion&) = default;
//- Copy assignment
quaternion& operator=(const quaternion&) = default;
//- Move construct
quaternion(quaternion&&) = default;
//- Move assignment
quaternion& operator=(quaternion&&) = default;
// Constructors
//- Construct zero initialized
inline quaternion(const Foam::zero);
@ -193,7 +208,7 @@ public:
inline quaternion normalized() const;
// Edit
// Edit
//- Scalar part of the quaternion ( = cos(theta/2) for rotation)
inline scalar& w();
@ -205,7 +220,7 @@ public:
inline void normalize();
// Transform
// Transform
//- Rotate the given vector
inline vector transform(const vector& v) const;
@ -222,16 +237,15 @@ public:
// Member Operators
inline void operator=(const quaternion& q);
inline void operator+=(const quaternion& q);
inline void operator-=(const quaternion& q);
inline void operator*=(const quaternion& q);
inline void operator/=(const quaternion& q);
//- Change scalar portion
//- Change scalar portion only
inline void operator=(const scalar s);
//- Change vector portion
//- Change vector portion only
inline void operator=(const vector& v);
inline void operator*=(const scalar s);

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -28,13 +28,9 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
inline Foam::quaternion::quaternion()
{}
inline Foam::quaternion::quaternion(const Foam::zero)
:
w_(Zero),
w_(0),
v_(Zero)
{}
@ -585,12 +581,6 @@ inline Foam::vector Foam::quaternion::eulerAngles
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
inline void Foam::quaternion::operator=(const quaternion& q)
{
w_ = q.w_;
v_ = q.v_;
}
inline void Foam::quaternion::operator+=(const quaternion& q)
{
w_ += q.w_;

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -32,17 +33,15 @@ License
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
const char* const Foam::septernion::typeName = "septernion";
const Foam::septernion Foam::septernion::zero
(
vector(0, 0, 0),
quaternion(0, vector(0, 0, 0))
);
const Foam::septernion Foam::septernion::zero(Zero);
const Foam::septernion Foam::septernion::I
(
vector(0, 0, 0),
quaternion(1, vector(0, 0, 0))
vector(Zero),
quaternion(scalar(1))
);
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
Foam::septernion::septernion(Istream& is)

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -77,7 +77,7 @@ class septernion
public:
// Static data members
// Static Data
static const char* const typeName;
@ -85,10 +85,28 @@ public:
static const septernion I;
// Generated Methods
//- Default construct
septernion() = default;
//- Copy construct
septernion(const septernion&) = default;
//- Copy assignment
septernion& operator=(const septernion&) = default;
//- Move construct
septernion(septernion&&) = default;
//- Move assignment
septernion& operator=(septernion&&) = default;
// Constructors
//- Construct null
inline septernion();
//- Construct zero initialized
inline septernion(const Foam::zero);
//- Construct given a translation vector and rotation quaternion
inline septernion(const vector& t, const quaternion& r);
@ -103,24 +121,24 @@ public:
inline explicit septernion(const spatialTransform& st);
//- Construct from Istream
septernion(Istream&);
explicit septernion(Istream& is);
// Member functions
// Member Functions
// Access
// Access
inline const vector& t() const;
inline const quaternion& r() const;
// Edit
// Edit
inline vector& t();
inline quaternion& r();
// Transform
// Transform
//- Transform the given coordinate point
inline vector transformPoint(const vector& v) const;
@ -129,9 +147,8 @@ public:
inline vector invTransformPoint(const vector& v) const;
// Member operators
// Member Operators
inline void operator=(const septernion&);
inline void operator*=(const septernion&);
inline void operator=(const vector&);
@ -146,7 +163,7 @@ public:
inline void operator/=(const scalar);
// IOstream operators
// IOstream Operators
friend Istream& operator>>(Istream& is, septernion&);
friend Ostream& operator<<(Ostream& os, const septernion& C);

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -27,27 +28,34 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
inline Foam::septernion::septernion()
inline Foam::septernion::septernion(const Foam::zero)
:
t_(Zero),
r_(Zero)
{}
inline Foam::septernion::septernion(const vector& t, const quaternion& r)
:
t_(t),
r_(r)
{}
inline Foam::septernion::septernion(const vector& t)
:
t_(t),
r_(quaternion::I)
{}
inline Foam::septernion::septernion(const quaternion& r)
:
t_(Zero),
r_(r)
{}
inline Foam::septernion::septernion(const spatialTransform& st)
:
t_(st.r()),
@ -95,12 +103,6 @@ inline Foam::vector Foam::septernion::invTransformPoint(const vector& v) const
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
inline void Foam::septernion::operator=(const septernion& tr)
{
t_ = tr.t_;
r_ = tr.r_;
}
inline void Foam::septernion::operator*=(const septernion& tr)
{
t_ = tr.t() + tr.r().invTransform(t_);
@ -114,11 +116,13 @@ inline void Foam::septernion::operator=(const vector& t)
r_ = quaternion::I;
}
inline void Foam::septernion::operator+=(const vector& t)
{
t_ += t;
}
inline void Foam::septernion::operator-=(const vector& t)
{
t_ -= t;
@ -131,12 +135,14 @@ inline void Foam::septernion::operator=(const quaternion& r)
r_ = r;
}
inline void Foam::septernion::operator*=(const quaternion& r)
{
t_ = r.invTransform(t_);
r_ *= r;
}
inline void Foam::septernion::operator/=(const quaternion& r)
{
t_ = r.transform(t_);

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -65,8 +65,8 @@ public:
// Constructors
//- Construct an empty list
inline hashedWordList() = default;
//- Default construct an empty list
hashedWordList() = default;
//- Copy construct.
inline hashedWordList(const hashedWordList& list);

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -29,14 +30,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
Foam::referredWallFace::referredWallFace()
:
face(),
pts_(),
patchi_()
{}
Foam::referredWallFace::referredWallFace
(
const face& f,
@ -48,36 +41,16 @@ Foam::referredWallFace::referredWallFace
pts_(pts),
patchi_(patchi)
{
if (this->size() != pts_.size())
if (face::size() != pts_.size())
{
FatalErrorInFunction
<< "Face and pointField are not the same size. " << nl << (*this)
<< "Face and pointField are not the same size." << nl
<< (*this) << nl
<< abort(FatalError);
}
}
Foam::referredWallFace::referredWallFace(const referredWallFace& rWF)
:
face(rWF),
pts_(rWF.pts_),
patchi_(rWF.patchi_)
{
if (this->size() != pts_.size())
{
FatalErrorInFunction
<< "Face and pointField are not the same size. " << nl << (*this)
<< abort(FatalError);
}
}
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
Foam::referredWallFace::~referredWallFace()
{}
// * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * * //
bool Foam::referredWallFace::operator==(const referredWallFace& rhs) const

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -47,16 +48,11 @@ SourceFiles
namespace Foam
{
// Forward declaration of classes
class Istream;
class Ostream;
// Forward declaration of friend functions and operators
// Forward Declarations
class referredWallFace;
Istream& operator>>(Istream&, referredWallFace&);
Ostream& operator<<(Ostream&, const referredWallFace&);
/*---------------------------------------------------------------------------*\
Class referredWallFace Declaration
\*---------------------------------------------------------------------------*/
@ -65,7 +61,7 @@ class referredWallFace
:
public face
{
// Private data
// Private Data
//- Points of face
pointField pts_;
@ -76,10 +72,13 @@ class referredWallFace
public:
// Constructors
// Generated Methods
//- Construct null
referredWallFace();
//- Default construct
referredWallFace() = default;
// Constructors
//- Construct from components
referredWallFace
@ -89,13 +88,6 @@ public:
label patchi
);
//- Construct as copy
referredWallFace(const referredWallFace&);
//- Destructor
~referredWallFace();
// Member Functions
@ -119,6 +111,7 @@ public:
bool operator==(const referredWallFace&) const;
bool operator!=(const referredWallFace&) const;
// IOstream Operators
friend Istream& operator>>(Istream&, referredWallFace&);

View File

@ -25,8 +25,6 @@ License
\*---------------------------------------------------------------------------*/
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
const Foam::pointField& Foam::referredWallFace::points() const

View File

@ -31,14 +31,6 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class PairType, class WallType>
Foam::CollisionRecordList<PairType, WallType>::CollisionRecordList()
:
pairRecords_(),
wallRecords_()
{}
template<class PairType, class WallType>
Foam::CollisionRecordList<PairType, WallType>::CollisionRecordList(Istream& is)
:
@ -123,13 +115,6 @@ Foam::CollisionRecordList<PairType, WallType>::CollisionRecordList
}
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * /
template<class PairType, class WallType>
Foam::CollisionRecordList<PairType, WallType>::~CollisionRecordList()
{}
// * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * //
template<class PairType, class WallType>
@ -386,24 +371,6 @@ void Foam::CollisionRecordList<PairType, WallType>::update()
}
// * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * * //
template<class PairType, class WallType>
void Foam::CollisionRecordList<PairType, WallType>::operator=
(
const CollisionRecordList<PairType, WallType>& rhs
)
{
if (this == &rhs)
{
return; // Self-assignment is a no-op
}
pairRecords_ = rhs.pairRecords_;
wallRecords_ = rhs.wallRecords_;
}
// * * * * * * * * * * * * * * Friend Operators * * * * * * * * * * * * * * //
template<class PairType, class WallType>

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -47,7 +48,7 @@ SourceFiles
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class PairType, class WallType>
class CollisionRecordList;
@ -79,7 +80,7 @@ Ostream& operator<<(Ostream&, const CollisionRecordList<PairType, WallType>&);
template<class PairType, class WallType>
class CollisionRecordList
{
// Private data
// Private Data
//- List of active pair collisions
DynamicList<PairCollisionRecord<PairType>> pairRecords_;
@ -90,13 +91,16 @@ class CollisionRecordList
public:
// Generated Methods
//- Default construct
CollisionRecordList() = default;
// Constructors
//- Construct null
CollisionRecordList();
//- Construct from Istream
CollisionRecordList(Istream&);
explicit CollisionRecordList(Istream& is);
//- Construct from component fields (for IO)
CollisionRecordList
@ -110,9 +114,6 @@ public:
const Field<WallType>& wallData
);
//- Destructor
~CollisionRecordList();
// Member Functions
@ -196,11 +197,6 @@ public:
void update();
// Member Operators
void operator=(const CollisionRecordList&);
// Friend Operators
friend bool operator== <PairType, WallType>

View File

@ -25,8 +25,6 @@ License
\*---------------------------------------------------------------------------*/
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class PairType, class WallType>
@ -45,7 +43,4 @@ Foam::CollisionRecordList<PairType, WallType>::wallRecords() const
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
// ************************************************************************* //

View File

@ -188,16 +188,6 @@ Foam::phaseProperties::phaseProperties()
{}
Foam::phaseProperties::phaseProperties(const phaseProperties& pp)
:
phase_(pp.phase_),
stateLabel_(pp.stateLabel_),
names_(pp.names_),
Y_(pp.Y_),
carrierIds_(pp.carrierIds_)
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
void Foam::phaseProperties::reorder

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -48,14 +49,11 @@ SourceFiles
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
class phaseProperties;
Istream& operator>>(Istream&, phaseProperties&);
Ostream& operator<<(Ostream&, const phaseProperties&);
/*---------------------------------------------------------------------------*\
Class phaseProperties Declaration
\*---------------------------------------------------------------------------*/
@ -64,7 +62,7 @@ class phaseProperties
{
public:
// Public data
// Public Data
//- Phase type enumeration
enum phaseType
@ -81,7 +79,7 @@ public:
private:
// Private data
// Private Data
//- Phase type
phaseType phase_;
@ -118,21 +116,14 @@ public:
// Constructors
//- Null constructor
//- Default construct, as 'UNKNOWN' state
phaseProperties();
//- Construct from Istream
phaseProperties(Istream& is);
//- Construct as copy
phaseProperties(const phaseProperties& pp);
explicit phaseProperties(Istream& is);
//- Destructor
~phaseProperties() = default;
// Public Member Functions
// Member Functions
//- Reorder species to be consistent with the corresponding
// phase specie name list

View File

@ -32,11 +32,7 @@ License
Foam::phaseProperties::phaseProperties(Istream& is)
:
phase_(UNKNOWN),
stateLabel_("(unknown)"),
names_(),
Y_(),
carrierIds_()
phaseProperties()
{
is >> *this;
}
@ -59,7 +55,7 @@ Foam::Istream& Foam::operator>>(Istream& is, phaseProperties& pp)
const label nComponents = pp.names_.size();
pp.Y_.resize(nComponents, 0.0);
pp.Y_.resize(nComponents, Zero);
pp.carrierIds_.resize(nComponents, -1);
for (label cmpti = 0; cmpti < nComponents; ++cmpti)

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -50,7 +51,7 @@ SourceFiles
namespace Foam
{
// Forward declarations
// Forward Declarations
class forceSuSp;
inline forceSuSp operator+(const forceSuSp& susp1, const forceSuSp& susp2);
@ -65,13 +66,12 @@ class forceSuSp
:
public Tuple2<vector, scalar>
{
public:
// Constructors
//- Construct null
inline forceSuSp();
//- Default construct
forceSuSp() = default;
//- Construct zero-initialized content
inline forceSuSp(const zero);
@ -83,7 +83,7 @@ public:
inline forceSuSp(const vector& Su, const scalar Sp);
//- Construct from Istream
inline forceSuSp(Istream& is);
inline explicit forceSuSp(Istream& is);
// Member Functions
@ -108,9 +108,6 @@ public:
// Operators
//- Assignment
inline void operator=(const forceSuSp& susp);
//- Addition
inline void operator+=(const forceSuSp& susp);
@ -118,7 +115,7 @@ public:
inline void operator-=(const forceSuSp& susp);
// Friend operators
// Friend Operators
//- Addition
friend inline forceSuSp operator*

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -27,13 +28,9 @@ License
// * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * * * //
inline Foam::forceSuSp::forceSuSp()
{}
inline Foam::forceSuSp::forceSuSp(const zero)
:
Tuple2<vector, scalar>(vector::zero, 0.0)
Tuple2<vector, scalar>(vector::zero, 0)
{}
@ -87,13 +84,6 @@ inline Foam::scalar& Foam::forceSuSp::Sp()
// * * * * * * * * * * * * * * * Operators * * * * * * * * * * * * * * * * * //
inline void Foam::forceSuSp::operator=(const forceSuSp& susp)
{
first() = susp.first();
second() = susp.second();
}
inline void Foam::forceSuSp::operator+=(const forceSuSp& susp)
{
first() += susp.first();

View File

@ -71,29 +71,6 @@ SingleKineticRateDevolatilisation
}
template<class CloudType>
Foam::SingleKineticRateDevolatilisation<CloudType>::
SingleKineticRateDevolatilisation
(
const SingleKineticRateDevolatilisation<CloudType>& dm
)
:
DevolatilisationModel<CloudType>(dm),
volatileData_(dm.volatileData_),
YVolatile0_(dm.YVolatile0_),
volatileToGasMap_(dm.volatileToGasMap_),
residualCoeff_(dm.residualCoeff_)
{}
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
template<class CloudType>
Foam::SingleKineticRateDevolatilisation<CloudType>::
~SingleKineticRateDevolatilisation()
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class CloudType>

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -68,6 +68,7 @@ Description
namespace Foam
{
/*---------------------------------------------------------------------------*\
Class SingleKineticRateDevolatilisation Declaration
\*---------------------------------------------------------------------------*/
@ -77,10 +78,10 @@ class SingleKineticRateDevolatilisation
:
public DevolatilisationModel<CloudType>
{
// Helper class to store specie-local volatile data
//- Helper class to store specie-local volatile data
class volatileData
{
// Private data
// Private Data
//- Specie name
word name_;
@ -91,41 +92,28 @@ class SingleKineticRateDevolatilisation
//- Pre-exponential factor
scalar E_;
public:
// Constructors
//- Null constructor
//- Default construct
volatileData()
:
name_(word::null),
A1_(0.0),
E_(0.0)
name_(),
A1_(0),
E_(0)
{}
//- Construct from Istream
volatileData(Istream& is)
explicit volatileData(Istream& is)
:
name_(is),
A1_(readScalar(is)),
E_(readScalar(is))
{}
//- Construct as copy
volatileData(const volatileData& vd)
:
name_(vd.name_),
A1_(vd.A1_),
E_(vd.E_)
{}
//- Destructor
~volatileData() = default;
// Public Member Functions
// Member Functions
// Access
@ -174,9 +162,9 @@ class SingleKineticRateDevolatilisation
};
// Private data
// Private Data
// Model constants
// Model Constants
//- List of volatile data - (name A1 E)
List<volatileData> volatileData_;
@ -195,7 +183,7 @@ class SingleKineticRateDevolatilisation
public:
//- Runtime type information
//- Declare type-name, virtual type (with debug switch)
TypeName("singleKineticRateDevolatilisation");
@ -208,12 +196,6 @@ public:
CloudType& owner
);
//- Construct copy
SingleKineticRateDevolatilisation
(
const SingleKineticRateDevolatilisation<CloudType>& dm
);
//- Construct and return a clone
virtual autoPtr<DevolatilisationModel<CloudType>> clone() const
{
@ -225,7 +207,7 @@ public:
//- Destructor
virtual ~SingleKineticRateDevolatilisation();
virtual ~SingleKineticRateDevolatilisation() = default;
// Member Functions

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -39,13 +40,14 @@ SourceFiles
#ifndef constAnIsoSolidTransport_H
#define constAnIsoSolidTransport_H
#include "vector.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam
{
// Forward Declarations
template<class Thermo> class constAnIsoSolidTransport;
template<class Thermo>
@ -72,7 +74,7 @@ class constAnIsoSolidTransport
:
public Thermo
{
// Private data
// Private Data
//- Constant anisotropic thermal conductivity.
vector kappa_;
@ -86,6 +88,9 @@ class constAnIsoSolidTransport
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct as named copy
@ -96,7 +101,7 @@ public:
);
//- Construct from dictionary
constAnIsoSolidTransport(const dictionary&);
explicit constAnIsoSolidTransport(const dictionary& dict);
// Selector from dictionary
inline static autoPtr<constAnIsoSolidTransport> New
@ -105,7 +110,7 @@ public:
);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -133,13 +138,12 @@ public:
void write(Ostream& os) const;
// Member operators
// Member Operators
inline void operator=(const constAnIsoSolidTransport&);
inline void operator+=(const constAnIsoSolidTransport&);
// Friend operators
// Friend Operators
friend constAnIsoSolidTransport operator* <Thermo>
(
@ -148,7 +152,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Thermo>
(

View File

@ -83,7 +83,7 @@ inline Foam::scalar Foam::constAnIsoSolidTransport<Thermo>::
mu(const scalar p, const scalar T) const
{
NotImplemented;
return scalar(0);
return 0;
}
@ -96,16 +96,6 @@ alphah(const scalar p, const scalar T) const
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class Thermo>
inline void Foam::constAnIsoSolidTransport<Thermo>::operator=
(
const constAnIsoSolidTransport<Thermo>& ct
)
{
kappa_ = ct.kappa_;
}
template<class Thermo>
inline void Foam::constAnIsoSolidTransport<Thermo>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -47,6 +48,7 @@ SourceFiles
namespace Foam
{
// Forward Declarations
template<class Thermo> class constIsoSolidTransport;
template<class Thermo>
@ -73,7 +75,7 @@ class constIsoSolidTransport
:
public Thermo
{
// Private data
// Private Data
//- Constant isotropic thermal conductivity
scalar kappa_;
@ -87,6 +89,9 @@ class constIsoSolidTransport
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct as named copy
@ -97,7 +102,7 @@ public:
);
//- Construct from dictionary
constIsoSolidTransport(const dictionary& dict);
explicit constIsoSolidTransport(const dictionary& dict);
// Selector from dictionary
inline static autoPtr<constIsoSolidTransport> New
@ -106,7 +111,7 @@ public:
);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -123,7 +128,7 @@ public:
//- Un-isotropic thermal conductivity [W/mK]
inline vector Kappa(const scalar p, const scalar T) const;
//- Dynamic viscosity [kg/ms]
//- Dynamic viscosity [kg/ms]
inline scalar mu(const scalar p, const scalar T) const;
//- Thermal diffusivity of enthalpy [kg/ms]
@ -134,13 +139,12 @@ public:
void write(Ostream& os) const;
// Member operators
// Member Operators
inline void operator=(const constIsoSolidTransport&);
inline void operator+=(const constIsoSolidTransport&);
// Friend operators
// Friend Operators
friend constIsoSolidTransport operator* <Thermo>
(
@ -149,7 +153,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Thermo>
(

View File

@ -83,7 +83,7 @@ inline Foam::scalar Foam::constIsoSolidTransport<thermo>::
mu(const scalar p, const scalar T) const
{
NotImplemented;
return scalar(0);
return 0;
}
@ -96,17 +96,6 @@ alphah(const scalar p, const scalar T) const
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class thermo>
inline void Foam::constIsoSolidTransport<thermo>::operator=
(
const constIsoSolidTransport<thermo>& ct
)
{
thermo::operator=(ct);
kappa_ = ct.kappa_;
}
template<class thermo>
inline void Foam::constIsoSolidTransport<thermo>::operator+=
(
@ -125,7 +114,6 @@ inline void Foam::constIsoSolidTransport<thermo>::operator+=
// * * * * * * * * * * * * * * * Friend Operators * * * * * * * * * * * * * //
template<class thermo>
inline Foam::constIsoSolidTransport<thermo> Foam::operator*
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -44,6 +45,8 @@ SourceFiles
namespace Foam
{
// Forward Declarations
template<class Thermo> class exponentialSolidTransport;
template<class Thermo>
@ -70,7 +73,7 @@ class exponentialSolidTransport
:
public Thermo
{
// Private data
// Private Data
//- Constant thermal coefficient.
scalar kappa0_;
@ -96,6 +99,9 @@ class exponentialSolidTransport
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct as named copy
@ -106,7 +112,7 @@ public:
);
//- Construct from dictionary
exponentialSolidTransport(const dictionary&);
explicit exponentialSolidTransport(const dictionary&);
// Selector from dictionary
inline static autoPtr<exponentialSolidTransport> New
@ -115,7 +121,7 @@ public:
);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -132,7 +138,7 @@ public:
//- Thermal conductivity [W/mK]
inline vector Kappa(const scalar p, const scalar T) const;
//- Dynamic viscosity [kg/ms]
//- Dynamic viscosity [kg/ms]
inline scalar mu(const scalar p, const scalar T) const;
//- Thermal diffusivity of enthalpy [kg/ms]
@ -142,13 +148,12 @@ public:
void write(Ostream& os) const;
// Member operators
// Member Operators
inline void operator=(const exponentialSolidTransport&);
inline void operator+=(const exponentialSolidTransport&);
// Friend operators
// Friend Operators
friend exponentialSolidTransport operator* <Thermo>
(
@ -156,7 +161,8 @@ public:
const exponentialSolidTransport&
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Thermo>
(

View File

@ -95,7 +95,7 @@ inline Foam::scalar Foam::exponentialSolidTransport<Thermo>::
mu(const scalar p, const scalar T) const
{
NotImplemented;
return scalar(0);
return 0;
}
@ -108,19 +108,6 @@ alphah(const scalar p, const scalar T) const
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class Thermo>
inline void Foam::exponentialSolidTransport<Thermo>::operator=
(
const exponentialSolidTransport<Thermo>& ct
)
{
kappa0_ = ct.kappa0_;
n0_ = ct.n0_;
Tref_ = ct.Tref_;
}
template<class Thermo>
inline void Foam::exponentialSolidTransport<Thermo>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2013-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -73,7 +74,7 @@ See also
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class Thermo, int PolySize> class polynomialSolidTransport;
@ -108,7 +109,7 @@ class polynomialSolidTransport
:
public Thermo
{
// Private data
// Private Data
//- Thermal conductivity polynomial coefficients
// Note: input in [W/m/K]
@ -133,6 +134,9 @@ class polynomialSolidTransport
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct as named copy
@ -143,7 +147,7 @@ public:
);
//- Construct from dictionary
polynomialSolidTransport(const dictionary& dict);
explicit polynomialSolidTransport(const dictionary& dict);
//- Construct and return a clone
inline autoPtr<polynomialSolidTransport> clone() const;
@ -155,7 +159,7 @@ public:
);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -183,14 +187,13 @@ public:
void write(Ostream& os) const;
// Member operators
// Member Operators
inline void operator=(const polynomialSolidTransport&);
inline void operator+=(const polynomialSolidTransport&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
friend polynomialSolidTransport operator+ <Thermo, PolySize>
(
@ -205,7 +208,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Thermo, PolySize>
(

View File

@ -81,7 +81,7 @@ inline Foam::scalar Foam::polynomialSolidTransport<Thermo, PolySize>::mu
) const
{
NotImplemented;
return scalar(0);
return 0;
}
@ -120,18 +120,6 @@ inline Foam::scalar Foam::polynomialSolidTransport<Thermo, PolySize>::alphah
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class Thermo, int PolySize>
inline void Foam::polynomialSolidTransport<Thermo, PolySize>::operator=
(
const polynomialSolidTransport<Thermo, PolySize>& pt
)
{
Thermo::operator=(pt);
kappaCoeffs_ = pt.kappaCoeffs_;
}
template<class Thermo, int PolySize>
inline void Foam::polynomialSolidTransport<Thermo, PolySize>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -76,7 +77,7 @@ See also
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class Specie, int PolySize>
class icoPolynomial;
@ -119,7 +120,7 @@ class icoPolynomial
:
public Specie
{
// Private data
// Private Data
//- Density polynomial coefficients
Polynomial<PolySize> rhoCoeffs_;
@ -136,6 +137,8 @@ class icoPolynomial
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct from components
@ -146,7 +149,7 @@ public:
);
//- Construct from dictionary
icoPolynomial(const dictionary& dict);
explicit icoPolynomial(const dictionary& dict);
//- Construct as named copy
inline icoPolynomial(const word& name, const icoPolynomial&);
@ -158,7 +161,7 @@ public:
inline static autoPtr<icoPolynomial> New(const dictionary& dict);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -209,14 +212,13 @@ public:
void write(Ostream& os) const;
// Member operators
// Member Operators
inline void operator=(const icoPolynomial&);
inline void operator+=(const icoPolynomial&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
friend icoPolynomial operator+ <Specie, PolySize>
(
@ -237,7 +239,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Specie, PolySize>
(

View File

@ -174,18 +174,6 @@ inline Foam::scalar Foam::icoPolynomial<Specie, PolySize>::CpMCv
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class Specie, int PolySize>
inline void Foam::icoPolynomial<Specie, PolySize>::operator=
(
const icoPolynomial<Specie, PolySize>& ip
)
{
Specie::operator=(ip);
rhoCoeffs_ = ip.rhoCoeffs_;
}
template<class Specie, int PolySize>
inline void Foam::icoPolynomial<Specie, PolySize>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2012-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -50,7 +51,7 @@ SourceFiles
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class Specie> class incompressiblePerfectGas;
@ -92,7 +93,7 @@ class incompressiblePerfectGas
:
public Specie
{
// Private data
// Private Data
//- Reference pressure
scalar pRef_;
@ -100,13 +101,16 @@ class incompressiblePerfectGas
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct from components
inline incompressiblePerfectGas(const Specie& sp, const scalar pRef);
//- Construct from dictionary
incompressiblePerfectGas(const dictionary& dict);
explicit incompressiblePerfectGas(const dictionary& dict);
//- Construct as named copy
inline incompressiblePerfectGas
@ -125,7 +129,7 @@ public:
);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -178,14 +182,13 @@ public:
void write(Ostream& os) const;
// Member operators
// Member Operators
inline void operator=(const incompressiblePerfectGas&);
inline void operator+=(const incompressiblePerfectGas&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
friend incompressiblePerfectGas operator+ <Specie>
(
@ -206,7 +209,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Specie>
(

View File

@ -27,13 +27,13 @@ License
#include "incompressiblePerfectGas.H"
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class Specie>
inline Foam::incompressiblePerfectGas<Specie>::incompressiblePerfectGas
(
const Specie& sp, const scalar pRef
const Specie& sp,
const scalar pRef
)
:
Specie(sp),
@ -175,17 +175,6 @@ inline Foam::scalar Foam::incompressiblePerfectGas<Specie>::CpMCv
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class Specie>
inline void Foam::incompressiblePerfectGas<Specie>::operator=
(
const incompressiblePerfectGas<Specie>& ipg
)
{
Specie::operator=(ipg);
pRef_ = ipg.pRef_;
}
template<class Specie>
inline void Foam::incompressiblePerfectGas<Specie>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -50,8 +51,7 @@ using namespace Foam::constant::thermodynamic;
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
class specie;
inline specie operator+(const specie&, const specie&);
@ -67,7 +67,7 @@ Ostream& operator<<(Ostream&, const specie&);
class specie
{
// Private data
// Private Data
//- Name of specie
word name_;
@ -81,10 +81,16 @@ class specie
public:
//- Runtime type information
//- Declare type-name (with debug switch)
ClassName("specie");
// Generated Methods
//- Copy construct
specie(const specie&) = default;
// Constructors
//- Construct from components without name
@ -102,7 +108,7 @@ public:
inline specie(const word& name, const specie&);
//- Construct from dictionary
specie(const dictionary& dict);
explicit specie(const dictionary& dict);
// Member Functions
@ -122,27 +128,29 @@ public:
inline scalar R() const;
// I-O
// IO
//- Write to Ostream
void write(Ostream& os) const;
// Member operators
// Member Operators
//- Copy assignment, preserve original name
inline void operator=(const specie&);
inline void operator+=(const specie&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
inline friend specie operator+(const specie&, const specie&);
inline friend specie operator*(const scalar, const specie&);
inline friend specie operator==(const specie&, const specie&);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<<(Ostream&, const specie&);
};

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -27,14 +28,9 @@ License
#include "specie.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam
{
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
inline specie::specie
inline Foam::specie::specie
(
const word& name,
const scalar Y,
@ -47,7 +43,7 @@ inline specie::specie
{}
inline specie::specie
inline Foam::specie::specie
(
const scalar Y,
const scalar molWeight
@ -60,7 +56,7 @@ inline specie::specie
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
inline specie::specie(const word& name, const specie& st)
inline Foam::specie::specie(const word& name, const specie& st)
:
name_(name),
Y_(st.Y_),
@ -70,25 +66,25 @@ inline specie::specie(const word& name, const specie& st)
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
inline const word& specie::name() const
inline const Foam::word& Foam::specie::name() const
{
return name_;
}
inline scalar specie::W() const
inline Foam::scalar Foam::specie::W() const
{
return molWeight_;
}
inline scalar specie::Y() const
inline Foam::scalar Foam::specie::Y() const
{
return Y_;
}
inline scalar specie::R() const
inline Foam::scalar Foam::specie::R() const
{
return RR/molWeight_;
}
@ -96,15 +92,15 @@ inline scalar specie::R() const
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
inline void specie::operator=(const specie& st)
inline void Foam::specie::operator=(const specie& st)
{
//name_ = st.name_;
// Preserve original name
Y_ = st.Y_;
molWeight_ = st.molWeight_;
}
inline void specie::operator+=(const specie& st)
inline void Foam::specie::operator+=(const specie& st)
{
const scalar sumY = Y_ + st.Y_;
if (mag(sumY) > SMALL)
@ -116,7 +112,7 @@ inline void specie::operator+=(const specie& st)
}
inline void specie::operator*=(const scalar s)
inline void Foam::specie::operator*=(const scalar s)
{
Y_ *= s;
}
@ -124,7 +120,7 @@ inline void specie::operator*=(const scalar s)
// * * * * * * * * * * * * * * * Friend Operators * * * * * * * * * * * * * //
inline specie operator+(const specie& st1, const specie& st2)
inline Foam::specie Foam::operator+(const specie& st1, const specie& st2)
{
const scalar sumY = max(st1.Y_ + st2.Y_, SMALL);
@ -143,7 +139,7 @@ inline specie operator+(const specie& st1, const specie& st2)
}
inline specie operator*(const scalar s, const specie& st)
inline Foam::specie Foam::operator*(const scalar s, const specie& st)
{
return specie
(
@ -153,7 +149,7 @@ inline specie operator*(const scalar s, const specie& st)
}
inline specie operator==(const specie& st1, const specie& st2)
inline Foam::specie Foam::operator==(const specie& st1, const specie& st2)
{
scalar diffY = st2.Y_ - st1.Y_;
if (mag(diffY) < SMALL)
@ -180,8 +176,4 @@ inline specie operator==(const specie& st1, const specie& st2)
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
} // End namespace Foam
// ************************************************************************* //

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -43,7 +44,7 @@ SourceFiles
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
class specieElement;
Ostream& operator<<(Ostream&, const specieElement&);
@ -54,7 +55,7 @@ Ostream& operator<<(Ostream&, const specieElement&);
class specieElement
{
// Private data
// Private Data
//- Name of the element
word name_;
@ -67,14 +68,14 @@ public:
// Constructors
//- Construct null
//- Default construct
inline specieElement();
//- Construct from components
inline specieElement(const word& name, const label nAtoms);
//- Construct from Istream
inline specieElement(Istream&);
inline explicit specieElement(Istream& is);
// Member Functions

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -30,6 +31,9 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
inline Foam::specieElement::specieElement()
:
name_(),
nAtoms_(0)
{}

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -86,7 +87,7 @@ See also
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class EquationOfState, int PolySize>
class hPolynomialThermo;
@ -129,7 +130,7 @@ class hPolynomialThermo
:
public EquationOfState
{
// Private data
// Private Data
//- Heat of formation
scalar Hf_;
@ -170,6 +171,9 @@ class hPolynomialThermo
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct from dictionary
@ -222,20 +226,19 @@ public:
// I-O
// IO
//- Write to Ostream
void write(Ostream& os) const;
// Member operators
// Member Operators
inline void operator=(const hPolynomialThermo&);
inline void operator+=(const hPolynomialThermo&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
friend hPolynomialThermo operator+ <EquationOfState, PolySize>
(
@ -256,7 +259,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <EquationOfState, PolySize>
(

View File

@ -159,22 +159,6 @@ inline Foam::scalar Foam::hPolynomialThermo<EquationOfState, PolySize>::dCpdT
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class EquationOfState, int PolySize>
inline void Foam::hPolynomialThermo<EquationOfState, PolySize>::operator=
(
const hPolynomialThermo<EquationOfState, PolySize>& pt
)
{
EquationOfState::operator=(pt);
Hf_ = pt.Hf_;
Sf_ = pt.Sf_;
CpCoeffs_ = pt.CpCoeffs_;
hCoeffs_ = pt.hCoeffs_;
sCoeffs_ = pt.sCoeffs_;
}
template<class EquationOfState, int PolySize>
inline void Foam::hPolynomialThermo<EquationOfState, PolySize>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -59,7 +60,7 @@ SourceFiles
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class Thermo> class WLFTransport;
@ -94,7 +95,7 @@ class WLFTransport
:
public Thermo
{
// Private data
// Private Data
//- Dynamic viscosity at the reference temperature [Pa.s]
scalar mu0_;
@ -108,7 +109,7 @@ class WLFTransport
//- WLF coefficient 2 [T]
scalar C2_;
//- Reciprocal Prandtl Number []
//- Reciprocal Prandtl Number [-]
scalar rPr_;
@ -120,13 +121,16 @@ class WLFTransport
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct as named copy
inline WLFTransport(const word&, const WLFTransport&);
//- Construct from dictionary
WLFTransport(const dictionary& dict);
explicit WLFTransport(const dictionary& dict);
//- Construct and return a clone
inline autoPtr<WLFTransport> clone() const;
@ -135,7 +139,7 @@ public:
inline static autoPtr<WLFTransport> New(const dictionary& dict);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -159,16 +163,14 @@ public:
void write(Ostream& os) const;
// Member operators
inline void operator=(const WLFTransport&);
// Member Operators
inline void operator+=(const WLFTransport&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
friend WLFTransport operator+ <Thermo>
(
@ -183,7 +185,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Thermo>
(

View File

@ -107,22 +107,6 @@ inline Foam::scalar Foam::WLFTransport<Thermo>::alphah
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class Thermo>
inline void Foam::WLFTransport<Thermo>::operator=
(
const WLFTransport<Thermo>& wlft
)
{
Thermo::operator=(wlft);
mu0_ = wlft.mu0_;
Tr_ = wlft.Tr_;
C1_ = wlft.C1_;
C2_ = wlft.C2_;
rPr_ = wlft.rPr_;
}
template<class Thermo>
inline void Foam::WLFTransport<Thermo>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -48,7 +49,7 @@ SourceFiles
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class Thermo> class constTransport;
@ -83,12 +84,12 @@ class constTransport
:
public Thermo
{
// Private data
// Private Data
//- Constant dynamic viscosity [Pa.s]
scalar mu_;
//- Reciprocal Prandtl Number []
//- Reciprocal Prandtl Number [-]
scalar rPr_;
@ -105,13 +106,16 @@ class constTransport
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct as named copy
inline constTransport(const word&, const constTransport&);
//- Construct from dictionary
constTransport(const dictionary& dict);
explicit constTransport(const dictionary& dict);
//- Construct and return a clone
inline autoPtr<constTransport> clone() const;
@ -120,7 +124,7 @@ public:
inline static autoPtr<constTransport> New(const dictionary& dict);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -144,16 +148,14 @@ public:
void write(Ostream& os) const;
// Member operators
inline void operator=(const constTransport&);
// Member Operators
inline void operator+=(const constTransport&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
friend constTransport operator+ <Thermo>
(
@ -168,7 +170,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Thermo>
(

View File

@ -110,19 +110,6 @@ inline Foam::scalar Foam::constTransport<Thermo>::alphah
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class Thermo>
inline void Foam::constTransport<Thermo>::operator=
(
const constTransport<Thermo>& ct
)
{
Thermo::operator=(ct);
mu_ = ct.mu_;
rPr_ = ct.rPr_;
}
template<class Thermo>
inline void Foam::constTransport<Thermo>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -93,7 +94,7 @@ See also
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class Thermo, int PolySize> class logPolynomialTransport;
@ -128,7 +129,7 @@ class logPolynomialTransport
:
public Thermo
{
// Private data
// Private Data
//- Dynamic viscosity polynomial coefficients
// Note: input in [Pa.s], but internally uses [Pa.s/kmol]
@ -158,6 +159,9 @@ class logPolynomialTransport
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct as named copy
@ -168,7 +172,7 @@ public:
);
//- Construct from dictionary
logPolynomialTransport(const dictionary& dict);
explicit logPolynomialTransport(const dictionary& dict);
//- Construct and return a clone
inline autoPtr<logPolynomialTransport> clone() const;
@ -180,7 +184,7 @@ public:
);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -204,16 +208,14 @@ public:
void write(Ostream& os) const;
// Member operators
inline void operator=(const logPolynomialTransport&);
// Member Operators
inline void operator+=(const logPolynomialTransport&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
friend logPolynomialTransport operator+ <Thermo, PolySize>
(
@ -228,7 +230,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Thermo, PolySize>
(

View File

@ -108,19 +108,6 @@ inline Foam::scalar Foam::logPolynomialTransport<Thermo, PolySize>::alphah
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class Thermo, int PolySize>
inline void Foam::logPolynomialTransport<Thermo, PolySize>::operator=
(
const logPolynomialTransport<Thermo, PolySize>& pt
)
{
Thermo::operator=(pt);
muCoeffs_ = pt.muCoeffs_;
kappaCoeffs_ = pt.kappaCoeffs_;
}
template<class Thermo, int PolySize>
inline void Foam::logPolynomialTransport<Thermo, PolySize>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -84,7 +85,7 @@ See also
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class Thermo, int PolySize> class polynomialTransport;
@ -119,7 +120,7 @@ class polynomialTransport
:
public Thermo
{
// Private data
// Private Data
//- Dynamic viscosity polynomial coefficients
Polynomial<PolySize> muCoeffs_;
@ -147,13 +148,16 @@ class polynomialTransport
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct as named copy
inline polynomialTransport(const word&, const polynomialTransport&);
//- Construct from dictionary
polynomialTransport(const dictionary& dict);
explicit polynomialTransport(const dictionary& dict);
//- Construct and return a clone
inline autoPtr<polynomialTransport> clone() const;
@ -162,7 +166,7 @@ public:
inline static autoPtr<polynomialTransport> New(const dictionary& dict);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -186,16 +190,14 @@ public:
void write(Ostream& os) const;
// Member operators
inline void operator=(const polynomialTransport&);
// Member Operators
inline void operator+=(const polynomialTransport&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
friend polynomialTransport operator+ <Thermo, PolySize>
(
@ -210,7 +212,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Thermo, PolySize>
(

View File

@ -108,19 +108,6 @@ inline Foam::scalar Foam::polynomialTransport<Thermo, PolySize>::alphah
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
template<class Thermo, int PolySize>
inline void Foam::polynomialTransport<Thermo, PolySize>::operator=
(
const polynomialTransport<Thermo, PolySize>& pt
)
{
Thermo::operator=(pt);
muCoeffs_ = pt.muCoeffs_;
kappaCoeffs_ = pt.kappaCoeffs_;
}
template<class Thermo, int PolySize>
inline void Foam::polynomialTransport<Thermo, PolySize>::operator+=
(

View File

@ -6,6 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -54,7 +55,7 @@ SourceFiles
namespace Foam
{
// Forward declaration of friend functions and operators
// Forward Declarations
template<class Thermo> class sutherlandTransport;
@ -89,7 +90,7 @@ class sutherlandTransport
:
public Thermo
{
// Private data
// Private Data
// Sutherland's coefficients
scalar As_, Ts_;
@ -111,6 +112,9 @@ class sutherlandTransport
public:
// Generated Methods: copy construct, copy assignment
// Constructors
//- Construct from components
@ -133,7 +137,7 @@ public:
inline sutherlandTransport(const word&, const sutherlandTransport&);
//- Construct from dictionary
sutherlandTransport(const dictionary& dict);
explicit sutherlandTransport(const dictionary& dict);
//- Construct from base thermo and dictionary
sutherlandTransport(const Thermo& t,const dictionary& dict);
@ -145,7 +149,7 @@ public:
inline static autoPtr<sutherlandTransport> New(const dictionary& dict);
// Member functions
// Member Functions
//- Return the instantiated type name
static word typeName()
@ -169,16 +173,14 @@ public:
void write(Ostream& os) const;
// Member operators
inline void operator=(const sutherlandTransport&);
// Member Operators
inline void operator+=(const sutherlandTransport&);
inline void operator*=(const scalar);
// Friend operators
// Friend Operators
friend sutherlandTransport operator+ <Thermo>
(
@ -193,7 +195,7 @@ public:
);
// Ostream Operator
// IOstream Operators
friend Ostream& operator<< <Thermo>
(

Some files were not shown because too many files have changed in this diff Show More