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 "PFCTradMaterial.h" 11 : 12 : registerMooseObject("PhaseFieldApp", PFCTradMaterial); 13 : 14 : InputParameters 15 79 : PFCTradMaterial::validParams() 16 : { 17 79 : InputParameters params = Material::validParams(); 18 79 : params.addClassDescription( 19 : "Polynomial coefficients for a phase field crystal correlation function"); 20 158 : MooseEnum order("FOURTH=4 EIGHTH=8"); 21 158 : params.addRequiredParam<MooseEnum>( 22 : "order", order, "This is the order of the polynomial used for correlation function"); 23 79 : return params; 24 79 : } 25 : 26 60 : PFCTradMaterial::PFCTradMaterial(const InputParameters & parameters) 27 : : Material(parameters), 28 60 : _order(getParam<MooseEnum>("order")), 29 60 : _M(declareProperty<Real>("M")), 30 60 : _a(declareProperty<Real>("a")), 31 60 : _b(declareProperty<Real>("b")), 32 60 : _C0(declareProperty<Real>("C0")), 33 60 : _C2(declareProperty<Real>("C2")), 34 60 : _C4(declareProperty<Real>("C4")), 35 60 : _C6(declareProperty<Real>("C6")), 36 120 : _C8(declareProperty<Real>("C8")) 37 : { 38 60 : } 39 : 40 : void 41 953200 : PFCTradMaterial::computeQpProperties() 42 : { 43 : const Real invSkm = 0.332; 44 : const Real u_s = 0.72; 45 : 46 953200 : _M[_qp] = 1.0; 47 953200 : _a[_qp] = 3.0 / (2.0 * u_s) * invSkm; 48 953200 : _b[_qp] = 4.0 / (30.0 * u_s * u_s) * invSkm; 49 : 50 953200 : switch (_order) 51 : { 52 953200 : case 4: 53 953200 : _C0[_qp] = -10.9153; 54 953200 : _C2[_qp] = 2.6; // Angstrom^2 55 953200 : _C4[_qp] = 0.1459; // Angstrom^4, would be negative but coefficient term is negative 56 953200 : break; 57 : 58 0 : case 8: 59 0 : _C0[_qp] = -49.0; 60 : // new parameter derived from Jaatinen's paper; using km = 2.985 A; updated 1/31/2015. 61 0 : _C2[_qp] = 20.00313; // Angstrom^2 62 0 : _C4[_qp] = 3.11883; // Angstrom^4, would be negative but coefficient term is negative 63 0 : _C6[_qp] = 0.22554; // Angstrom^6 64 0 : _C8[_qp] = 0.00643; // Angstrom^8, would be negative but coefficient term is negative 65 0 : break; 66 : 67 0 : default: 68 0 : mooseError("Unknown order value."); 69 : } 70 953200 : }