Mathematical library, including random number generation and tensor representations. More...
Data Types | |
interface | math_eye |
Functions/Subroutines | |
subroutine | math_init |
initialization of random seed generator and internal checks More... | |
recursive subroutine | math_sort (a, istart, iend, sortDim) |
Quicksort algorithm for two-dimensional integer arrays. More... | |
pure real(preal) function, dimension(sum(how)) | math_expand (what, how) |
vector expansion More... | |
pure integer function, dimension(n) | math_range (N) |
range of integers starting at one More... | |
pure real(preal) function, dimension(d, d) | math_identity2nd (d) |
second rank identity tensor of specified dimension More... | |
pure real(preal) function, dimension(d, d, d, d) | math_identity4th (d) |
symmetric fourth rank identity tensor of specified dimension More... | |
real(preal) pure function | math_levicivita (i, j, k) |
permutation tensor e_ijk More... | |
real(preal) pure function | math_delta (i, j) |
kronecker delta function d_ij More... | |
pure real(preal) function, dimension(3) | math_cross (A, B) |
cross product a x b More... | |
pure real(preal) function, dimension(size(a, 1), size(b, 1)) | math_outer (A, B) |
outer product of arbitrary sized vectors (A ⊗ B / i,j) More... | |
real(preal) pure function | math_inner (A, B) |
inner product of arbitrary sized vectors (A · B / i,i) More... | |
real(preal) pure function | math_tensordot (A, B) |
double contraction of 3x3 matrices (A : B / ij,ij) More... | |
pure real(preal) function, dimension(3, 3) | math_mul3333xx33 (A, B) |
matrix double contraction 3333x33 = 33 (ijkl,kl) More... | |
pure real(preal) function, dimension(3, 3, 3, 3) | math_mul3333xx3333 (A, B) |
matrix multiplication 3333x3333 = 3333 (ijkl,klmn) More... | |
pure real(preal) function, dimension(3, 3) | math_exp33 (A, n) |
3x3 matrix exponential up to series approximation order n (default 5) More... | |
pure real(preal) function, dimension(3, 3) | math_inv33 (A) |
Cramer inversion of 3x3 matrix (function) More... | |
pure subroutine | math_invert33 (InvA, DetA, error, A) |
Cramer inversion of 3x3 matrix (subroutine) More... | |
real(preal) function, dimension(3, 3, 3, 3) | math_invsym3333 (A) |
Inversion of symmetriced 3x3x3x3 matrix. More... | |
subroutine | math_invert (InvA, error, A) |
invert quadratic matrix of arbitrary dimension More... | |
pure real(preal) function, dimension(3, 3) | math_symmetric33 (m) |
symmetrize a 3x3 matrix More... | |
pure real(preal) function, dimension(6, 6) | math_symmetric66 (m) |
symmetrize a 6x6 matrix More... | |
pure real(preal) function, dimension(3, 3) | math_skew33 (m) |
skew part of a 3x3 matrix More... | |
pure real(preal) function, dimension(3, 3) | math_spherical33 (m) |
hydrostatic part of a 3x3 matrix More... | |
pure real(preal) function, dimension(3, 3) | math_deviatoric33 (m) |
deviatoric part of a 3x3 matrix More... | |
real(preal) pure function | math_trace33 (m) |
trace of a 3x3 matrix More... | |
real(preal) pure function | math_det33 (m) |
determinant of a 3x3 matrix More... | |
real(preal) pure function | math_detsym33 (m) |
determinant of a symmetric 3x3 matrix More... | |
pure real(preal) function, dimension(9) | math_33to9 (m33) |
convert 3x3 matrix into vector 9 More... | |
pure real(preal) function, dimension(3, 3) | math_9to33 (v9) |
convert 9 vector into 3x3 matrix More... | |
pure real(preal) function, dimension(6) | math_sym33to6 (m33, weighted) |
convert symmetric 3x3 matrix into 6 vector More... | |
pure real(preal) function, dimension(3, 3) | math_6tosym33 (v6, weighted) |
convert 6 vector into symmetric 3x3 matrix More... | |
pure real(preal) function, dimension(9, 9) | math_3333to99 (m3333) |
convert 3x3x3x3 matrix into 9x9 matrix More... | |
pure real(preal) function, dimension(3, 3, 3, 3) | math_99to3333 (m99) |
convert 9x9 matrix into 3x3x3x3 matrix More... | |
pure real(preal) function, dimension(6, 6) | math_sym3333to66 (m3333, weighted) |
convert symmetric 3x3x3x3 matrix into 6x6 matrix More... | |
pure real(preal) function, dimension(3, 3, 3, 3) | math_66tosym3333 (m66, weighted) |
convert 66 matrix into symmetric 3x3x3x3 matrix More... | |
pure real(preal) function, dimension(3, 3, 3, 3) | math_voigt66to3333 (m66) |
convert 66 Voigt matrix into symmetric 3x3x3x3 matrix More... | |
real(preal) function | math_samplegaussvar (meanvalue, stddev, width) |
draw a random sample from Gauss variable More... | |
subroutine | math_eigh (m, w, v, error) |
eigenvalues and eigenvectors of symmetric matrix More... | |
subroutine | math_eigh33 (m, w, v) |
eigenvalues and eigenvectors of symmetric 3x3 matrix using an analytical expression and the general LAPACK powered version for arbritrary sized matrices as fallback More... | |
real(preal) function, dimension(3, 3) | math_rotationalpart (m) |
rotational part from polar decomposition of 3x3 tensor More... | |
real(preal) function, dimension(size(m, 1)) | math_eigvalsh (m) |
Eigenvalues of symmetric matrix. More... | |
real(preal) function, dimension(3) | math_eigvalsh33 (m) |
eigenvalues of symmetric 3x3 matrix using an analytical expression More... | |
pure real(preal) function, dimension(3) | math_invariantssym33 (m) |
invariants of symmetrix 3x3 matrix More... | |
integer pure function | math_factorial (n) |
factorial More... | |
integer pure function | math_binomial (n, k) |
binomial coefficient More... | |
integer pure function | math_multinomial (alpha) |
multinomial coefficient More... | |
real(preal) pure function | math_voltetrahedron (v1, v2, v3, v4) |
volume of tetrahedron given by four vertices More... | |
real(preal) pure function | math_areatriangle (v1, v2, v3) |
area of triangle given by three vertices More... | |
real(preal) pure elemental function | math_clip (a, left, right) |
limits a scalar value to a certain range (either one or two sided) More... | |
subroutine, private | unittest |
check correctness of some math functions More... | |
Variables | |
real(preal), parameter | pi = acos(-1.0_pReal) |
ratio of a circle's circumference to its diameter More... | |
real(preal), parameter | indeg = 180.0_pReal/PI |
conversion from radian into degree More... | |
real(preal), parameter | inrad = PI/180.0_pReal |
conversion from degree into radian More... | |
complex(preal), parameter | twopiimg = cmplx(0.0_pReal, 2.0_pReal*PI) |
Re(0.0), Im(2xPi) More... | |
real(preal), dimension(3, 3), parameter | math_i3 = reshape([ 1.0_pReal,0.0_pReal,0.0_pReal, 0.0_pReal,1.0_pReal,0.0_pReal, 0.0_pReal,0.0_pReal,1.0_pReal ], [3,3]) |
3x3 Identity More... | |
real(preal), dimension(6), parameter, private | nrmmandel = [ 1.0_pReal, 1.0_pReal, 1.0_pReal, sqrt(2.0_pReal), sqrt(2.0_pReal), sqrt(2.0_pReal) ] |
forward weighting for Mandel notation More... | |
real(preal), dimension(6), parameter, private | invnrmmandel = 1.0_pReal/NRMMANDEL |
backward weighting for Mandel notation More... | |
integer, dimension(2, 6), parameter, private | mapnye = reshape([ 1,1, 2,2, 3,3, 1,2, 2,3, 1,3 ], [2,6]) |
arrangement in Nye notation. More... | |
integer, dimension(2, 6), parameter, private | mapvoigt = reshape([ 1,1, 2,2, 3,3, 2,3, 1,3, 1,2 ], [2,6]) |
arrangement in Voigt notation More... | |
integer, dimension(2, 9), parameter, private | mapplain = reshape([ 1,1, 1,2, 1,3, 2,1, 2,2, 2,3, 3,1, 3,2, 3,3 ], [2,9]) |
arrangement in Plain notation More... | |
Mathematical library, including random number generation and tensor representations.
pure real(preal) function, dimension(9,9) math::math_3333to99 | ( | real(preal), dimension(3,3,3,3), intent(in) | m3333 | ) |
convert 3x3x3x3 matrix into 9x9 matrix
Definition at line 3203 of file DAMASK_marc.f90.
References mapplain.
Referenced by crystallite_stresstangent(), integratestress(), and unittest().
pure real(preal) function, dimension(9) math::math_33to9 | ( | real(preal), dimension(3,3), intent(in) | m33 | ) |
convert 3x3 matrix into vector 9
Definition at line 3112 of file DAMASK_marc.f90.
References mapplain.
Referenced by integratestress(), and unittest().
pure real(preal) function, dimension(3,3,3,3) math::math_66tosym3333 | ( | real(preal), dimension(6,6), intent(in) | m66, |
logical, intent(in), optional | weighted | ||
) |
convert 66 matrix into symmetric 3x3x3x3 matrix
Weighted conversion (default) rearranges according to Nye and weights shear
[in] | m66 | 6x6 matrix |
[in] | weighted | weight according to Mandel (.true. by default) |
Definition at line 3268 of file DAMASK_marc.f90.
References invnrmmandel, and mapnye.
Referenced by constitutive::constitutive_hooke_sanditstangents(), cpfem_general(), math_invsym3333(), rotations::rottensor4sym(), and unittest().
pure real(preal) function, dimension(3,3) math::math_6tosym33 | ( | real(preal), dimension(6), intent(in) | v6, |
logical, intent(in), optional | weighted | ||
) |
convert 6 vector into symmetric 3x3 matrix
Weighted conversion (default) rearranges according to Nye and weights shear
[in] | v6 | 6 vector |
[in] | weighted | weight according to Mandel (.true. by default) |
Definition at line 3177 of file DAMASK_marc.f90.
References invnrmmandel, and mapnye.
Referenced by cpfem_general(), and unittest().
pure real(preal) function, dimension(3,3,3,3) math::math_99to3333 | ( | real(preal), dimension(9,9), intent(in) | m99 | ) |
convert 9x9 matrix into 3x3x3x3 matrix
Definition at line 3220 of file DAMASK_marc.f90.
References mapplain.
Referenced by crystallite_stresstangent(), and unittest().
pure real(preal) function, dimension(3,3) math::math_9to33 | ( | real(preal), dimension(9), intent(in) | v9 | ) |
convert 9 vector into 3x3 matrix
Definition at line 3129 of file DAMASK_marc.f90.
References mapplain.
Referenced by integratestress(), and unittest().
real(preal) pure function math::math_areatriangle | ( | real(preal), dimension (3), intent(in) | v1, |
real(preal), dimension (3), intent(in) | v2, | ||
real(preal), dimension (3), intent(in) | v3 | ||
) |
area of triangle given by three vertices
Definition at line 3646 of file DAMASK_marc.f90.
References math_cross().
Referenced by discretization_marc::ipvolume().
integer pure function math::math_binomial | ( | integer, intent(in) | n, |
integer, intent(in) | k | ||
) |
binomial coefficient
Definition at line 3594 of file DAMASK_marc.f90.
Referenced by math_multinomial(), and unittest().
real(preal) pure elemental function math::math_clip | ( | real(preal), intent(in) | a, |
real(preal), intent(in), optional | left, | ||
real(preal), intent(in), optional | right | ||
) |
limits a scalar value to a certain range (either one or two sided)
Definition at line 3659 of file DAMASK_marc.f90.
Referenced by eigenvectorbasis(), lambert::lambert_balltocube(), math_eigvalsh33(), rotations::om2ax(), rotations::qu2ax(), rotations::qu2ho(), rotations::qu2ro(), and unittest().
pure real(preal) function, dimension(3) math::math_cross | ( | real(preal), dimension(3), intent(in) | A, |
real(preal), dimension(3), intent(in) | B | ||
) |
cross product a x b
Definition at line 2774 of file DAMASK_marc.f90.
Referenced by lattice::buildcoordinatesystem(), lattice::buildtransformationsystem(), discretization_marc::ipareanormal(), discretization_marc::ipvolume(), lattice::lattice_nonschmidmatrix(), math_areatriangle(), math_eigh33(), and unittest().
real(preal) pure function math::math_delta | ( | integer, intent(in) | i, |
integer, intent(in) | j | ||
) |
kronecker delta function d_ij
Definition at line 2762 of file DAMASK_marc.f90.
Referenced by cpfem_general().
determinant of a 3x3 matrix
Definition at line 3085 of file DAMASK_marc.f90.
Referenced by constitutive::constitutive_lianditstangents(), cpfem_general(), crystallite_init(), rotations::frommatrix(), integratestress(), math_voltetrahedron(), and unittest().
determinant of a symmetric 3x3 matrix
Definition at line 3099 of file DAMASK_marc.f90.
Referenced by math_invariantssym33(), and unittest().
pure real(preal) function, dimension(3,3) math::math_deviatoric33 | ( | real(preal), dimension(3,3), intent(in) | m | ) |
deviatoric part of a 3x3 matrix
Definition at line 3060 of file DAMASK_marc.f90.
References math_spherical33().
subroutine math::math_eigh | ( | real(preal), dimension(:,:), intent(in) | m, |
real(preal), dimension(size(m,1)), intent(out) | w, | ||
real(preal), dimension(size(m,1),size(m,1)), intent(out) | v, | ||
logical, intent(out) | error | ||
) |
eigenvalues and eigenvectors of symmetric matrix
[in] | m | quadratic matrix to compute eigenvectors and values of |
[out] | w | eigenvalues |
[out] | v | eigenvectors |
Definition at line 3350 of file DAMASK_marc.f90.
Referenced by math_eigh33().
subroutine math::math_eigh33 | ( | real(preal), dimension(3,3), intent(in) | m, |
real(preal), dimension(3), intent(out) | w, | ||
real(preal), dimension(3,3), intent(out) | v | ||
) |
eigenvalues and eigenvectors of symmetric 3x3 matrix using an analytical expression and the general LAPACK powered version for arbritrary sized matrices as fallback
See http://arxiv.org/abs/physics/0610206 (DSYEVH3)
[in] | m | 3x3 matrix to compute eigenvectors and values of |
[out] | w | eigenvalues |
[out] | v | eigenvectors |
Definition at line 3377 of file DAMASK_marc.f90.
References math_cross(), math_eigh(), and math_eigvalsh33().
real(preal) function, dimension(size(m,1)) math::math_eigvalsh | ( | real(preal), dimension(:,:), intent(in) | m | ) |
Eigenvalues of symmetric matrix.
[in] | m | symmetric matrix to compute eigenvalues of |
Definition at line 3508 of file DAMASK_marc.f90.
Referenced by math_eigvalsh33().
real(preal) function, dimension(3) math::math_eigvalsh33 | ( | real(preal), dimension(3,3), intent(in) | m | ) |
eigenvalues of symmetric 3x3 matrix using an analytical expression
similar to http://arxiv.org/abs/physics/0610206 (DSYEVC3) but apparently more stable solution and has general LAPACK powered version for arbritrary sized matrices as fallback
[in] | m | 3x3 symmetric matrix to compute eigenvalues of |
Definition at line 3533 of file DAMASK_marc.f90.
References math_clip(), math_eigvalsh(), math_invariantssym33(), and pi.
Referenced by math_eigh33().
pure real(preal) function, dimension(3,3) math::math_exp33 | ( | real(preal), dimension(3,3), intent(in) | A, |
integer, intent(in), optional | n | ||
) |
3x3 matrix exponential up to series approximation order n (default 5)
Definition at line 2864 of file DAMASK_marc.f90.
References math_i3.
Referenced by unittest().
pure real(preal) function, dimension(sum(how)) math::math_expand | ( | real(preal), dimension(:), intent(in) | what, |
integer, dimension(:), intent(in) | how | ||
) |
vector expansion
takes a set of numbers (a,b,c,...) and corresponding multiples (x,y,z,...) to return a vector of x times a, y times b, z times c, ...
Definition at line 2669 of file DAMASK_marc.f90.
Referenced by kinematics_cleavage_opening::kinematics_cleavage_opening_init(), kinematics_slipplane_opening::kinematics_slipplane_opening_init(), source_damage_anisobrittle::source_damage_anisobrittle_init(), source_damage_anisoductile::source_damage_anisoductile_init(), and unittest().
integer pure function math::math_factorial | ( | integer, intent(in) | n | ) |
factorial
Definition at line 3582 of file DAMASK_marc.f90.
References math_range().
Referenced by unittest().
pure real(preal) function, dimension(d,d) math::math_identity2nd | ( | integer, intent(in) | d | ) |
second rank identity tensor of specified dimension
[in] | d | tensor dimension |
Definition at line 2702 of file DAMASK_marc.f90.
Referenced by cpfem_general(), crystallite_stresstangent(), integratestress(), math_identity4th(), and unittest().
pure real(preal) function, dimension(d,d,d,d) math::math_identity4th | ( | integer, intent(in) | d | ) |
symmetric fourth rank identity tensor of specified dimension
[in] | d | tensor dimension |
Definition at line 2720 of file DAMASK_marc.f90.
References math_identity2nd().
subroutine math::math_init |
initialization of random seed generator and internal checks
Definition at line 2557 of file DAMASK_marc.f90.
References numerics::randomseed, and prec::unittest().
Referenced by cpfem_initall().
real(preal) pure function math::math_inner | ( | real(preal), dimension(:), intent(in) | A, |
real(preal), dimension(size(a,1)), intent(in) | B | ||
) |
inner product of arbitrary sized vectors (A · B / i,i)
Definition at line 2805 of file DAMASK_marc.f90.
Referenced by lattice::slipprojection_direction(), and lattice::slipprojection_transverse().
pure real(preal) function, dimension(3,3) math::math_inv33 | ( | real(preal), dimension(3,3), intent(in) | A | ) |
Cramer inversion of 3x3 matrix (function)
Direct Cramer inversion of matrix A. Returns all zeroes if not possible, i.e.
Definition at line 2897 of file DAMASK_marc.f90.
References math_invert33().
Referenced by constitutive::constitutive_lianditstangents(), crystallite_init(), crystallite_push33toref(), crystallite_stress(), crystallite_stresstangent(), integratestress(), math_rotationalpart(), and unittest().
pure real(preal) function, dimension(3) math::math_invariantssym33 | ( | real(preal), dimension(3,3), intent(in) | m | ) |
invariants of symmetrix 3x3 matrix
Definition at line 3566 of file DAMASK_marc.f90.
References math_detsym33(), and math_trace33().
Referenced by eigenvectorbasis(), and math_eigvalsh33().
subroutine math::math_invert | ( | real(preal), dimension(size(a,1),size(a,1)), intent(out) | InvA, |
logical, intent(out) | error, | ||
real(preal), dimension(:,:), intent(in) | A | ||
) |
invert quadratic matrix of arbitrary dimension
Definition at line 2983 of file DAMASK_marc.f90.
Referenced by crystallite_stresstangent(), lattice::equivalent_mu(), lattice::equivalent_nu(), and unittest().
pure subroutine math::math_invert33 | ( | real(preal), dimension(3,3), intent(out) | InvA, |
real(preal), intent(out) | DetA, | ||
logical, intent(out) | error, | ||
real(preal), dimension(3,3), intent(in) | A | ||
) |
Cramer inversion of 3x3 matrix (subroutine)
Direct Cramer inversion of matrix A. Also returns determinant
Definition at line 2916 of file DAMASK_marc.f90.
Referenced by integratestress(), math_inv33(), and unittest().
real(preal) function, dimension(3,3,3,3) math::math_invsym3333 | ( | real(preal), dimension(3,3,3,3), intent(in) | A | ) |
Inversion of symmetriced 3x3x3x3 matrix.
Definition at line 2951 of file DAMASK_marc.f90.
References math_66tosym3333(), and math_sym3333to66().
real(preal) pure function math::math_levicivita | ( | integer, intent(in) | i, |
integer, intent(in) | j, | ||
integer, intent(in) | k | ||
) |
permutation tensor e_ijk
Definition at line 2742 of file DAMASK_marc.f90.
Referenced by unittest().
pure real(preal) function, dimension(3,3) math::math_mul3333xx33 | ( | real(preal), dimension(3,3,3,3), intent(in) | A, |
real(preal), dimension(3,3), intent(in) | B | ||
) |
matrix double contraction 3333x33 = 33 (ijkl,kl)
Definition at line 2830 of file DAMASK_marc.f90.
Referenced by constitutive::constitutive_hooke_sanditstangents().
pure real(preal) function, dimension(3,3,3,3) math::math_mul3333xx3333 | ( | real(preal), dimension(3,3,3,3), intent(in) | A, |
real(preal), dimension(3,3,3,3), intent(in) | B | ||
) |
matrix multiplication 3333x3333 = 3333 (ijkl,klmn)
Definition at line 2847 of file DAMASK_marc.f90.
Referenced by crystallite_stresstangent(), and integratestress().
integer pure function math::math_multinomial | ( | integer, dimension(:), intent(in) | alpha | ) |
multinomial coefficient
Definition at line 3613 of file DAMASK_marc.f90.
References math_binomial().
pure real(preal) function, dimension(size(a,1),size(b,1)) math::math_outer | ( | real(preal), dimension(:), intent(in) | A, |
real(preal), dimension(:), intent(in) | B | ||
) |
outer product of arbitrary sized vectors (A ⊗ B / i,j)
Definition at line 2789 of file DAMASK_marc.f90.
Referenced by lattice::buildtransformationsystem(), kinematics_slipplane_opening::kinematics_slipplane_opening_init(), lattice::lattice_nonschmidmatrix(), lattice::lattice_schmidmatrix_cleavage(), lattice::lattice_schmidmatrix_slip(), and lattice::lattice_schmidmatrix_twin().
pure integer function, dimension(n) math::math_range | ( | integer, intent(in) | N | ) |
range of integers starting at one
[in] | n | length of range |
Definition at line 2688 of file DAMASK_marc.f90.
Referenced by math_factorial(), and unittest().
real(preal) function, dimension(3,3) math::math_rotationalpart | ( | real(preal), dimension(3,3), intent(in) | m | ) |
rotational part from polar decomposition of 3x3 tensor
Definition at line 3424 of file DAMASK_marc.f90.
References eigenvectorbasis(), math_i3, and math_inv33().
Referenced by crystallite_orientations(), and unittest().
real(preal) function math::math_samplegaussvar | ( | real(preal), intent(in) | meanvalue, |
real(preal), intent(in) | stddev, | ||
real(preal), intent(in), optional | width | ||
) |
draw a random sample from Gauss variable
[in] | stddev | standard deviation of gauss distribution |
[in] | width | width of considered values as multiples of standard deviation |
meanvalue | meanvalue of gauss distribution |
Definition at line 3315 of file DAMASK_marc.f90.
pure real(preal) function, dimension(3,3) math::math_skew33 | ( | real(preal), dimension(3,3), intent(in) | m | ) |
skew part of a 3x3 matrix
Definition at line 3034 of file DAMASK_marc.f90.
References math_symmetric33().
recursive subroutine math::math_sort | ( | integer, dimension(:,:), intent(inout) | a, |
integer, intent(in), optional | istart, | ||
integer, intent(in), optional | iend, | ||
integer, intent(in), optional | sortDim | ||
) |
Quicksort algorithm for two-dimensional integer arrays.
Definition at line 2594 of file DAMASK_marc.f90.
References qsort_partition().
Referenced by discretization_marc::buildcells(), discretization_marc::inputread_mapelems(), discretization_marc::inputread_mapnodes(), and unittest().
pure real(preal) function, dimension(3,3) math::math_spherical33 | ( | real(preal), dimension(3,3), intent(in) | m | ) |
hydrostatic part of a 3x3 matrix
Definition at line 3047 of file DAMASK_marc.f90.
References math_i3, and math_trace33().
Referenced by math_deviatoric33().
pure real(preal) function, dimension(6,6) math::math_sym3333to66 | ( | real(preal), dimension(3,3,3,3), intent(in) | m3333, |
logical, intent(in), optional | weighted | ||
) |
convert symmetric 3x3x3x3 matrix into 6x6 matrix
Weighted conversion (default) rearranges according to Nye and weights shear
[in] | m3333 | symmetric 3x3x3x3 matrix (no internal check) |
[in] | weighted | weight according to Mandel (.true. by default) |
Definition at line 3240 of file DAMASK_marc.f90.
References mapnye, and nrmmandel.
Referenced by cpfem_general(), lattice::lattice_init(), math_invsym3333(), rotations::rottensor4sym(), and unittest().
pure real(preal) function, dimension(6) math::math_sym33to6 | ( | real(preal), dimension(3,3), intent(in) | m33, |
logical, intent(in), optional | weighted | ||
) |
convert symmetric 3x3 matrix into 6 vector
Weighted conversion (default) rearranges according to Nye and weights shear
[in] | m33 | symmetric 3x3 matrix (no internal check) |
[in] | weighted | weight according to Mandel (.true. by default) |
Definition at line 3149 of file DAMASK_marc.f90.
References mapnye, and nrmmandel.
Referenced by cpfem_general(), and unittest().
pure real(preal) function, dimension(3,3) math::math_symmetric33 | ( | real(preal), dimension(3,3), intent(in) | m | ) |
symmetrize a 3x3 matrix
Definition at line 3008 of file DAMASK_marc.f90.
Referenced by math_skew33(), and unittest().
pure real(preal) function, dimension(6,6) math::math_symmetric66 | ( | real(preal), dimension(6,6), intent(in) | m | ) |
symmetrize a 6x6 matrix
Definition at line 3021 of file DAMASK_marc.f90.
real(preal) pure function math::math_tensordot | ( | real(preal), dimension(3,3), intent(in) | A, |
real(preal), dimension(3,3), intent(in) | B | ||
) |
double contraction of 3x3 matrices (A : B / ij,ij)
Definition at line 2818 of file DAMASK_marc.f90.
trace of a 3x3 matrix
Definition at line 3073 of file DAMASK_marc.f90.
Referenced by lattice::lattice_schmidmatrix_slip(), lattice::lattice_schmidmatrix_twin(), math_invariantssym33(), math_spherical33(), and rotations::om2ax().
pure real(preal) function, dimension(3,3,3,3) math::math_voigt66to3333 | ( | real(preal), dimension(6,6), intent(in) | m66 | ) |
convert 66 Voigt matrix into symmetric 3x3x3x3 matrix
[in] | m66 | 6x6 matrix |
Definition at line 3296 of file DAMASK_marc.f90.
References mapvoigt.
Referenced by lattice::lattice_init().
real(preal) pure function math::math_voltetrahedron | ( | real(preal), dimension (3), intent(in) | v1, |
real(preal), dimension (3), intent(in) | v2, | ||
real(preal), dimension (3), intent(in) | v3, | ||
real(preal), dimension (3), intent(in) | v4 | ||
) |
volume of tetrahedron given by four vertices
Definition at line 3629 of file DAMASK_marc.f90.
References math_det33().
Referenced by discretization_marc::ipvolume(), and unittest().
|
private |
check correctness of some math functions
Definition at line 3676 of file DAMASK_marc.f90.
References math_3333to99(), math_33to9(), math_66tosym3333(), math_6tosym33(), math_99to3333(), math_9to33(), math_binomial(), math_clip(), math_cross(), math_det33(), math_detsym33(), math_exp33(), math_expand(), math_factorial(), math_i3, math_identity2nd(), math_inv33(), math_invert(), math_invert33(), math_levicivita(), math_range(), math_rotationalpart(), math_sort(), math_sym3333to66(), math_sym33to6(), math_symmetric33(), and math_voltetrahedron().
real(preal), parameter math::indeg = 180.0_pReal/PI |
conversion from radian into degree
Definition at line 2490 of file DAMASK_marc.f90.
real(preal), parameter math::inrad = PI/180.0_pReal |
conversion from degree into radian
Definition at line 2491 of file DAMASK_marc.f90.
Referenced by rotations::fromaxisangle(), and rotations::fromeulers().
|
private |
backward weighting for Mandel notation
Definition at line 2506 of file DAMASK_marc.f90.
Referenced by math_66tosym3333(), and math_6tosym33().
|
private |
arrangement in Nye notation.
Definition at line 2509 of file DAMASK_marc.f90.
Referenced by math_66tosym3333(), math_6tosym33(), math_sym3333to66(), and math_sym33to6().
|
private |
arrangement in Plain notation
Definition at line 2529 of file DAMASK_marc.f90.
Referenced by math_3333to99(), math_33to9(), math_99to3333(), and math_9to33().
|
private |
arrangement in Voigt notation
Definition at line 2519 of file DAMASK_marc.f90.
Referenced by math_voigt66to3333().
real(preal), dimension(3,3), parameter math::math_i3 = reshape([ 1.0_pReal,0.0_pReal,0.0_pReal, 0.0_pReal,1.0_pReal,0.0_pReal, 0.0_pReal,0.0_pReal,1.0_pReal ], [3,3]) |
3x3 Identity
Definition at line 2494 of file DAMASK_marc.f90.
Referenced by lattice::buildtransformationsystem(), constitutive::constitutive_hooke_sanditstangents(), constitutive::constitutive_initialfi(), constitutive::constitutive_lianditstangents(), crystallite_init(), eigenvectorbasis(), homogenization::homogenization_init(), integratestress(), math_exp33(), math_rotationalpart(), math_spherical33(), unittest(), rotations::unittest(), and lattice::unittest().
|
private |
forward weighting for Mandel notation
Definition at line 2501 of file DAMASK_marc.f90.
Referenced by math_sym3333to66(), and math_sym33to6().
real(preal), parameter math::pi = acos(-1.0_pReal) |
ratio of a circle's circumference to its diameter
Definition at line 2489 of file DAMASK_marc.f90.
Referenced by rotations::ax2ro(), eigenvectorbasis(), rotations::eu2ax(), rotations::eu2ro(), rotations::fromaxisangle(), rotations::fromeulers(), lambert::lambert_cubetoball(), lattice::lattice_c66_twin(), math_eigvalsh33(), rotations::om2eu(), rotations::qu2ax(), rotations::qu2eu(), rotations::ro2ax(), rotations::ro2ho(), and rotations::unittest().
complex(preal), parameter math::twopiimg = cmplx(0.0_pReal, 2.0_pReal*PI) |
Re(0.0), Im(2xPi)
Definition at line 2492 of file DAMASK_marc.f90.