From f7852ad84c078cbbc39cfc1e23ff72087a57efb5 Mon Sep 17 00:00:00 2001 From: bangshiuh Date: Fri, 18 May 2018 16:01:19 -0400 Subject: [PATCH] [Transport] Add use Blancs law to calculate mobilities --- include/cantera/transport/IonGasTransport.h | 10 ++++++++-- src/transport/IonGasTransport.cpp | 20 ++++++++++++++++++++ 2 files changed, 28 insertions(+), 2 deletions(-) diff --git a/include/cantera/transport/IonGasTransport.h b/include/cantera/transport/IonGasTransport.h index 779d97f64..54513758a 100644 --- a/include/cantera/transport/IonGasTransport.h +++ b/include/cantera/transport/IonGasTransport.h @@ -55,6 +55,14 @@ public: //! Only Neutral species contribute to therrmal conductivity. virtual double thermalConductivity(); + //! The mobilities for ions in gas. + //! The ion mobilities are calculated by Blanc's law. + virtual void getMobilities(double* const mobi); + + //! The mixture transport for ionized gas. + //! The binary transport between two charged species is neglected. + virtual void getMixDiffCoeffs(double* const d); + protected: //! setup parameters for n64 model void setupN64(); @@ -72,8 +80,6 @@ protected: */ double omega11_n64(const double tstar, const double gamma); - virtual void getMixDiffCoeffs(doublereal* const d); - //! electrical properties vector_int m_speciesCharge; diff --git a/src/transport/IonGasTransport.cpp b/src/transport/IonGasTransport.cpp index 5b2db60b8..e35620cb2 100644 --- a/src/transport/IonGasTransport.cpp +++ b/src/transport/IonGasTransport.cpp @@ -332,5 +332,25 @@ void IonGasTransport::getMixDiffCoeffs(double* const d) } } +void IonGasTransport::getMobilities(double* const mobi) +{ + double p = m_thermo->pressure(); + for (size_t k = 0; k < m_nsp; k++) { + if (k == m_kElectron) { + mobi[k] = 0.4; + } else { + mobi[k] = 0.0; + } + } + for (size_t k : m_kIon) { + double sum = 0.0; + for (size_t j : m_kNeutral) { + double bmobi = m_bdiff(k,j) * ElectronCharge / m_kbt; + sum += m_molefracs[j] / bmobi; + } + mobi[k] = 1.0 / sum / p; + } +} + }