https://mooseframework.inl.gov
Loading...
Searching...
No Matches
PiecewiseConstantVariable.C
Go to the documentation of this file.
1//* This file is part of the MOOSE framework
2//* https://mooseframework.inl.gov
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#include "NS.h"
12#include "NSFVUtils.h"
13
15
21
26
27bool
29 const Elem * const elem,
30 const Moose::StateArg & time) const
31{
32 if (isDirichletBoundaryFace(fi, elem, time))
33 return false;
34 if (!isInternalFace(fi))
35 return true;
36
37 return !MooseUtils::relativeFuzzyEqual((*this)(Moose::ElemArg{&fi.elem(), false}, time),
38 (*this)(Moose::ElemArg{fi.neighborPtr(), false}, time));
39}
registerMooseObject("NavierStokesApp", PiecewiseConstantVariable)
const Elem & elem() const
const Elem * neighborPtr() const
static InputParameters validParams()
virtual bool isDirichletBoundaryFace(const FaceInfo &fi, const Elem *elem, const Moose::StateArg &state) const
bool isInternalFace(const FaceInfo &) const
A special variable class for porosity which flags faces at which porosity jumps occur as extrapolated...
static InputParameters validParams()
PiecewiseConstantVariable(const InputParameters &params)
bool isExtrapolatedBoundaryFace(const FaceInfo &fi, const Elem *elem, const Moose::StateArg &time) const override