move function of T for rotational relaxation calculation to class Particle

This commit is contained in:
Yeongdo Park 2018-11-02 02:56:33 -04:00
parent 67b9ab8227
commit 03cbca684f
4 changed files with 19 additions and 17 deletions

View file

@ -54,15 +54,8 @@ inline Foam::scalar Foam::Ion::Zrot(const scalar T)
const
{
scalar wellDepth_ = 0.0;
scalar a3 = sqrt(pow3(pi));
scalar a1 = a3/2.0;
scalar a2 = sqr(pi) / 4.0 + 2.0;
scalar t1 = sqrt(wellDepth_/T);
scalar t2 = wellDepth_/T;
scalar t3 = t1 * t2;
return 1.0 + a1 * t1 + a2 * t2 + a3 * t3;
return Particle::Zrot() * zeta(298.0, wellDepth_) / zeta(T, wellDepth_);
}

View file

@ -81,15 +81,7 @@ inline Foam::scalar Foam::Neutral::C6()
inline Foam::scalar Foam::Neutral::Zrot(const scalar T)
const
{
scalar a3 = sqrt(pow3(pi));
scalar a1 = a3/2.0;
scalar a2 = sqr(pi) / 4.0 + 2.0;
scalar t1 = sqrt(wellDepth_/T);
scalar t2 = wellDepth_/T;
scalar t3 = t1 * t2;
return 1.0 + a1 * t1 + a2 * t2 + a3 * t3;
return Particle::Zrot() * zeta(298.0, wellDepth_) / zeta(T, wellDepth_);
}

View file

@ -168,6 +168,8 @@ public:
inline scalar Zrot() const;
inline scalar zeta(const scalar T, const scalar wellDepth) const;
// Check
// Edit

View file

@ -78,6 +78,21 @@ inline Foam::scalar Foam::Particle::Zrot()
}
inline Foam::scalar Foam::Particle::zeta(const scalar T, const scalar wellDepth)
const
{
const scalar a3 = sqrt(pow3(pi));
const scalar a1 = a3/2.0;
const scalar a2 = sqr(pi) / 4.0 + 2.0;
const scalar t1 = sqrt(wellDepth/T);
const scalar t2 = wellDepth/T;
const scalar t3 = t1 * t2;
return 1.0 + a1 * t1 + a2 * t2 + a3 * t3;
}
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //