SpECTRE  v2026.09.05
Loading...
Searching...
No Matches
amr::Limits Class Reference

The limits on refinement level and resolution for AMR. More...

#include <Limits.hpp>

Classes

struct  ErrorBeyondLimits
 Whether the code should error if EnforcePolicies has to prevent refinement from going beyond the given limits. More...
struct  FourierM
 Inclusive bounds on the \(m\) of Fourier modes for a S1 or B2 topology. More...
struct  NumPolynomialModes
 Inclusive bounds on the number of polynomial modes for a I1 or B1 topology. More...
struct  RefinementLevel
 Inclusive bounds on the refinement level. More...
struct  SphericalHarmonicL
 Inclusive bounds on the \(\ell\) of spherical harmonic modes. More...

Public Types

using options

Public Member Functions

 Limits (const std::optional< std::array< size_t, 2 > > &refinement_level_bounds, const std::optional< std::array< size_t, 2 > > &polynomial_mode_bounds, const std::optional< std::array< size_t, 2 > > &fourier_mode_bounds, const std::optional< std::array< size_t, 2 > > &spherical_harmonic_bounds, bool error_beyond_limits, const Options::Context &context={})
size_t minimum_refinement_level () const
size_t maximum_refinement_level () const
size_t minimum_resolution (Spectral::Basis basis, Spectral::Quadrature quadrature) const
size_t maximum_resolution (Spectral::Basis basis, Spectral::Quadrature quadrature) const
bool error_beyond_limits () const
std::ostream & print (std::ostream &os) const
void pup (PUP::er &p)

Static Public Attributes

static constexpr Options::String help

Friends

bool operator== (const Limits &lhs, const Limits &rhs)

Detailed Description

The limits on refinement level and resolution for AMR.

Details

  • For a default constructed Limits, the refinement level is bounded between 0 and ElementId<Dim>::max_refinement_level, and the resolution is bounded between Spectral::limits::min and Spectral::limits::max which are limits based on the implementation details of ElementId and Mesh. ErrorBeyondLimits is set to false.
  • Specifying Auto for any option uses the above limits.
  • If you specify a lower bound that violates the above limits, the limit will be raised to that needed by the code.
  • If you specify an upper bound that violates the above limits, the code will error on parsing the option.

Member Typedef Documentation

◆ options

using amr::Limits::options
Initial value:
Whether the code should error if EnforcePolicies has to prevent refinement from going beyond the give...
Definition Limits.hpp:79
Inclusive bounds on the of Fourier modes for a S1 or B2 topology.
Definition Limits.hpp:60
Inclusive bounds on the number of polynomial modes for a I1 or B1 topology.
Definition Limits.hpp:52
Inclusive bounds on the refinement level.
Definition Limits.hpp:45
Inclusive bounds on the of spherical harmonic modes.
Definition Limits.hpp:67

Member Data Documentation

◆ help

Options::String amr::Limits::help
staticconstexpr
Initial value:
= {
"Limits on refinement level and resolution for adaptive mesh "
"refinement."}

The documentation for this class was generated from the following file:
  • src/ParallelAlgorithms/Amr/Policies/Limits.hpp