feat(field-support): added field support system, mid migration

currently the barotope and the pressure force operator are migrated to the new support system
This commit is contained in:
2026-08-23 10:13:53 -04:00
parent dc912fd15e
commit 0f3ca8050b
137 changed files with 29975 additions and 16389 deletions

View File

@@ -0,0 +1,37 @@
module;
#include <mfem.hpp>
export module mean_field:model.structure.base;
export import :eos.base;
export namespace mean_field::models::structure {
struct StructureSeed {
mfem::Vector radius;
mfem::Vector density;
mfem::Vector enthalpy;
double stellarRadius;
double centralDensity;
double centralEnthalpy;
};
struct StructureSeedRequest {
double centralDensity;
int radialSampleCount{512};
};
class StructureBase {
public:
virtual ~StructureBase() = default;
[[nodiscard]] virtual const eos::EquationOfState &equationOfState() const noexcept = 0;
[[nodiscard]] virtual double targetMass() const noexcept = 0;
[[nodiscard]] virtual StructureSeed makeInitialSeed(const StructureSeedRequest &request) const = 0;
virtual void validate() const = 0;
protected:
StructureBase() = default;
};
} // namespace mean_field::models::structure