diff --git a/dumux/material/fluidsystems/1padapter.hh b/dumux/material/fluidsystems/1padapter.hh index d023684d7e4d8447be3c17633039c60478d285a0..a7e4f40d27e04cab47948ab03107dc57f3f1d56c 100644 --- a/dumux/material/fluidsystems/1padapter.hh +++ b/dumux/material/fluidsystems/1padapter.hh @@ -60,7 +60,9 @@ class OnePAdapter DUNE_THROW(Dune::InvalidStateException, "Only phase " << phase << " is available!"); } - // the main component has to be index 0 so we swap the main component with the first component + // the main component is currently excepted to have the same index as it's phase + // (see Fluidsystems::Base::getMainComponent for more information) + // so we swap the main component with the first component // this mapping works in both ways since we are only swapping components static constexpr int compIdx(int compIdx) { diff --git a/dumux/material/fluidsystems/base.hh b/dumux/material/fluidsystems/base.hh index fbc36961cf7272613c8d57873f2c0994e87e81c3..0768dfc6a7be0bee62a366a906cdc446c819af1e 100644 --- a/dumux/material/fluidsystems/base.hh +++ b/dumux/material/fluidsystems/base.hh @@ -60,8 +60,11 @@ public: * \brief Get the main component of a given phase if possible * * \param phaseIdx The index of the fluid phase to consider - * \note This method has to can throw at compile time if the fluid system doesn't assume a + * \note This method has to can assert at compile time if the fluid system doesn't assume a * main phase. Then using e.g. Fick's law will fail compiling. + * \todo Unfortunately we currently still have the assumption in some volume variables (e.g. 1pnc, 2pnc) + * that the main component index of a phase is equal to the phase index of that phase. This means + * changing this only works if the volume variables are written accordingly. */ static constexpr int getMainComponent(int phaseIdx) { return phaseIdx; }