Real TensorMechanicsPlasticWeakPlaneTensileN::yieldFunction(const RankTwoTensor & stress, const Real & intnl) const { Real s22 = 0; for (unsigned i = 0 ; i < 3 ; ++i) for (unsigned j = 0 ; j < 3 ; ++j) s22 += _rot(2, i)*_rot(2, j)*stress(i, j); return s22 - tensile_strength(intnl); }
TensorMechanicsPlasticWeakPlaneTensileN::TensorMechanicsPlasticWeakPlaneTensileN(const InputParameters & parameters) : TensorMechanicsPlasticWeakPlaneTensile(parameters), _input_n(getParam<RealVectorValue>("normal_vector")), _df_dsig(RankTwoTensor()) { // cannot check the following for all values of strength, but this is a start if (_strength.value(0) < 0) mooseError("Weak plane tensile strength must not be negative"); if (_input_n.size() == 0) mooseError("Weak-plane normal vector must not have zero length"); else _input_n /= _input_n.size(); _rot = RotationMatrix::rotVecToZ(_input_n); for (unsigned i = 0 ; i < 3 ; ++i) for (unsigned j = 0 ; j < 3 ; ++j) _df_dsig(i, j) = _rot(2, i)*_rot(2, j); }
void IO_Memory__ChannelDesc_Fingerprint(IO_Memory__Channel ch, OOC_CHAR8 key[], OOC_LEN key_0d, OOC_INT32 start, OOC_INT32 end) { register OOC_INT32 i0,i1,i2,i3,i4,i5,i6; OOC_INT16 i; OOC_INT16 j; OOC_INT32 pos; OOC_CHAR8 byte; OOC_INT16 old; OOC_INT16 _new; i0=0; l1_loop: *(OOC_UINT8*)((OOC_INT32)key+(_check_index(i0, key_0d, OOC_UINT16, 3993))) = 0; i0 = i0+1; i1 = i0<=3; if (i1) goto l1_loop; l5: i = 0; j = 0; i0 = start; pos = i0; i1 = end; i2 = i0<i1; if (!i2) goto l17; i2 = (OOC_INT32)ch; i3=0;i4=0; l8_loop: i5 = (OOC_INT32)*(OOC_INT32*)((_check_pointer(i2, 4121))+16); i5 = _check_pointer(i5, 4127); i6 = OOC_ARRAY_LENGTH(i5, 0); i5 = *(OOC_UINT8*)(i5+(_check_index(i0, i6, OOC_UINT32, 4127))); i5 = _type_cast_fast(OOC_UINT8, OOC_UINT8, i5); byte = i5; i6 = *(OOC_UINT8*)((OOC_INT32)key+(_check_index(i3, key_0d, OOC_UINT16, 4174))); i6 = _type_cast_fast(OOC_UINT8, OOC_UINT8, i6); old = i6; i5 = _type_cast_fast(OOC_UINT8, OOC_UINT8, (_rot(OOC_UINT8, OOC_UINT8, i5, i4))); _new = i5; *(OOC_UINT8*)((OOC_INT32)key+(_check_index(i3, key_0d, OOC_UINT16, 4250))) = (_mod((i6+i5),256)); i3 = i3+1; i = i3; i5 = i3==4; if (!i5) goto l12; i3 = _mod((i4+1),8); j = i3; i = 0; i4=i3;i3=0; l12: i0 = i0+1; pos = i0; i5 = i0<i1; if (i5) goto l8_loop; l17: return; ; }