SpECTRE Documentation Coverage Report
Current view: top level - Evolution/Systems/GrMhd/ValenciaDivClean/Subcell - InitialDataTci.hpp Hit Total Coverage
Commit: 3f09028930c0450a2fb61ee918b22882f5d03d2b Lines: 1 5 20.0 %
Date: 2021-10-22 20:52:16
Legend: Lines: hit not hit

          Line data    Source code
       1           0 : // Distributed under the MIT License.
       2             : // See LICENSE.txt for details.
       3             : 
       4             : #pragma once
       5             : 
       6             : #include <cstddef>
       7             : 
       8             : #include "DataStructures/Tensor/TypeAliases.hpp"
       9             : #include "Domain/Tags.hpp"
      10             : #include "Evolution/DgSubcell/Tags/Inactive.hpp"
      11             : #include "Evolution/Systems/GrMhd/ValenciaDivClean/Subcell/TciOptions.hpp"
      12             : #include "Evolution/Systems/GrMhd/ValenciaDivClean/Tags.hpp"
      13             : #include "PointwiseFunctions/Hydro/TagsDeclarations.hpp"
      14             : #include "Utilities/TMPL.hpp"
      15             : 
      16             : /// \cond
      17             : class DataVector;
      18             : template <size_t Dim>
      19             : class Mesh;
      20             : template <typename TagsList>
      21             : class Variables;
      22             : /// \endcond
      23             : 
      24             : namespace grmhd::ValenciaDivClean::subcell {
      25             : /*!
      26             :  * \brief The troubled-cell indicator run on DG initial data to see if we need
      27             :  * to switch to subcell.
      28             :  *
      29             :  * The following checks are done in the order they are listed:
      30             :  *
      31             :  * - if `TildeD` (`TildeTau`) on the DG or subcell grid (projected from the DG
      32             :  *   grid, not initialized to the initial data) is less than
      33             :  *   `tci_options.minimum_rest_mass_density_times_lorentz_factor`
      34             :  *   (`tci_options.minimum_tilde_tau`), then the element is flagged as troubled.
      35             :  * - apply the two-mesh relaxed discrete maximum principle TCI
      36             :  * - apply the Persson TCI to \f$\tilde{D}\f$ and \f$\tilde{\tau}\f$.
      37             :  * - apply the Persson TCI to the magnitude of \f$\tilde{B}\f$ if its magnitude
      38             :  *   on the DG grid is greater than `tci_options.magnetic_field_cutoff`.
      39             :  */
      40           1 : struct DgInitialDataTci {
      41             :  private:
      42             :   template <typename Tag>
      43           0 :   using Inactive = evolution::dg::subcell::Tags::Inactive<Tag>;
      44             : 
      45             :  public:
      46           0 :   using argument_tags = tmpl::list<domain::Tags::Mesh<3>, Tags::TciOptions>;
      47             : 
      48           0 :   static bool apply(
      49             :       const Variables<tmpl::list<
      50             :           ValenciaDivClean::Tags::TildeD, ValenciaDivClean::Tags::TildeTau,
      51             :           ValenciaDivClean::Tags::TildeS<>, ValenciaDivClean::Tags::TildeB<>,
      52             :           ValenciaDivClean::Tags::TildePhi>>& dg_vars,
      53             :       const Variables<tmpl::list<Inactive<ValenciaDivClean::Tags::TildeD>,
      54             :                                  Inactive<ValenciaDivClean::Tags::TildeTau>,
      55             :                                  Inactive<ValenciaDivClean::Tags::TildeS<>>,
      56             :                                  Inactive<ValenciaDivClean::Tags::TildeB<>>,
      57             :                                  Inactive<ValenciaDivClean::Tags::TildePhi>>>&
      58             :           subcell_vars,
      59             :       double rdmp_delta0, double rdmp_epsilon, double persson_exponent,
      60             :       const Mesh<3>& dg_mesh, const TciOptions& tci_options);
      61             : };
      62             : }  // namespace grmhd::ValenciaDivClean::subcell

Generated by: LCOV version 1.14