SpECTRE  v2022.10.04
DenseTriggers::Filter Class Reference

Filter activations of a dense trigger using a non-dense trigger. More...

#include <Filter.hpp>

Classes

struct  FilterOption
 
struct  TriggerOption
 

Public Types

using options = tmpl::list< TriggerOption, FilterOption >
 
using is_triggered_argument_tags = tmpl::list< Tags::DataBox >
 
using next_check_time_argument_tags = tmpl::list< Tags::DataBox >
 

Public Member Functions

 Filter (std::unique_ptr< DenseTrigger > trigger, std::unique_ptr< Trigger > filter)
 
template<typename Metavariables , typename ArrayIndex , typename Component , typename DbTags >
std::optional< bool > is_triggered (Parallel::GlobalCache< Metavariables > &cache, const ArrayIndex &array_index, const Component *component, const db::DataBox< DbTags > &box) const
 
template<typename Metavariables , typename ArrayIndex , typename Component , typename DbTags >
std::optional< double > next_check_time (Parallel::GlobalCache< Metavariables > &cache, const ArrayIndex &array_index, const Component *component, const db::DataBox< DbTags > &box) const
 
void pup (PUP::er &p) override
 
- Public Member Functions inherited from DenseTrigger
template<typename DbTags , typename Metavariables , typename ArrayIndex , typename Component >
std::optional< bool > is_triggered (const db::DataBox< DbTags > &box, Parallel::GlobalCache< Metavariables > &cache, const ArrayIndex &array_index, const Component *const component)
 Check whether the trigger fires. Returns std::nullopt if insufficient data is available to make the decision. The trigger is not responsible for checking whether dense output of the evolved variables is possible, but may need to check things such as the availability of FunctionOfTime data.
 
template<typename DbTags , typename Metavariables , typename ArrayIndex , typename Component >
std::optional< double > next_check_time (const db::DataBox< DbTags > &box, Parallel::GlobalCache< Metavariables > &cache, const ArrayIndex &array_index, const Component *component)
 Obtain the next time to check the trigger, or std::nullopt if the trigger is not ready to report yet.
 
std::optional< double > previous_trigger_time () const
 Reports the value of Tags::Time when the trigger most recently fired, except for the most recent call of is_triggered. More...
 
void pup (PUP::er &p) override
 

Static Public Attributes

static constexpr Options::String help
 

Detailed Description

Filter activations of a dense trigger using a non-dense trigger.

For example, to trigger every 10 starting at 100, one could use

Filter:
Times:
EvenlySpaced:
Offset: 0
Interval: 10
Filter:
TimeCompares:
Comparison: GreaterThanOrEqualTo
Value: 100
Base class for checking whether to run an Event.
Definition: Trigger.hpp:17

Member Data Documentation

◆ help

constexpr Options::String DenseTriggers::Filter::help
staticconstexpr
Initial value:
=
"Filter activations of a dense trigger using a non-dense trigger."

The documentation for this class was generated from the following file: