Shamrock 2025.10.0
Astrophysical Code
Loading...
Searching...
No Matches
shammodels::sph Namespace Reference

namespace for the sph model More...

Namespaces

namespace  modules
 namespace for the sph model modules

Classes

struct  BasicSPHGhostHandlerConfig
class  BasicSPHGhostHandler
struct  AVConfig_None
 No artificial viscosity: \( q^a_ab = 0\). More...
struct  AVConfig_Constant
 Constant artificial viscosity: \( \alpha = cte\). More...
struct  AVConfig_VaryingMM97
 Morris & Monaghan 1997. More...
struct  AVConfig_VaryingCD10
 Cullen & Dehnen 2010. More...
struct  AVConfig_ConstantDisc
 Constant artificial viscosity for alpha disc viscosity. More...
struct  AVConfig
 Configuration for the Artificial Viscosity (AV). More...
struct  BCConfig
 Boundary conditions configuration. More...
struct  MHDConfig
struct  PhantomDumpTableHeader
 Phantom dump table header for a specific type. More...
struct  PhantomDumpBlockArray
 A helper class to represent a single block of data in a Phantom dump. More...
struct  PhantomDumpBlock
 A class to represent a single block of data in a Phantom dump. More...
struct  PhantomDump
 Class representing a Phantom dump file. More...
class  Model
 The shamrock SPH model. More...
class  SolverStorage
struct  SinkEdges
struct  SinkParticle
struct  TimestepLog
struct  EvolveUntilResults
class  Solver
 The shamrock SPH model. More...
struct  SolverConfig
 The configuration for a sph solver. More...
struct  CFLConfig
 The configuration for the CFL condition. More...
struct  ParticleKillingConfig
struct  DustConfig
struct  SmoothingLengthConfig
struct  SelfGravConfig
struct  SolverLog
 Class holding the logs of the solver /todo add a variable to keep only a definite number of steps in the step_logs. More...
class  SPHTreeUtilities
class  SPHUtilities
 handle basic utilities dealing with SPH More...
struct  Debug_ph_dump

Typedefs

template<class T>
using Component = shambase::StorageComponent<T>

Functions

template<class Tscal>
void to_json (nlohmann::json &j, const AVConfig_None< Tscal > &p)
template<class Tscal>
void from_json (const nlohmann::json &j, AVConfig_None< Tscal > &p)
template<class Tscal>
void to_json (nlohmann::json &j, const AVConfig_Constant< Tscal > &p)
template<class Tscal>
void from_json (const nlohmann::json &j, AVConfig_Constant< Tscal > &p)
template<class Tscal>
void to_json (nlohmann::json &j, const AVConfig_VaryingMM97< Tscal > &p)
template<class Tscal>
void from_json (const nlohmann::json &j, AVConfig_VaryingMM97< Tscal > &p)
template<class Tscal>
void to_json (nlohmann::json &j, const AVConfig_VaryingCD10< Tscal > &p)
template<class Tscal>
void from_json (const nlohmann::json &j, AVConfig_VaryingCD10< Tscal > &p)
template<class Tscal>
void to_json (nlohmann::json &j, const AVConfig_ConstantDisc< Tscal > &p)
template<class Tscal>
void from_json (const nlohmann::json &j, AVConfig_ConstantDisc< Tscal > &p)
template<class Tvec>
void to_json (nlohmann::json &j, const AVConfig< Tvec > &p)
 Convert an AVConfig to a json object.
template<class Tvec>
void from_json (const nlohmann::json &j, AVConfig< Tvec > &p)
 Convert a json object to an AVConfig.
template<class Tvec>
void to_json (nlohmann::json &j, const BCConfig< Tvec > &p)
 Serialize a BCConfig to a JSON object.
template<class Tvec>
void from_json (const nlohmann::json &j, BCConfig< Tvec > &p)
 Deserialize a JSON object into a BCConfig.
template<class Tvec>
void to_json (nlohmann::json &j, const MHDConfig< Tvec > &p)
 Serialize a MHDConfig to a JSON object.
template<class Tvec>
void from_json (const nlohmann::json &j, MHDConfig< Tvec > &p)
 Deserialize a JSON object into a MHDConfig.
template<class Tvec>
EOSConfig< Tvec > get_shamrock_eosconfig (PhantomDump &phdump, bool bypass_error)
 Generate a Shamrock EOS configuration from a PhantomDump object.
template<class Tvec>
void write_shamrock_eos_in_phantom_dump (EOSConfig< Tvec > &cfg, PhantomDump &dump, bool bypass_error)
 Write the eos config to th phantom dump header.
template<class Tvec>
AVConfig< Tvec > get_shamrock_avconfig (PhantomDump &phdump)
 Generate an Shamrock artificial viscosity configuration from a PhantomDump object.
template<class Tscal>
shamunits::UnitSystem< Tscal > get_shamrock_units (PhantomDump &phdump)
 Get the shamrock units object.
template<class Tscal>
void write_shamrock_units_in_phantom_dump (std::optional< shamunits::UnitSystem< Tscal > > &units, PhantomDump &dump, bool bypass_error)
 Write shamrock units config into the phantom dump.
template<class Tvec>
BCConfig< Tvec > get_shamrock_boundary_config (PhantomDump &phdump)
 Generate an Shamrock boundary configuration from a PhantomDump object.
template<class Tvec>
void write_shamrock_boundaries_in_phantom_dump (BCConfig< Tvec > &cfg, std::tuple< Tvec, Tvec > box_size, PhantomDump &dump, bool bypass_error)
bool compare_phantom_dumps (PhantomDump &dump1, PhantomDump &dump2)
 Compare two phantom dumps and report offenses.
template<class Tvec>
void ensure_sink_edges (shamrock::solvergraph::SolverGraphSerializable &sync)
 Register sink SoA synchronized edges if missing (idempotent).
template<class Tvec>
std::vector< Tvec > & get_sink_pos (shamrock::solvergraph::SolverGraphSerializable &sync)
 Named SoA getters (edges must already exist; call ensure_sink_edges first). Prefer these when a function only needs a subset of sink fields.
template<class Tvec>
std::vector< Tvec > & get_sink_vel (shamrock::solvergraph::SolverGraphSerializable &sync)
template<class Tvec>
std::vector< Tvec > & get_sink_acc_sph (shamrock::solvergraph::SolverGraphSerializable &sync)
template<class Tvec>
std::vector< Tvec > & get_sink_acc_ext (shamrock::solvergraph::SolverGraphSerializable &sync)
template<class Tvec>
std::vector< shambase::VecComponent< Tvec > > & get_sink_mass (shamrock::solvergraph::SolverGraphSerializable &sync)
template<class Tvec>
std::vector< Tvec > & get_sink_angular_momentum (shamrock::solvergraph::SolverGraphSerializable &sync)
template<class Tvec>
std::vector< shambase::VecComponent< Tvec > > & get_sink_accretion_radius (shamrock::solvergraph::SolverGraphSerializable &sync)
template<class Tvec>
bool has_sinks (shamrock::solvergraph::SolverGraphSerializable &sync)
 Check whether any sinks are present by inspecting sink_pos only.
template<class Tvec>
SinkEdges< Tvec > get_sink_edges (shamrock::solvergraph::SolverGraphSerializable &sync)
 Fetch mutable references to the sink SoA synchronized edges.
template<class Tvec>
std::vector< SinkParticle< Tvec > > to_sink_particles (const SinkEdges< Tvec > &e)
 Build an AoS sink list from the current SoA edges (Python API / dump helpers).
template<class Tvec>
void set_sink_particles (SinkEdges< Tvec > &e, const std::vector< SinkParticle< Tvec > > &sinks)
 Replace SoA sink edge contents from an AoS sink list (legacy dump migration).
template<class Tvec>
void add_sink (SinkEdges< Tvec > &e, typename SinkEdges< Tvec >::Tscal mass, Tvec pos, Tvec velocity, typename SinkEdges< Tvec >::Tscal accretion_radius)
 Append one sink to the SoA edges.
template<class Tvec>
void to_json (nlohmann::json &j, const SinkParticle< Tvec > &p)
template<class Tvec>
void from_json (const nlohmann::json &j, SinkParticle< Tvec > &p)
template<class Tscal>
void to_json (nlohmann::json &j, const CFLConfig< Tscal > &p)
 Converts a CFLConfig object to a JSON object.
template<class Tscal>
void from_json (const nlohmann::json &j, CFLConfig< Tscal > &p)
 Deserializes a CFLConfig object from a JSON object.
template<class Tvec>
void to_json (nlohmann::json &j, const ParticleKillingConfig< Tvec > &p)
template<class Tvec>
void from_json (const nlohmann::json &j, ParticleKillingConfig< Tvec > &p)
void to_json (nlohmann::json &j, const SmoothingLengthConfig &p)
void from_json (const nlohmann::json &j, SmoothingLengthConfig &p)
void to_json (nlohmann::json &j, const SelfGravConfig &p)
 JSON serialization for SelfGravConfig.
void from_json (const nlohmann::json &j, SelfGravConfig &p)
 JSON deserialization for SelfGravConfig.
template<class Tvec>
void to_json (nlohmann::json &j, const DustConfig< Tvec > &p)
template<class Tvec>
void from_json (const nlohmann::json &j, DustConfig< Tvec > &p)
template<class Tvec, template< class > class SPHKernel>
void to_json (nlohmann::json &j, const SolverConfig< Tvec, SPHKernel > &p)
 Serializes a SolverConfig object to a JSON object.
template<class Tvec, template< class > class SPHKernel>
void from_json (const nlohmann::json &j, SolverConfig< Tvec, SPHKernel > &p)
 Deserializes a SolverConfig object from a JSON object.
template EOSConfig< f32_3 > get_shamrock_eosconfig< f32_3 > (PhantomDump &phdump, bool bypass_error)
 explicit instanciation for f32_3
template EOSConfig< f64_3 > get_shamrock_eosconfig< f64_3 > (PhantomDump &phdump, bool bypass_error)
 explicit instanciation for f64_3
template void write_shamrock_eos_in_phantom_dump< f32_3 > (EOSConfig< f32_3 > &cfg, PhantomDump &dump, bool bypass_error)
 explicit instanciation for f32_3
template void write_shamrock_eos_in_phantom_dump< f64_3 > (EOSConfig< f64_3 > &cfg, PhantomDump &dump, bool bypass_error)
 explicit instanciation for f64_3
template AVConfig< f32_3 > get_shamrock_avconfig< f32_3 > (PhantomDump &phdump)
 explicit instanciation for f32_3
template AVConfig< f64_3 > get_shamrock_avconfig< f64_3 > (PhantomDump &phdump)
 explicit instanciation for f64_3
template shamunits::UnitSystem< f32get_shamrock_units< f32 > (PhantomDump &phdump)
 explicit instanciation for f32_3
template shamunits::UnitSystem< f64get_shamrock_units< f64 > (PhantomDump &phdump)
 explicit instanciation for f64_3
template void write_shamrock_units_in_phantom_dump< f64 > (std::optional< shamunits::UnitSystem< f64 > > &units, PhantomDump &dump, bool bypass_error)
template BCConfig< f32_3 > get_shamrock_boundary_config< f32_3 > (PhantomDump &phdump)
 explicit instanciation for f32_3
template BCConfig< f64_3 > get_shamrock_boundary_config< f64_3 > (PhantomDump &phdump)
 explicit instanciation for f64_3
template void write_shamrock_boundaries_in_phantom_dump< f32_3 > (BCConfig< f32_3 > &cfg, std::tuple< f32_3, f32_3 > box_size, PhantomDump &dump, bool bypass_error)
 explicit instanciation for f32_3
template void write_shamrock_boundaries_in_phantom_dump< f64_3 > (BCConfig< f64_3 > &cfg, std::tuple< f64_3, f64_3 > box_size, PhantomDump &dump, bool bypass_error)
 explicit instanciation for f64_3
template<class Tvec>
void fill_blocks (PhantomDumpBlock &block, Debug_ph_dump< Tvec > &info)
template<class Tvec>
shammodels::sph::PhantomDump make_interface_debug_phantom_dump (Debug_ph_dump< Tvec > info)

Detailed Description

namespace for the sph model

Typedef Documentation

◆ Component

template<class T>
using shammodels::sph::Component = shambase::StorageComponent<T>

Definition at line 44 of file SolverStorage.hpp.

Function Documentation

◆ add_sink()

template<class Tvec>
void shammodels::sph::add_sink ( SinkEdges< Tvec > & e,
typename SinkEdges< Tvec >::Tscal mass,
Tvec pos,
Tvec velocity,
typename SinkEdges< Tvec >::Tscal accretion_radius )
inline

Append one sink to the SoA edges.

Definition at line 234 of file sink_edges_helper.hpp.

◆ compare_phantom_dumps()

bool shammodels::sph::compare_phantom_dumps ( PhantomDump & dump1,
PhantomDump & dump2 )

Compare two phantom dumps and report offenses.

Definition at line 397 of file PhantomDump.cpp.

Here is the call graph for this function:

◆ ensure_sink_edges()

template<class Tvec>
void shammodels::sph::ensure_sink_edges ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Register sink SoA synchronized edges if missing (idempotent).

Definition at line 81 of file sink_edges_helper.hpp.

◆ fill_blocks()

template<class Tvec>
void shammodels::sph::fill_blocks ( PhantomDumpBlock & block,
Debug_ph_dump< Tvec > & info )

Definition at line 669 of file Solver.cpp.

◆ from_json() [1/15]

template<class Tvec>
void shammodels::sph::from_json ( const nlohmann::json & j,
AVConfig< Tvec > & p )
inline

Convert a json object to an AVConfig.

Parameters
jthe json object to be used
pthe AVConfig object to be filled

Definition at line 370 of file AVConfig.hpp.

Here is the call graph for this function:

◆ from_json() [2/15]

template<class Tscal>
void shammodels::sph::from_json ( const nlohmann::json & j,
AVConfig_Constant< Tscal > & p )
inline

Definition at line 67 of file AVConfig.hpp.

◆ from_json() [3/15]

template<class Tscal>
void shammodels::sph::from_json ( const nlohmann::json & j,
AVConfig_ConstantDisc< Tscal > & p )
inline

Definition at line 165 of file AVConfig.hpp.

◆ from_json() [4/15]

template<class Tscal>
void shammodels::sph::from_json ( const nlohmann::json & j,
AVConfig_None< Tscal > & p )
inline

Definition at line 41 of file AVConfig.hpp.

◆ from_json() [5/15]

template<class Tscal>
void shammodels::sph::from_json ( const nlohmann::json & j,
AVConfig_VaryingCD10< Tscal > & p )
inline

Definition at line 135 of file AVConfig.hpp.

◆ from_json() [6/15]

template<class Tscal>
void shammodels::sph::from_json ( const nlohmann::json & j,
AVConfig_VaryingMM97< Tscal > & p )
inline

Definition at line 100 of file AVConfig.hpp.

◆ from_json() [7/15]

template<class Tvec>
void shammodels::sph::from_json ( const nlohmann::json & j,
BCConfig< Tvec > & p )
inline

Deserialize a JSON object into a BCConfig.

Parameters
[in]jThe JSON object to read from
[out]pThe BCConfig to deserialize

Definition at line 188 of file BCConfig.hpp.

Here is the call graph for this function:

◆ from_json() [8/15]

template<class Tscal>
void shammodels::sph::from_json ( const nlohmann::json & j,
CFLConfig< Tscal > & p )
inline

Deserializes a CFLConfig object from a JSON object.

Parameters
jThe JSON object to deserialize from.
pThe CFLConfig object to populate.

Definition at line 1073 of file SolverConfig.hpp.

◆ from_json() [9/15]

template<class Tvec>
void shammodels::sph::from_json ( const nlohmann::json & j,
DustConfig< Tvec > & p )
inline

Definition at line 1244 of file SolverConfig.hpp.

◆ from_json() [10/15]

template<class Tvec>
void shammodels::sph::from_json ( const nlohmann::json & j,
MHDConfig< Tvec > & p )
inline

Deserialize a JSON object into a MHDConfig.

Parameters
[in]jThe JSON object to read from
[out]pThe MHDConfig to deserialize

Definition at line 155 of file MHDConfig.hpp.

Here is the call graph for this function:

◆ from_json() [11/15]

template<class Tvec>
void shammodels::sph::from_json ( const nlohmann::json & j,
ParticleKillingConfig< Tvec > & p )
inline

Definition at line 1102 of file SolverConfig.hpp.

◆ from_json() [12/15]

void shammodels::sph::from_json ( const nlohmann::json & j,
SelfGravConfig & p )
inline

JSON deserialization for SelfGravConfig.

Definition at line 1195 of file SolverConfig.hpp.

Here is the call graph for this function:

◆ from_json() [13/15]

template<class Tvec>
void shammodels::sph::from_json ( const nlohmann::json & j,
SinkParticle< Tvec > & p )
inline

Definition at line 57 of file SinkPartStruct.hpp.

◆ from_json() [14/15]

void shammodels::sph::from_json ( const nlohmann::json & j,
SmoothingLengthConfig & p )
inline

Definition at line 1137 of file SolverConfig.hpp.

◆ from_json() [15/15]

template<class Tvec, template< class > class SPHKernel>
void shammodels::sph::from_json ( const nlohmann::json & j,
SolverConfig< Tvec, SPHKernel > & p )
inline

Deserializes a SolverConfig object from a JSON object.

Parameters
jThe JSON object to deserialize from.
pThe SolverConfig object to populate.

Definition at line 1320 of file SolverConfig.hpp.

Here is the call graph for this function:

◆ get_shamrock_avconfig()

template<class Tvec>
AVConfig< Tvec > shammodels::sph::get_shamrock_avconfig ( PhantomDump & phdump)

Generate an Shamrock artificial viscosity configuration from a PhantomDump object.

Parameters
phdumpReference to the PhantomDump object.
Returns
The artificial viscosity configuration corresponding to the given PhantomDump object.

Definition at line 133 of file Phantom2Shamrock.cpp.

Here is the call graph for this function:

◆ get_shamrock_boundary_config()

template<class Tvec>
BCConfig< Tvec > shammodels::sph::get_shamrock_boundary_config ( PhantomDump & phdump)

Generate an Shamrock boundary configuration from a PhantomDump object.

Parameters
phdumpReference to the PhantomDump object.
Returns
The boundary configuration corresponding to the given PhantomDump object.

Definition at line 204 of file Phantom2Shamrock.cpp.

Here is the call graph for this function:

◆ get_shamrock_eosconfig()

template<class Tvec>
EOSConfig< Tvec > shammodels::sph::get_shamrock_eosconfig ( PhantomDump & phdump,
bool bypass_error )

Generate a Shamrock EOS configuration from a PhantomDump object.

Parameters
phdumpReference to the PhantomDump object.
bypass_errorFlag to bypass error handling.
Returns
The EOS configuration corresponding to the given PhantomDump object.
Exceptions
std::runtime_errorIf an error occurs during configuration retrieval.

Definition at line 26 of file Phantom2Shamrock.cpp.

Here is the call graph for this function:

◆ get_shamrock_units()

template<class Tscal>
shamunits::UnitSystem< Tscal > shammodels::sph::get_shamrock_units ( PhantomDump & phdump)

Get the shamrock units object.

Todo
load also magfd
Template Parameters
Tscal
Parameters
phdump
Returns
shamunits::UnitSystem<Tscal>

Definition at line 147 of file Phantom2Shamrock.cpp.

Here is the call graph for this function:

◆ get_sink_acc_ext()

template<class Tvec>
std::vector< Tvec > & shammodels::sph::get_sink_acc_ext ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Definition at line 121 of file sink_edges_helper.hpp.

◆ get_sink_acc_sph()

template<class Tvec>
std::vector< Tvec > & shammodels::sph::get_sink_acc_sph ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Definition at line 115 of file sink_edges_helper.hpp.

◆ get_sink_accretion_radius()

template<class Tvec>
std::vector< shambase::VecComponent< Tvec > > & shammodels::sph::get_sink_accretion_radius ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Definition at line 139 of file sink_edges_helper.hpp.

◆ get_sink_angular_momentum()

template<class Tvec>
std::vector< Tvec > & shammodels::sph::get_sink_angular_momentum ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Definition at line 133 of file sink_edges_helper.hpp.

◆ get_sink_edges()

template<class Tvec>
SinkEdges< Tvec > shammodels::sph::get_sink_edges ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Fetch mutable references to the sink SoA synchronized edges.

Edges must already exist (call ensure_sink_edges first). Prefer named getters when only a subset of fields is needed.

Definition at line 163 of file sink_edges_helper.hpp.

Here is the call graph for this function:

◆ get_sink_mass()

template<class Tvec>
std::vector< shambase::VecComponent< Tvec > > & shammodels::sph::get_sink_mass ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Definition at line 127 of file sink_edges_helper.hpp.

◆ get_sink_pos()

template<class Tvec>
std::vector< Tvec > & shammodels::sph::get_sink_pos ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Named SoA getters (edges must already exist; call ensure_sink_edges first). Prefer these when a function only needs a subset of sink fields.

Definition at line 105 of file sink_edges_helper.hpp.

◆ get_sink_vel()

template<class Tvec>
std::vector< Tvec > & shammodels::sph::get_sink_vel ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Definition at line 110 of file sink_edges_helper.hpp.

◆ has_sinks()

template<class Tvec>
bool shammodels::sph::has_sinks ( shamrock::solvergraph::SolverGraphSerializable & sync)
inline

Check whether any sinks are present by inspecting sink_pos only.

Prefer this for early-exit checks instead of fetching the full SinkEdges struct. Edges must already exist (call ensure_sink_edges first).

Definition at line 152 of file sink_edges_helper.hpp.

Here is the call graph for this function:

◆ make_interface_debug_phantom_dump()

template<class Tvec>
shammodels::sph::PhantomDump shammodels::sph::make_interface_debug_phantom_dump ( Debug_ph_dump< Tvec > info)

Definition at line 706 of file Solver.cpp.

◆ set_sink_particles()

template<class Tvec>
void shammodels::sph::set_sink_particles ( SinkEdges< Tvec > & e,
const std::vector< SinkParticle< Tvec > > & sinks )
inline

Replace SoA sink edge contents from an AoS sink list (legacy dump migration).

Definition at line 201 of file sink_edges_helper.hpp.

◆ to_json() [1/15]

template<class Tvec>
void shammodels::sph::to_json ( nlohmann::json & j,
const AVConfig< Tvec > & p )
inline

Convert an AVConfig to a json object.

Parameters
jthe json object to be filled
pthe AVConfig object

Definition at line 355 of file AVConfig.hpp.

◆ to_json() [2/15]

template<class Tscal>
void shammodels::sph::to_json ( nlohmann::json & j,
const AVConfig_Constant< Tscal > & p )
inline

Definition at line 58 of file AVConfig.hpp.

◆ to_json() [3/15]

template<class Tscal>
void shammodels::sph::to_json ( nlohmann::json & j,
const AVConfig_ConstantDisc< Tscal > & p )
inline

Definition at line 156 of file AVConfig.hpp.

◆ to_json() [4/15]

template<class Tscal>
void shammodels::sph::to_json ( nlohmann::json & j,
const AVConfig_None< Tscal > & p )
inline

Definition at line 38 of file AVConfig.hpp.

◆ to_json() [5/15]

template<class Tscal>
void shammodels::sph::to_json ( nlohmann::json & j,
const AVConfig_VaryingCD10< Tscal > & p )
inline

Definition at line 124 of file AVConfig.hpp.

◆ to_json() [6/15]

template<class Tscal>
void shammodels::sph::to_json ( nlohmann::json & j,
const AVConfig_VaryingMM97< Tscal > & p )
inline

Definition at line 89 of file AVConfig.hpp.

◆ to_json() [7/15]

template<class Tvec>
void shammodels::sph::to_json ( nlohmann::json & j,
const BCConfig< Tvec > & p )
inline

Serialize a BCConfig to a JSON object.

Parameters
[out]jThe JSON object to write to
[in]pThe BCConfig to serialize

Definition at line 152 of file BCConfig.hpp.

Here is the call graph for this function:

◆ to_json() [8/15]

template<class Tscal>
void shammodels::sph::to_json ( nlohmann::json & j,
const CFLConfig< Tscal > & p )
inline

Converts a CFLConfig object to a JSON object.

Parameters
jThe JSON object to be populated.
pThe CFLConfig object to be converted.

Definition at line 1058 of file SolverConfig.hpp.

◆ to_json() [9/15]

template<class Tvec>
void shammodels::sph::to_json ( nlohmann::json & j,
const DustConfig< Tvec > & p )
inline

Definition at line 1235 of file SolverConfig.hpp.

◆ to_json() [10/15]

template<class Tvec>
void shammodels::sph::to_json ( nlohmann::json & j,
const MHDConfig< Tvec > & p )
inline

Serialize a MHDConfig to a JSON object.

Parameters
[out]jThe JSON object to write to
[in]pThe MHDConfig to serialize

Definition at line 118 of file MHDConfig.hpp.

Here is the call graph for this function:

◆ to_json() [11/15]

template<class Tvec>
void shammodels::sph::to_json ( nlohmann::json & j,
const ParticleKillingConfig< Tvec > & p )
inline

Definition at line 1089 of file SolverConfig.hpp.

◆ to_json() [12/15]

void shammodels::sph::to_json ( nlohmann::json & j,
const SelfGravConfig & p )
inline

JSON serialization for SelfGravConfig.

Definition at line 1149 of file SolverConfig.hpp.

Here is the call graph for this function:

◆ to_json() [13/15]

template<class Tvec>
void shammodels::sph::to_json ( nlohmann::json & j,
const SinkParticle< Tvec > & p )
inline

Definition at line 40 of file SinkPartStruct.hpp.

◆ to_json() [14/15]

void shammodels::sph::to_json ( nlohmann::json & j,
const SmoothingLengthConfig & p )
inline

Definition at line 1117 of file SolverConfig.hpp.

◆ to_json() [15/15]

template<class Tvec, template< class > class SPHKernel>
void shammodels::sph::to_json ( nlohmann::json & j,
const SolverConfig< Tvec, SPHKernel > & p )
inline

Serializes a SolverConfig object to a JSON object.

Parameters
jThe JSON object to serialize to.
pThe SolverConfig object to serialize.

Definition at line 1257 of file SolverConfig.hpp.

◆ to_sink_particles()

template<class Tvec>
std::vector< SinkParticle< Tvec > > shammodels::sph::to_sink_particles ( const SinkEdges< Tvec > & e)
inline

Build an AoS sink list from the current SoA edges (Python API / dump helpers).

Definition at line 179 of file sink_edges_helper.hpp.

◆ write_shamrock_boundaries_in_phantom_dump()

template<class Tvec>
void shammodels::sph::write_shamrock_boundaries_in_phantom_dump ( BCConfig< Tvec > & cfg,
std::tuple< Tvec, Tvec > box_size,
PhantomDump & dump,
bool bypass_error )

Definition at line 218 of file Phantom2Shamrock.cpp.

◆ write_shamrock_eos_in_phantom_dump()

template<class Tvec>
void shammodels::sph::write_shamrock_eos_in_phantom_dump ( EOSConfig< Tvec > & cfg,
PhantomDump & dump,
bool bypass_error )

Write the eos config to th phantom dump header.

Definition at line 69 of file Phantom2Shamrock.cpp.

Here is the call graph for this function:

◆ write_shamrock_units_in_phantom_dump()

template<class Tscal>
void shammodels::sph::write_shamrock_units_in_phantom_dump ( std::optional< shamunits::UnitSystem< Tscal > > & units,
PhantomDump & dump,
bool bypass_error )

Write shamrock units config into the phantom dump.

Definition at line 164 of file Phantom2Shamrock.cpp.

Here is the call graph for this function: