45 std::string FilterThresholdMax::className =
 
   47                 "ThresholdMax", FilterThresholdMax::create);
 
   49 FilterThresholdMax::FilterThresholdMax(
 
   54     ParamMap::const_iterator it;
 
   57     it = pParams.find(
"ThresholdValue");
 
   58     ASSERTL0(it != pParams.end(), 
"Missing parameter 'ThresholdValue'.");
 
   63     it = pParams.find(
"InitialValue");
 
   64     ASSERTL0(it != pParams.end(), 
"Missing parameter 'InitialValue'.");
 
   69     it = pParams.find(
"StartTime");
 
   71     if (it != pParams.end())
 
   78     it = pParams.find(
"OutputFile");
 
   80     if (it != pParams.end())
 
   86     it = pParams.find(
"ThresholdVar");
 
   88     if (it != pParams.end())
 
   90         std::string var = it->second.c_str();
 
   91         std::vector<string> varlist = pSession->GetVariables();
 
   92         std::vector<string>::const_iterator x;
 
   95                  "Specified variable " + var +
 
   96                  " in ThresholdMax filter is not available.");
 
  142     std::vector<LibUtilities::FieldDefinitionsSharedPtr> FieldDef
 
  144     std::vector<std::vector<NekDouble> > FieldData(FieldDef.size());
 
  150     for(
int i = 0; i < FieldDef.size(); ++i)
 
  153         FieldDef[i]->m_fields.push_back(
"m");
 
  154         pFields[
m_thresholdVar]->AppendFieldData(FieldDef[i], FieldData[i], vCoeffs);
 
Array< OneD, NekDouble > m_threshold
Storage for recording when each point in domain rises above threshold. 
#define ASSERTL0(condition, msg)
virtual void v_Initialise(const Array< OneD, const MultiRegions::ExpListSharedPtr > &pFields, const NekDouble &time)
Initialises the filter. 
LibUtilities::FieldIOSharedPtr m_fld
FieldIO object for writing data. 
int m_thresholdVar
Variable on which to detect threshold. 
virtual SOLVER_UTILS_EXPORT ~FilterThresholdMax()
NekDouble m_initialValue
Initial value of storage. 
boost::shared_ptr< SessionReader > SessionReaderSharedPtr
virtual bool v_IsTimeDependent()
Indicate that this filter is time dependent. 
NekDouble m_thresholdValue
Value of threshold. 
NekDouble Evaluate() const 
NekDouble m_startTime
Time at which to start recording. 
std::map< std::string, std::string > ParamMap
LibUtilities::SessionReaderSharedPtr m_session
static boost::shared_ptr< FieldIO > CreateDefault(const LibUtilities::SessionReaderSharedPtr session)
Returns an object for the default FieldIO method. 
std::string m_outputFile
File into which to write output data. 
InputIterator find(InputIterator first, InputIterator last, InputIterator startingpoint, const EqualityComparable &value)
FilterFactory & GetFilterFactory()
virtual void v_Finalise(const Array< OneD, const MultiRegions::ExpListSharedPtr > &pFields, const NekDouble &time)
Finalise the filter and write out data. 
virtual void v_Update(const Array< OneD, const MultiRegions::ExpListSharedPtr > &pFields, const NekDouble &time)
For each point in domain test if solution is above threshold. 
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, tDescription pDesc="")
Register a class with the factory.