Module for Tensor operations in NAFPack
function that calculates the dot product of two real 3-dimensional vectors and
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | intent(in), | DIMENSION(:) | :: | a | ||
real(kind=dp), | intent(in), | DIMENSION(:) | :: | b |
function that calculates the cross product between two real 3-dimensional vectors and 1
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | DIMENSION(3) | :: | a | |||
real(kind=dp), | DIMENSION(3) | :: | b |
function that calculates the Euclidean norm (L2 norm) of a vector , where where is the dimension of the real vector .
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | DIMENSION(:) | :: | a |
function that calculates the Euclidean norm (L2 norm or modulus) of a vector , where where is the dimension of the complex vector .
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
complex(kind=dp), | DIMENSION(:) | :: | a |
function that normalises a real vector a to make it a unit vector, where
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | DIMENSION(:) | :: | a |
function that normalises a complex vector a to make it a unit vector, where
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
complex(kind=dp), | DIMENSION(:) | :: | a |
function that calculates the trace of a square matrix
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | intent(in), | DIMENSION(:, :) | :: | A |
function which checks if A is diagonally dominant
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | intent(in), | DIMENSION(:, :) | :: | A |
function that returns the identity matrix for a given size N
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer, | intent(in) | :: | N | |||
logical, | intent(in), | optional | :: | use_concurrent |
function that extracts the diagonal of a matrix where is a vector containing the diagonal elements of the matrix .
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | intent(in), | DIMENSION(:,:) | :: | A |
Function to create a rotation matrix
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | intent(in), | DIMENSION(:, :) | :: | A | ||
integer, | intent(in), | DIMENSION(2) | :: | rotation |