Toeplitz Derived Type

type, public :: Toeplitz

Base type to define a Toeplitz matrix of size [m x n]. The first column is given by the vector vc while the first row is given by vr.


Constructor

public interface Toeplitz

This interface provides methods to construct Toeplitz matrices. Given a vector vc specifying the first column of the matrix and a vector vr specifying its first row, the associated Toeplitz matrix is the following matrix

Syntax

   integer, parameter :: m = 100, n = 200
   real(dp) :: vc(n), vr(n)
   type(Toeplitz) :: A

   call random_number(vc) ; call random_number(vr)
   A = Toeplitz(vc, vr)

Warning

The element is read from the first entry of the vector vc. The first entry of vr is not referenced.

Note

Only double precision is currently supported for this matrix type.

  • private pure module function construct(vc, vr) result(A)

    Construct a Toeplitz matrix from the rank-1 arrays vc and vr.

    Arguments

    Type IntentOptional Attributes Name
    real(kind=dp), intent(in) :: vc(:)

    First column of the matrix.

    real(kind=dp), intent(in) :: vr(:)

    First row of the matrix.

    Return Value type(Toeplitz)

    Corresponding Toeplitz matrix.