https://mooseframework.inl.gov
MFEMCrossProductAux.h
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 
10 #ifdef MOOSE_MFEM_ENABLED
11 #pragma once
12 
13 #include "MFEMAuxKernel.h"
14 #include "mfem.hpp"
15 
24 {
25 public:
27 
29  ~MFEMCrossProductAux() override = default;
30 
31  void execute() override;
32 
33 protected:
35  const VariableName _u_var_name;
36  const VariableName _v_var_name;
37 
39  const mfem::ParGridFunction & _u_var;
40  const mfem::ParGridFunction & _v_var;
42  const mfem::real_t _scale_factor;
43 
45  mfem::VectorGridFunctionCoefficient _u_coef;
46  mfem::VectorGridFunctionCoefficient _v_coef;
47  mfem::VectorCrossProductCoefficient _cross_uv;
48  mfem::ConstantCoefficient _scale_c;
49 
51  mfem::ScalarVectorProductCoefficient _final_coef;
52 };
53 
54 #endif // MOOSE_MFEM_ENABLED
const VariableName _u_var_name
Names of vector sources.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
mfem::VectorCrossProductCoefficient _cross_uv
mfem::VectorGridFunctionCoefficient _v_coef
const mfem::real_t _scale_factor
Scaling factor applied on the resulting field.
mfem::ScalarVectorProductCoefficient _final_coef
Final coefficient that applies the scale factor to the crossproduct.
const mfem::ParGridFunction & _v_var
Class to construct an auxiliary solver used to update an auxvariable.
Definition: MFEMAuxKernel.h:20
Project s(x) * (U x V) onto a vector MFEM auxvariable.
void execute() override
Execute method.
mfem::VectorGridFunctionCoefficient _u_coef
Coefficient wrappers.
const mfem::ParGridFunction & _u_var
References to the vector ParGridFunctions.
~MFEMCrossProductAux() override=default
MFEMCrossProductAux(const InputParameters &parameters)
mfem::ConstantCoefficient _scale_c
static InputParameters validParams()
const VariableName _v_var_name