nambu_m Module

This module defines the new data type 'nambu', which represents 4×4 complex matrices in spin and particle-hole space. It overloads arithmetic operators to work with the new type and exports relevant Pauli matrices as constants.


Uses


Interfaces

public interface inverse

  • private pure function nambu_inv(this) result(r)

    Calculates the inverse of the nambu matrix.

    Arguments

    Type IntentOptional Attributes Name
    class(nambu), intent(in) :: this

    Return Value type(nambu)

public interface trace

  • private elemental function nambu_trace(this) result(r)

    Calculates the trace of the nambu matrix.

    Arguments

    Type IntentOptional Attributes Name
    class(nambu), intent(in) :: this

    Return Value complex(kind=wp)

public interface sum

  • private pure function nambu_sum(this) result(r)

    Calculates the sum of an array of nambu matrices.

    Arguments

    Type IntentOptional Attributes Name
    class(nambu), intent(in) :: this(:)

    Return Value type(nambu)

public interface conjg

  • private elemental function nambu_conjg(this) result(r)

    Calculates the complex conjugate of the nambu matrix.

    Arguments

    Type IntentOptional Attributes Name
    class(nambu), intent(in) :: this

    Return Value type(nambu)

public interface nambuv

  • private pure function nambuv_scalar(n) result(r)

    Constructs basis matrix number n in spin-nambu space.

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: n

    Return Value type(nambu)

  • private pure function nambuv_vector(v) result(r)

    Constructs a matrix representation of a vector.

    Arguments

    Type IntentOptional Attributes Name
    real(kind=wp), intent(in), dimension(1:3) :: v

    Return Value type(nambu)


Derived Types

type, public ::  nambu

Components

Type Visibility Attributes Name Initial
complex(kind=wp), public :: matrix(4,4) = 0.0_wp

Type-Bound Procedures

generic, public :: nambu => cons_rscalar, cons_cscalar, cons_cmatrix, cons_nambu
generic, public :: assignment(=) => assr_rscalar, assr_cscalar, assr_cmatrix, assl_cmatrix
generic, public :: operator(+) => addl_rscalar, addr_rscalar, addl_cscalar, addr_cscalar, addl_cmatrix, addr_cmatrix, add_nambu
generic, public :: operator(-) => subl_rscalar, subr_rscalar, subl_cscalar, subr_cscalar, subl_cmatrix, subr_cmatrix, sub_nambu
generic, public :: operator(*) => mull_rscalar, mulr_rscalar, mull_cscalar, mulr_cscalar, mull_cmatrix, mulr_cmatrix, mul_nambu
generic, public :: operator(/) => divr_rscalar, divr_cscalar
generic, public :: operator(**) => expr_iscalar