Line data Source code
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 : #include "QuotientAux.h" 11 : 12 : registerMooseObject("MooseApp", QuotientAux); 13 : 14 : InputParameters 15 14453 : QuotientAux::validParams() 16 : { 17 14453 : InputParameters params = AuxKernel::validParams(); 18 14453 : params.addClassDescription("Divides two coupled variables."); 19 14453 : params.addCoupledVar("numerator", "The upstairs of the quotient variable"); 20 14453 : params.addCoupledVar("denominator", "The downstairs of the quotient variable"); 21 14453 : return params; 22 0 : } 23 : 24 96 : QuotientAux::QuotientAux(const InputParameters & parameters) 25 : : AuxKernel(parameters), 26 96 : _numerator(coupledValue("numerator")), 27 192 : _denominator(coupledValue("denominator")) 28 : { 29 96 : } 30 : 31 : Real 32 1138796 : QuotientAux::computeValue() 33 : { 34 1138796 : return _numerator[_qp] / _denominator[_qp]; 35 : }