ABLATE Source Documentation  0.12.34
constant.hpp
1 #ifndef ABLATELIBRARY_RADIATIONPROPERTIESCONSTANT_H
2 #define ABLATELIBRARY_RADIATIONPROPERTIESCONSTANT_H
3 
4 #include "radiation/radiation.hpp"
5 #include "radiationProperties.hpp"
6 
7 namespace ablate::eos::radiationProperties {
8 
9 class Constant : public RadiationModel {
10  private:
11  struct FunctionContext {
12  const PetscReal absorptivity;
13  const PetscReal emissivity;
14  };
15 
16  PetscReal absorptivityIn;
17  PetscReal emissivityIn;
18 
23  static inline constexpr PetscReal GetRefractiveIndex() { return 1; }
24 
31  static PetscErrorCode ConstantAbsorptionTemperatureFunction(const PetscReal conserved[], PetscReal temperature, PetscReal* property, void* ctx);
32 
41  static PetscErrorCode ConstantEmissionTemperatureFunction(const PetscReal conserved[], PetscReal temperature, PetscReal* property, void* ctx);
42 
43  public:
44  explicit Constant(double absorptivity, double emissivity);
45  explicit Constant(const Constant&) = delete;
46  void operator=(const Constant&) = delete;
47 
54  [[nodiscard]] ThermodynamicTemperatureFunction GetRadiationPropertiesTemperatureFunction(RadiationProperty property, const std::vector<domain::Field>& fields) const override;
55 };
56 
57 } // namespace ablate::eos::radiationProperties
58 
59 #endif // ABLATELIBRARY_CONSTANT_H
ThermodynamicTemperatureFunction GetRadiationPropertiesTemperatureFunction(RadiationProperty property, const std::vector< domain::Field > &fields) const override
Definition: constant.cpp:19
Definition: radiationProperties.hpp:11