33 template<
class ParcelType>
36 sizeof(DSMCParcel<ParcelType>) -
sizeof(ParcelType)
42 template<
class ParcelType>
60 is.
read(
reinterpret_cast<char*
>(&
U_), sizeofFields_);
67 "DSMCParcel<ParcelType>::DSMCParcel"
68 "(const Cloud<ParcelType>&, Istream&, bool)"
73 template<
class ParcelType>
84 c.checkFieldIOobject(
c,
U);
87 c.checkFieldIOobject(
c, Ei);
94 c.checkFieldIOobject(
c, typeId);
103 p.typeId_ = typeId[i];
109 template<
class ParcelType>
115 ParcelType::writeFields(
c);
130 typeId[i] =
p.typeId();
136 typeId.
write(np > 0);
142 template<
class ParcelType>
151 os << static_cast<const ParcelType& >(
p)
158 os << static_cast<const ParcelType& >(
p);
161 reinterpret_cast<const char*
>(&
p.U_),
162 DSMCParcel<ParcelType>::sizeofFields_
169 "Ostream& operator<<(Ostream&, const DSMCParcel<ParcelType>&)"
Useful combination of include files which define Sin, Sout and Serr and the use of IO streams general...
#define forAllIter(Container, container, iter)
Iterate across all elements in the container object of type.
#define forAllConstIter(Container, container, iter)
Iterate across all elements in the container object of type.
label typeId_
Parcel type id.
static void writeFields(const lagrangian::Cloud< DSMCParcel< ParcelType >> &c)
static void readFields(lagrangian::Cloud< DSMCParcel< ParcelType >> &c)
vector U_
Velocity of Parcel [m/s].
DSMCParcel(const polyMesh &mesh, const vector &position, const label celli, label &nLocateBoundaryHits, const vector &U, const scalar Ei, const label typeId)
Construct from a position and a cell, searching for the rest of the.
scalar Ei_
Internal energy of the Parcel, covering all non-translational.
A primitive field of type <Type> with automated input and output.
streamFormat format() const
Return current stream format.
virtual bool check(const char *operation) const
Check IOstream status for given operation.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
virtual Istream & read(token &)=0
Return next token from stream.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
virtual bool write(const bool write=true) const
Write using setting from DB.
bool valid(const PtrList< ModelType > &l)
const dimensionedScalar c
Speed of light in a vacuum.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
void readFields(const typename GeoFieldType::Mesh &mesh, const IOobjectList &objects, const HashSet< word > &selectedFields, LIFOStack< regIOobject * > &storedObjects)
Read the selected GeometricFields of the specified type.
bool readScalar(const char *buf, doubleScalar &s)
Read whole of buf as a scalar. Return true if successful.
label readLabel(Istream &is)