201 return c.conjugate();
212 return (c.re*c.re + c.im*c.im);
218 return std::hypot(c.re, c.im);
230 const scalar
s(
mag(c));
231 return s < ROOTVSMALL ?
Zero : c/
s;
275template<
class Cmpt>
class Tensor;
339 c1.re*c2.re - c1.im*c2.im,
340 c1.im*c2.re + c1.re*c2.im
359 const scalar sqrC2 =
magSqr(c2);
363 (c1.re*c2.re + c1.im*c2.im)/sqrC2,
364 (c1.im*c2.re - c1.re*c2.im)/sqrC2
391 #define transFunc(func) \
392 inline complex func(const complex& c) \
394 return std:: func (static_cast<std::complex<scalar>>(c)); \
419 static_cast<std::complex<scalar>
>(
x),
420 static_cast<std::complex<scalar>
>(
y)
426#define powFuncs(type2) \
427 inline complex pow(const complex& x, const type2 y) \
429 return std::pow(static_cast<std::complex<scalar>>(x), y); \
432 inline complex pow(const type2 x, const complex& y) \
436 static_cast<std::complex<scalar>>(x), \
437 static_cast<std::complex<scalar>>(y) \
443#if defined(__APPLE__) && WM_LABEL_SIZE == 64
A templated (3 x 3) tensor of objects of <T> derived from MatrixSpace.
A complex number, similar to the C++ complex type.
complex conjugate() const
Complex conjugate.
complex & operator=(const complex &)=default
Copy assignment.
void operator+=(const complex &c)
constexpr scalar imag() const
Imaginary part of complex number - STL naming.
constexpr complex() noexcept
Default construct, as zero-initialized.
scalar Im() const
Imaginary part of complex number.
void operator-=(const complex &c)
scalar Re() const
Real part of complex number.
void operator*=(const complex &c)
void operator/=(const complex &c)
constexpr scalar real() const
Real part of complex number - STL naming.
friend bool operator!=(const refineCell &rc1, const refineCell &rc2)
friend bool operator==(const refineCell &rc1, const refineCell &rc2)
A class representing the concept of 0 (zero) that can be used to avoid manipulating objects known to ...
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
tmp< faMatrix< Type > > operator-(const faMatrix< Type > &)
Unary negation.
bitSet operator~(const bitSet &bitset)
Bitset complement, returns a copy of the bitset with all its bits flipped.
dimensionedScalar pow6(const dimensionedScalar &ds)
dimensionedScalar pow5(const dimensionedScalar &ds)
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
dimensionedScalar asin(const dimensionedScalar &ds)
dimensionedScalar exp(const dimensionedScalar &ds)
dimensionedScalar tan(const dimensionedScalar &ds)
dimensionSet transform(const dimensionSet &ds)
Return the argument; transformations do not change the dimensions.
dimensionedScalar sign(const dimensionedScalar &ds)
dimensionedSymmTensor sqr(const dimensionedVector &dv)
tmp< faMatrix< Type > > operator+(const faMatrix< Type > &, const faMatrix< Type > &)
dimensionedScalar pow3(const dimensionedScalar &ds)
dimensionedScalar cosh(const dimensionedScalar &ds)
dimensioned< Type > sum(const DimensionedField< Type, GeoMesh > &df)
dimensionedScalar sin(const dimensionedScalar &ds)
dimensionedScalar tanh(const dimensionedScalar &ds)
dimensionedScalar sinh(const dimensionedScalar &ds)
dimensionedScalar log10(const dimensionedScalar &ds)
complex limit(const complex &, const complex &)
tmp< faMatrix< Type > > operator*(const areaScalarField::Internal &, const faMatrix< Type > &)
dimensionedScalar log(const dimensionedScalar &ds)
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
dimensionedScalar operator/(const scalar s1, const dimensionedScalar &ds2)
bool equal(const T &s1, const T &s2)
Compare two values for equality.
dimensionedScalar acosh(const dimensionedScalar &ds)
tmp< faMatrix< Type > > operator==(const faMatrix< Type > &, const faMatrix< Type > &)
dimensionedScalar sqrt(const dimensionedScalar &ds)
scalar csign(const complex &c)
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
label min(const labelHashSet &set, label minValue=labelMax)
Find the min value in labelHashSet, optionally limited by second argument.
dimensionedScalar pow4(const dimensionedScalar &ds)
dimensionedScalar atanh(const dimensionedScalar &ds)
static constexpr const zero Zero
Global zero (0)
dimensionedScalar atan(const dimensionedScalar &ds)
dimensioned< typename typeOfMag< Type >::type > magSqr(const dimensioned< Type > &dt)
dimensionedScalar cos(const dimensionedScalar &ds)
dimensionedScalar acos(const dimensionedScalar &ds)
dimensionedScalar pow025(const dimensionedScalar &ds)
dimensionedScalar asinh(const dimensionedScalar &ds)