norm_2_complex Function

public function norm_2_complex(a) result(result)

function that calculates the Euclidean norm (L2 norm or modulus) of a vector , where where is the dimension of the complex vector .

Arguments

Type IntentOptional Attributes Name
complex(kind=dp), intent(in), dimension(:) :: a

Return Value real(kind=dp)


Called by

proc~~norm_2_complex~~CalledByGraph proc~norm_2_complex norm_2_complex proc~normalise_complexe normalise_complexe proc~normalise_complexe->proc~norm_2_complex

Source Code

    function norm_2_complex(a) result(result)

        complex(dp), dimension(:), intent(in) :: a
        real(dp) :: result

        result = sqrt(real(dot_product(a, conjg(a))))

    end function norm_2_complex