added _mul33xx33 double contraction: A_ij * B_ij = scalar
This commit is contained in:
parent
cb4b4afc88
commit
a8dfdc6487
|
@ -429,6 +429,26 @@ real(pReal), dimension(4,36), parameter :: math_symOperations = &
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
|
!**************************************************************************
|
||||||
|
! matrix multiplication 33x33 = 1 (double contraction --> ij * ij)
|
||||||
|
!**************************************************************************
|
||||||
|
pure function math_mul33xx33(A,B)
|
||||||
|
|
||||||
|
use prec, only: pReal, pInt
|
||||||
|
implicit none
|
||||||
|
|
||||||
|
integer(pInt) i,j
|
||||||
|
real(pReal), dimension(3,3), intent(in) :: A,B
|
||||||
|
real(pReal), dimension(3,3) :: C
|
||||||
|
real(pReal) math_mul33xx33
|
||||||
|
|
||||||
|
forall (i=1:3,j=1:3) C(i,j) = A(i,j) * B(i,j)
|
||||||
|
math_mul33xx33 = sum(C)
|
||||||
|
return
|
||||||
|
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
!**************************************************************************
|
!**************************************************************************
|
||||||
! matrix multiplication 33x33 = 3x3
|
! matrix multiplication 33x33 = 3x3
|
||||||
!**************************************************************************
|
!**************************************************************************
|
||||||
|
|
Loading…
Reference in New Issue