www.mooseframework.org
XFEMPhaseTransitionMovingInterfaceVelocity.C
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 
11 
13 
14 template <>
15 InputParameters
17 {
18  InputParameters params = validParams<XFEMMovingInterfaceVelocityBase>();
19  params.addRequiredParam<Real>("diffusivity_at_positive_level_set",
20  "Diffusivity for level set positive region.");
21  params.addRequiredParam<Real>("diffusivity_at_negative_level_set",
22  "Diffusivity for level set negative region.");
23  params.addRequiredParam<Real>("equilibrium_concentration_jump",
24  "The jump of the equilibrium concentration at the interface.");
25  params.addClassDescription(
26  "calculate the interface velocity for a simple phase transition problem.");
27  return params;
28 }
29 
31  const InputParameters & parameters)
32  : XFEMMovingInterfaceVelocityBase(parameters),
33  _diffusivity_at_positive_level_set(getParam<Real>("diffusivity_at_positive_level_set")),
34  _diffusivity_at_negative_level_set(getParam<Real>("diffusivity_at_negative_level_set")),
35  _equilibrium_concentration_jump(getParam<Real>("equilibrium_concentration_jump"))
36 {
37 }
38 
39 Real
41  unsigned int point_id) const
42 {
43  Real value_positive = _value_at_interface_uo->getValueAtPositiveLevelSet()[point_id];
44  Real value_negative = _value_at_interface_uo->getValueAtNegativeLevelSet()[point_id];
45  RealVectorValue grad_positive = _value_at_interface_uo->getGradientAtPositiveLevelSet()[point_id];
46  RealVectorValue grad_negative = _value_at_interface_uo->getGradientAtNegativeLevelSet()[point_id];
47 
48  // Current implementation only supports the case that the interface is moving horizontally
49  return std::abs((_diffusivity_at_positive_level_set * grad_positive(0) -
50  _diffusivity_at_negative_level_set * grad_negative(0)) /
51  (value_positive - value_negative + _equilibrium_concentration_jump));
52 }
XFEMPhaseTransitionMovingInterfaceVelocity::_diffusivity_at_negative_level_set
Real _diffusivity_at_negative_level_set
Diffusivity in the negative level set region.
Definition: XFEMPhaseTransitionMovingInterfaceVelocity.h:32
registerMooseObject
registerMooseObject("XFEMApp", XFEMPhaseTransitionMovingInterfaceVelocity)
XFEMMovingInterfaceVelocityBase
Definition: XFEMMovingInterfaceVelocityBase.h:20
PointValueAtXFEMInterface::getValueAtNegativeLevelSet
std::map< unsigned int, Real > getValueAtNegativeLevelSet() const
get the map that stores the point index and its values at the negative level set side
Definition: PointValueAtXFEMInterface.h:48
PointValueAtXFEMInterface::getGradientAtPositiveLevelSet
std::map< unsigned int, RealVectorValue > getGradientAtPositiveLevelSet() const
get the map that stores the point index and its gradient at the positive level set side
Definition: PointValueAtXFEMInterface.h:56
validParams< XFEMPhaseTransitionMovingInterfaceVelocity >
InputParameters validParams< XFEMPhaseTransitionMovingInterfaceVelocity >()
Definition: XFEMPhaseTransitionMovingInterfaceVelocity.C:16
PointValueAtXFEMInterface::getValueAtPositiveLevelSet
std::map< unsigned int, Real > getValueAtPositiveLevelSet() const
get the map that stores the point index and its values at the positive level set side
Definition: PointValueAtXFEMInterface.h:40
XFEMMovingInterfaceVelocityBase::_value_at_interface_uo
const PointValueAtXFEMInterface * _value_at_interface_uo
Pointer to PointValueAtXFEMInterface object.
Definition: XFEMMovingInterfaceVelocityBase.h:42
validParams< XFEMMovingInterfaceVelocityBase >
InputParameters validParams< XFEMMovingInterfaceVelocityBase >()
Definition: XFEMMovingInterfaceVelocityBase.C:14
XFEMPhaseTransitionMovingInterfaceVelocity
Definition: XFEMPhaseTransitionMovingInterfaceVelocity.h:19
XFEMPhaseTransitionMovingInterfaceVelocity::_diffusivity_at_positive_level_set
Real _diffusivity_at_positive_level_set
Diffusivity in the positive level set region.
Definition: XFEMPhaseTransitionMovingInterfaceVelocity.h:29
XFEMPhaseTransitionMovingInterfaceVelocity::XFEMPhaseTransitionMovingInterfaceVelocity
XFEMPhaseTransitionMovingInterfaceVelocity(const InputParameters &parameters)
Definition: XFEMPhaseTransitionMovingInterfaceVelocity.C:30
PointValueAtXFEMInterface::getGradientAtNegativeLevelSet
std::map< unsigned int, RealVectorValue > getGradientAtNegativeLevelSet() const
get the map that stores the point index and its graident at the negative level set side
Definition: PointValueAtXFEMInterface.h:64
XFEMPhaseTransitionMovingInterfaceVelocity::_equilibrium_concentration_jump
Real _equilibrium_concentration_jump
Jump of the equilibrium concentrations at phase boundary.
Definition: XFEMPhaseTransitionMovingInterfaceVelocity.h:35
XFEMPhaseTransitionMovingInterfaceVelocity.h
XFEMPhaseTransitionMovingInterfaceVelocity::computeMovingInterfaceVelocity
virtual Real computeMovingInterfaceVelocity(unsigned int point_id) const override
Compute the interface velocity for a point.
Definition: XFEMPhaseTransitionMovingInterfaceVelocity.C:40