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 : #pragma once 11 : 12 : #include "AuxKernel.h" 13 : #include "RankFourTensor.h" 14 : 15 : /** 16 : * RankFourAux is designed to take the data in the RankFourTensor material 17 : * property, for example stiffness, and output the value for the 18 : * supplied indices. 19 : */ 20 : template <bool is_ad> 21 : class RankFourAuxTempl : public AuxKernel 22 : { 23 : public: 24 : static InputParameters validParams(); 25 : 26 : RankFourAuxTempl(const InputParameters & parameters); 27 : 28 1080 : virtual ~RankFourAuxTempl() {} 29 : 30 : protected: 31 : virtual Real computeValue(); 32 : 33 : private: 34 : const GenericMaterialProperty<RankFourTensor, is_ad> & _tensor; 35 : const unsigned int _i; 36 : const unsigned int _j; 37 : const unsigned int _k; 38 : const unsigned int _l; 39 : }; 40 : 41 : typedef RankFourAuxTempl<false> RankFourAux; 42 : typedef RankFourAuxTempl<true> ADRankFourAux;