www.mooseframework.org
MaterialTimeStepPostprocessor.h
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://www.mooseframework.org
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 #pragma once
11 
12 #include "ElementPostprocessor.h"
13 
15 
16 template <>
18 
23 class MaterialTimeStepPostprocessor : public ElementPostprocessor
24 {
25 public:
26  static InputParameters validParams();
27 
28  MaterialTimeStepPostprocessor(const InputParameters & parameters);
29  virtual void initialize();
30  virtual void execute();
31  virtual Real getValue();
32  virtual void threadJoin(const UserObject & y);
33 
34 protected:
37 
39  const MaterialProperty<Real> * _matl_time_step;
40 
43 
46 
48  const MaterialProperty<Real> * _changed_property;
49  const MaterialProperty<Real> * _changed_property_old;
51 
53  const int _elements_changed;
54 
56  int _count;
57 
60 
62  unsigned int _qp;
63 };
MaterialTimeStepPostprocessor::_elements_changed
const int _elements_changed
Target number of changed elements used to determine if we need to change the time step.
Definition: MaterialTimeStepPostprocessor.h:53
MaterialTimeStepPostprocessor::validParams
static InputParameters validParams()
Definition: MaterialTimeStepPostprocessor.C:25
MaterialTimeStepPostprocessor::initialize
virtual void initialize()
Definition: MaterialTimeStepPostprocessor.C:90
MaterialTimeStepPostprocessor::_matl_time_step
const MaterialProperty< Real > * _matl_time_step
Pointer to the material property containing the time step limit.
Definition: MaterialTimeStepPostprocessor.h:39
MaterialTimeStepPostprocessor::_qp
unsigned int _qp
Current quadrature point.
Definition: MaterialTimeStepPostprocessor.h:62
MaterialTimeStepPostprocessor::_changed_property
const MaterialProperty< Real > * _changed_property
Material property used to determine if elements have changed.
Definition: MaterialTimeStepPostprocessor.h:48
MaterialTimeStepPostprocessor::threadJoin
virtual void threadJoin(const UserObject &y)
Definition: MaterialTimeStepPostprocessor.C:133
MaterialTimeStepPostprocessor::_matl_value
Real _matl_value
Current time step limit from the material properties.
Definition: MaterialTimeStepPostprocessor.h:42
MaterialTimeStepPostprocessor::execute
virtual void execute()
Definition: MaterialTimeStepPostprocessor.C:97
MaterialTimeStepPostprocessor::_changed_property_old
const MaterialProperty< Real > * _changed_property_old
Definition: MaterialTimeStepPostprocessor.h:49
MaterialTimeStepPostprocessor::_use_elements_changed
const bool _use_elements_changed
Flag to limit the time step based on the number of elements changed.
Definition: MaterialTimeStepPostprocessor.h:45
MaterialTimeStepPostprocessor::_use_material_timestep_limit
const bool _use_material_timestep_limit
Flag to find the time step limit from material properties.
Definition: MaterialTimeStepPostprocessor.h:36
MaterialTimeStepPostprocessor::_elements_changed_threshold
const Real _elements_changed_threshold
Tolerance to determine if elements have changed.
Definition: MaterialTimeStepPostprocessor.h:59
MaterialTimeStepPostprocessor::_count
int _count
Current number of elements changed.
Definition: MaterialTimeStepPostprocessor.h:56
MaterialTimeStepPostprocessor::getValue
virtual Real getValue()
Definition: MaterialTimeStepPostprocessor.C:121
MaterialTimeStepPostprocessor
This postporocessor calculates an estimated timestep size that limits an auxiliary variable to below ...
Definition: MaterialTimeStepPostprocessor.h:23
validParams< MaterialTimeStepPostprocessor >
InputParameters validParams< MaterialTimeStepPostprocessor >()
MaterialTimeStepPostprocessor::MaterialTimeStepPostprocessor
MaterialTimeStepPostprocessor(const InputParameters &parameters)
Definition: MaterialTimeStepPostprocessor.C:58