Skip to content

Commit

Permalink
Rename struct properties
Browse files Browse the repository at this point in the history
  • Loading branch information
chillin-capybara committed Oct 26, 2021
1 parent c663dae commit 1f46005
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions include/cppmie/cppmie.h
Original file line number Diff line number Diff line change
Expand Up @@ -280,17 +280,17 @@ template<typename TIntercept> requires helpers::FloatingType<TIntercept>
struct MieResult
{
/** Extinction efficiency denoted as Q_ext in the Mie theory. */
TIntercept qext{};
TIntercept Qext{};

/** Scattering efficiency denoted as Q_sca in the Mie theory. */
TIntercept qsca{};
TIntercept Qsca{};

/** Backscattering efficiency denoted as Q_back in the Mie theory. */
TIntercept qback{};
TIntercept Qback{};

MieResult() = default;
MieResult(TIntercept qext_, TIntercept qsca_, TIntercept qback_)
:qext(qext_), qsca(qsca_), qback(qback_)
:Qext(qext_), Qsca(qsca_), Qback(qback_)
{ }
};

Expand All @@ -310,7 +310,7 @@ template<typename T> requires helpers::FloatingType<T>
MieResult<T> mie(const T& x, const T& m, size_t n_star = CPPMIE_NSTAR_DEFAULT)
{
MieResult<T> result;
helpers::mie_core_microopt(x, m, result.qext, result.qsca, result.qback, n_star);
helpers::mie_core_microopt(x, m, result.Qext, result.Qsca, result.Qback, n_star);
return result;
}

Expand All @@ -330,10 +330,10 @@ MieResult<T> mie(const T& x, const std::complex<T>& m, size_t n_star = CPPMIE_NS
{
MieResult<T> result;
if (m.imag() == T(0)) { // The refractive index is real -> ignore complex property
helpers::mie_core_microopt(x, m.real(), result.qext, result.qsca, result.qback, n_star);
helpers::mie_core_microopt(x, m.real(), result.Qext, result.Qsca, result.Qback, n_star);
}
else {
helpers::mie_core_microopt(x, m.real(), result.qext, result.qsca, result.qback, n_star);
helpers::mie_core_microopt(x, m.real(), result.Qext, result.Qsca, result.Qback, n_star);
}
return result;
}
Expand Down

0 comments on commit 1f46005

Please sign in to comment.