feat(Comoposition-Tracking): updated GridFire to use new, molar-abundance based, version of libcomposition (v2.0.6)
This entailed a major rewrite of the composition handling from each engine and engine view along with the solver and primer. The intent here is to let Compositions be constructed from the same extensive property which the solver tracks internally. This addressed C0 discontinuity issues in the tracked molar abundances of species which were introduced by repeadidly swaping from molar abundance space to mass fraction space and back. This also allowed for a simplification of the primeNetwork method. Specifically the mass borrowing system was dramatically simplified as molar abundances are extensive.
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
#include "gridfire/network.h"
|
||||
#include "gridfire/exceptions/exceptions.h"
|
||||
|
||||
#include "fourdst/composition/atomicSpecies.h"
|
||||
#include "fourdst/atomic/atomicSpecies.h"
|
||||
#include "fourdst/config/config.h"
|
||||
|
||||
|
||||
@@ -176,7 +176,7 @@ namespace gridfire::solver {
|
||||
const DynamicEngine& engine; ///< Reference to the engine.
|
||||
const std::vector<fourdst::atomic::Species>& networkSpecies; ///< Species layout.
|
||||
const size_t currentConvergenceFailures; ///< Total number of convergence failures
|
||||
const size_t currentNonlinearIterations; ///< Total number of non linear iterations
|
||||
const size_t currentNonlinearIterations; ///< Total number of non-linear iterations
|
||||
|
||||
/**
|
||||
* @brief Construct a context snapshot.
|
||||
@@ -216,12 +216,12 @@ namespace gridfire::solver {
|
||||
* to CVODE, then the driver loop inspects and rethrows.
|
||||
*/
|
||||
struct CVODEUserData {
|
||||
CVODESolverStrategy* solver_instance; // Pointer back to the class instance
|
||||
DynamicEngine* engine;
|
||||
double T9;
|
||||
double rho;
|
||||
double energy;
|
||||
const std::vector<fourdst::atomic::Species>* networkSpecies;
|
||||
CVODESolverStrategy* solver_instance{}; // Pointer back to the class instance
|
||||
DynamicEngine* engine{};
|
||||
double T9{};
|
||||
double rho{};
|
||||
double energy{};
|
||||
const std::vector<fourdst::atomic::Species>* networkSpecies{};
|
||||
std::unique_ptr<exceptions::StaleEngineTrigger> captured_exception = nullptr;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user