MPSOps

Fortran module MPSOps: June 2017 (dj, updated)

Containing basic operations for matrix product states.

Authors

    1. Jaschke

      1. Wall

Details

The error status can be decoded the following way

The following subroutines / functions are defined for the applicable data type

Procedure

include.f90

mpi.f90

omp.f90

copy

X

canonize

X

canonize_svd

X

destroy

X

gaugesite_rq

X

gaugesite_qr

X

gaugesite_rsvd

X

gaugesite_lsvd

X

norm

X

orthonormalize

X

perturb

X

print

X

randomize

X

read

X

scale

X

write

X

MPSOps_f90.ConstructProjectors_tensor()[source]

fortran-subroutine - June 2017 (dj, updated) Given a set of NE MPSs psiBs and their overlap propagators with a variational state LRAB construct a set of at most NE on-site tensors psiProjs which can be used to project the effective Hamiltonian into the orthogonal space.

Arguments

kkINTEGER, in

Build the projectors for site kk in the single site version or for sites (kk, kk + 1) in the two site version.

PsibsTYPE(mps)(*), inout

??

LRABTYPE(tensorlist)(*), inout

The left-right overlaps.

PsiprojsTYPE(tensor)(*), POINTER, inout

On output, the projectors.

nsitesINTEGER, in

Number of sites to build the projectors on. Either single site (1) or two-sites (2).

Source Code

show / hide f90 code
MPSOps_f90.ConstructProjectors_tensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Given a set of NE MPSs psiBs and their overlap propagators with a variational state LRAB construct a set of at most NE on-site tensors psiProjs which can be used to project the effective Hamiltonian into the orthogonal space.

Arguments

kkINTEGER, in

Build the projectors for site kk in the single site version or for sites (kk, kk + 1) in the two site version.

PsibsTYPE(mpsc)(*), inout

??

LRABTYPE(tensorlistc)(*), inout

The left-right overlaps.

PsiprojsTYPE(tensorc)(*), POINTER, inout

On output, the projectors.

nsitesINTEGER, in

Number of sites to build the projectors on. Either single site (1) or two-sites (2).

Source Code

show / hide f90 code
MPSOps_f90.ConstructProjectors_qtensor()[source]

fortran-subroutine - June 2017 (dj, updated) Given a set of NE MPSs psiBs and their overlap propagators with a variational state LRAB construct a set of at most NE on-site tensors psiProjs which can be used to project the effective Hamiltonian into the orthogonal space.

Arguments

kkINTEGER, in

Build the projectors for site kk in the single site version or for sites (kk, kk + 1) in the two site version.

PsibsTYPE(qmps)(*), inout

??

LRABTYPE(qtensorlist)(*), inout

The left-right overlaps.

PsiprojsTYPE(qtensor)(*), POINTER, inout

On output, the projectors.

nsitesINTEGER, in

Number of sites to build the projectors on. Either single site (1) or two-sites (2).

Source Code

show / hide f90 code
MPSOps_f90.ConstructProjectors_qtensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Given a set of NE MPSs psiBs and their overlap propagators with a variational state LRAB construct a set of at most NE on-site tensors psiProjs which can be used to project the effective Hamiltonian into the orthogonal space.

Arguments

kkINTEGER, in

Build the projectors for site kk in the single site version or for sites (kk, kk + 1) in the two site version.

PsibsTYPE(qmpsc)(*), inout

??

LRABTYPE(qtensorclist)(*), inout

The left-right overlaps.

PsiprojsTYPE(qtensorc)(*), POINTER, inout

On output, the projectors.

nsitesINTEGER, in

Number of sites to build the projectors on. Either single site (1) or two-sites (2).

Source Code

show / hide f90 code
MPSOps_f90.copy_mps_mps()[source]

fortran-subroutine - June 2017 (dj, updated) Copy a Matrix Product State.

Arguments

PsiNewTYPE(mps), out

Copy a MPS into this variable

PsiOldTYPE(mps), in

Copy this MPS to PsiNew

scalarreal, OPTIONAL, in

Scale the MPS by a factor.

Source Code

show / hide f90 code
MPSOps_f90.copy_part_mps_mps()[source]

fortran-subroutine - November 2017 (dj, updated) Copy parts of an MPS. Orthogonality center has to be within the extracted part.

Arguments

PsiNewTYPE(mps), out

Copy a part of an MPS into this variable

PsiOldTYPE(mps), in

Copy part of this MPS to PsiNew

firstINTEGER, in

The first site of the old MPS to be copied.

lastINTEGER, in

The last site of the old MPS to be copied.

scalarreal, OPTIONAL, in

Scale the MPS by a factor.

Details

The copy of parts of an MPS only works on continuous number of sites. Sites 2, 3, 4 work. Sites 2, 4, 5 cannot be extracted with this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.copy_mpsc_mps()[source]

fortran-subroutine - June 2017 (dj, updated) Copy a Matrix Product State.

Arguments

PsiNewTYPE(mpsc), out

Copy a MPS into this variable

PsiOldTYPE(mps), in

Copy this MPS to PsiNew

scalarcomplex, OPTIONAL, in

Scale the MPS by a factor.

Source Code

show / hide f90 code
MPSOps_f90.copy_part_mpsc_mps()[source]

fortran-subroutine - November 2017 (dj, updated) Copy parts of an MPS. Orthogonality center has to be within the extracted part.

Arguments

PsiNewTYPE(mpsc), out

Copy a part of an MPS into this variable

PsiOldTYPE(mps), in

Copy part of this MPS to PsiNew

firstINTEGER, in

The first site of the old MPS to be copied.

lastINTEGER, in

The last site of the old MPS to be copied.

scalarcomplex, OPTIONAL, in

Scale the MPS by a factor.

Details

The copy of parts of an MPS only works on continuous number of sites. Sites 2, 3, 4 work. Sites 2, 4, 5 cannot be extracted with this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.copy_mpsc_mpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Copy a Matrix Product State.

Arguments

PsiNewTYPE(mpsc), out

Copy a MPS into this variable

PsiOldTYPE(mpsc), in

Copy this MPS to PsiNew

scalarcomplex, OPTIONAL, in

Scale the MPS by a factor.

Source Code

show / hide f90 code
MPSOps_f90.copy_part_mpsc_mpsc()[source]

fortran-subroutine - November 2017 (dj, updated) Copy parts of an MPS. Orthogonality center has to be within the extracted part.

Arguments

PsiNewTYPE(mpsc), out

Copy a part of an MPS into this variable

PsiOldTYPE(mpsc), in

Copy part of this MPS to PsiNew

firstINTEGER, in

The first site of the old MPS to be copied.

lastINTEGER, in

The last site of the old MPS to be copied.

scalarcomplex, OPTIONAL, in

Scale the MPS by a factor.

Details

The copy of parts of an MPS only works on continuous number of sites. Sites 2, 3, 4 work. Sites 2, 4, 5 cannot be extracted with this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.copy_qmps_qmps()[source]

fortran-subroutine - June 2017 (dj, updated) Copy a Matrix Product State.

Arguments

PsiNewTYPE(qmps), out

Copy a MPS into this variable

PsiOldTYPE(qmps), in

Copy this MPS to PsiNew

scalarreal, OPTIONAL, in

Scale the MPS by a factor.

Source Code

show / hide f90 code
MPSOps_f90.copy_part_qmps_qmps()[source]

fortran-subroutine - November 2017 (dj, updated) Copy parts of an MPS. Orthogonality center has to be within the extracted part.

Arguments

PsiNewTYPE(qmps), out

Copy a part of an MPS into this variable

PsiOldTYPE(qmps), in

Copy part of this MPS to PsiNew

firstINTEGER, in

The first site of the old MPS to be copied.

lastINTEGER, in

The last site of the old MPS to be copied.

scalarreal, OPTIONAL, in

Scale the MPS by a factor.

Details

The copy of parts of an MPS only works on continuous number of sites. Sites 2, 3, 4 work. Sites 2, 4, 5 cannot be extracted with this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.copy_qmpsc_qmps()[source]

fortran-subroutine - June 2017 (dj, updated) Copy a Matrix Product State.

Arguments

PsiNewTYPE(qmpsc), out

Copy a MPS into this variable

PsiOldTYPE(qmps), in

Copy this MPS to PsiNew

scalarcomplex, OPTIONAL, in

Scale the MPS by a factor.

Source Code

show / hide f90 code
MPSOps_f90.copy_part_qmpsc_qmps()[source]

fortran-subroutine - November 2017 (dj, updated) Copy parts of an MPS. Orthogonality center has to be within the extracted part.

Arguments

PsiNewTYPE(qmpsc), out

Copy a part of an MPS into this variable

PsiOldTYPE(qmps), in

Copy part of this MPS to PsiNew

firstINTEGER, in

The first site of the old MPS to be copied.

lastINTEGER, in

The last site of the old MPS to be copied.

scalarcomplex, OPTIONAL, in

Scale the MPS by a factor.

Details

The copy of parts of an MPS only works on continuous number of sites. Sites 2, 3, 4 work. Sites 2, 4, 5 cannot be extracted with this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.copy_qmpsc_qmpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Copy a Matrix Product State.

Arguments

PsiNewTYPE(qmpsc), out

Copy a MPS into this variable

PsiOldTYPE(qmpsc), in

Copy this MPS to PsiNew

scalarcomplex, OPTIONAL, in

Scale the MPS by a factor.

Source Code

show / hide f90 code
MPSOps_f90.copy_part_qmpsc_qmpsc()[source]

fortran-subroutine - November 2017 (dj, updated) Copy parts of an MPS. Orthogonality center has to be within the extracted part.

Arguments

PsiNewTYPE(qmpsc), out

Copy a part of an MPS into this variable

PsiOldTYPE(qmpsc), in

Copy part of this MPS to PsiNew

firstINTEGER, in

The first site of the old MPS to be copied.

lastINTEGER, in

The last site of the old MPS to be copied.

scalarcomplex, OPTIONAL, in

Scale the MPS by a factor.

Details

The copy of parts of an MPS only works on continuous number of sites. Sites 2, 3, 4 work. Sites 2, 4, 5 cannot be extracted with this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.canonize_mps()[source]

fortran-subroutine - June 2017 (dj, updated) Canonize the MPS with gauged matrices.

Arguments

PsiTYPE(mps), inout

Bring this MPS into a canonical form using QR decompositions.

k0INTEGER, in

This is the new orthogonality center for the MPS.

klINTEGER, OPTIONAL, in

This optional argument can provide the information where to start with gauging the MPS from the left side of the MPS. If not given, the maximum of the 1 and the present orthogonality center is choosen.

krINTEGER, OPTIONAL, in

This optional argument can provide the information where to start with gauging the MPS from the right side of the MPS. If not given, the minimum of the system size and the present orthogonality center is choosen.

Details

Put the MPS into the canonical form where all matrices to the left of k_0 (optionally down to k_l) are gauged according to the left-handed condition \sum_i A_i^T A_i=I and all matrices to the right of k_0 (optionally up to k_r) are gauged according to the right-handed condition \sum_i A_i A_i^T=I for OBC. This routine uses the QR decomposition - the fastest method - but it is not rank revealing and so inappropriate for compression. Additionally, the Schmidt coefficients are not returned and so entropies cannot be computed.

Source Code

show / hide f90 code
MPSOps_f90.canonize_svd_mps()[source]

fortran-subroutine - June 2017 (dj, updated) Put the MPS into a canonical form using SVD.

Arguments

PsiTYPE(mps), inout

MPS to be canonized with SVDs. Updated on exit.

k0INTEGER, in

The new orthogonality center on exit is at the site k0. All matrices to the left and right are gauged accordingly.

klINTEGER, OPTIONAL, in

start SVD from the left on this site. If not present SVD start at site 1 or the ortogonality center.

krINTEGER, OPTIONAL, in

start SVD from the right on this site. If not present, SVD starts on the last site or the orthogonality center.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Details

Put the MPS into the canonical form where all matrices to the left of k_0 (optionally down to k_l) are gauged according to the left-handed condition \sum_i A_i^T A_i=I and all matrices to the right of k_0 (optionally up to k_r) are gauged according to the right-handed condition \sum_i A_i A_i^T=I for OBC. This routine uses the SVD decomposition, which is rank revealing and so appropriate for compression. Additionally, the Schmidt coefficients are returned and so entropies can be computed.

Source Code

show / hide f90 code
MPSOps_f90.canonize_mpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Canonize the MPS with gauged matrices.

Arguments

PsiTYPE(mpsc), inout

Bring this MPS into a canonical form using QR decompositions.

k0INTEGER, in

This is the new orthogonality center for the MPS.

klINTEGER, OPTIONAL, in

This optional argument can provide the information where to start with gauging the MPS from the left side of the MPS. If not given, the maximum of the 1 and the present orthogonality center is choosen.

krINTEGER, OPTIONAL, in

This optional argument can provide the information where to start with gauging the MPS from the right side of the MPS. If not given, the minimum of the system size and the present orthogonality center is choosen.

Details

Put the MPS into the canonical form where all matrices to the left of k_0 (optionally down to k_l) are gauged according to the left-handed condition \sum_i A_i^T A_i=I and all matrices to the right of k_0 (optionally up to k_r) are gauged according to the right-handed condition \sum_i A_i A_i^T=I for OBC. This routine uses the QR decomposition - the fastest method - but it is not rank revealing and so inappropriate for compression. Additionally, the Schmidt coefficients are not returned and so entropies cannot be computed.

Source Code

show / hide f90 code
MPSOps_f90.canonize_svd_mpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Put the MPS into a canonical form using SVD.

Arguments

PsiTYPE(mpsc), inout

MPS to be canonized with SVDs. Updated on exit.

k0INTEGER, in

The new orthogonality center on exit is at the site k0. All matrices to the left and right are gauged accordingly.

klINTEGER, OPTIONAL, in

start SVD from the left on this site. If not present SVD start at site 1 or the ortogonality center.

krINTEGER, OPTIONAL, in

start SVD from the right on this site. If not present, SVD starts on the last site or the orthogonality center.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Details

Put the MPS into the canonical form where all matrices to the left of k_0 (optionally down to k_l) are gauged according to the left-handed condition \sum_i A_i^T A_i=I and all matrices to the right of k_0 (optionally up to k_r) are gauged according to the right-handed condition \sum_i A_i A_i^T=I for OBC. This routine uses the SVD decomposition, which is rank revealing and so appropriate for compression. Additionally, the Schmidt coefficients are returned and so entropies can be computed.

Source Code

show / hide f90 code
MPSOps_f90.canonize_qmps()[source]

fortran-subroutine - June 2017 (dj, updated) Canonize the MPS with gauged matrices.

Arguments

PsiTYPE(qmps), inout

Bring this MPS into a canonical form using QR decompositions.

k0INTEGER, in

This is the new orthogonality center for the MPS.

klINTEGER, OPTIONAL, in

This optional argument can provide the information where to start with gauging the MPS from the left side of the MPS. If not given, the maximum of the 1 and the present orthogonality center is choosen.

krINTEGER, OPTIONAL, in

This optional argument can provide the information where to start with gauging the MPS from the right side of the MPS. If not given, the minimum of the system size and the present orthogonality center is choosen.

Details

Put the MPS into the canonical form where all matrices to the left of k_0 (optionally down to k_l) are gauged according to the left-handed condition \sum_i A_i^T A_i=I and all matrices to the right of k_0 (optionally up to k_r) are gauged according to the right-handed condition \sum_i A_i A_i^T=I for OBC. This routine uses the QR decomposition - the fastest method - but it is not rank revealing and so inappropriate for compression. Additionally, the Schmidt coefficients are not returned and so entropies cannot be computed.

Source Code

show / hide f90 code
MPSOps_f90.canonize_svd_qmps()[source]

fortran-subroutine - June 2017 (dj, updated) Put the MPS into a canonical form using SVD.

Arguments

PsiTYPE(qmps), inout

MPS to be canonized with SVDs. Updated on exit.

k0INTEGER, in

The new orthogonality center on exit is at the site k0. All matrices to the left and right are gauged accordingly.

klINTEGER, OPTIONAL, in

start SVD from the left on this site. If not present SVD start at site 1 or the ortogonality center.

krINTEGER, OPTIONAL, in

start SVD from the right on this site. If not present, SVD starts on the last site or the orthogonality center.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Details

Put the MPS into the canonical form where all matrices to the left of k_0 (optionally down to k_l) are gauged according to the left-handed condition \sum_i A_i^T A_i=I and all matrices to the right of k_0 (optionally up to k_r) are gauged according to the right-handed condition \sum_i A_i A_i^T=I for OBC. This routine uses the SVD decomposition, which is rank revealing and so appropriate for compression. Additionally, the Schmidt coefficients are returned and so entropies can be computed.

Source Code

show / hide f90 code
MPSOps_f90.canonize_qmpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Canonize the MPS with gauged matrices.

Arguments

PsiTYPE(qmpsc), inout

Bring this MPS into a canonical form using QR decompositions.

k0INTEGER, in

This is the new orthogonality center for the MPS.

klINTEGER, OPTIONAL, in

This optional argument can provide the information where to start with gauging the MPS from the left side of the MPS. If not given, the maximum of the 1 and the present orthogonality center is choosen.

krINTEGER, OPTIONAL, in

This optional argument can provide the information where to start with gauging the MPS from the right side of the MPS. If not given, the minimum of the system size and the present orthogonality center is choosen.

Details

Put the MPS into the canonical form where all matrices to the left of k_0 (optionally down to k_l) are gauged according to the left-handed condition \sum_i A_i^T A_i=I and all matrices to the right of k_0 (optionally up to k_r) are gauged according to the right-handed condition \sum_i A_i A_i^T=I for OBC. This routine uses the QR decomposition - the fastest method - but it is not rank revealing and so inappropriate for compression. Additionally, the Schmidt coefficients are not returned and so entropies cannot be computed.

Source Code

show / hide f90 code
MPSOps_f90.canonize_svd_qmpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Put the MPS into a canonical form using SVD.

Arguments

PsiTYPE(qmpsc), inout

MPS to be canonized with SVDs. Updated on exit.

k0INTEGER, in

The new orthogonality center on exit is at the site k0. All matrices to the left and right are gauged accordingly.

klINTEGER, OPTIONAL, in

start SVD from the left on this site. If not present SVD start at site 1 or the ortogonality center.

krINTEGER, OPTIONAL, in

start SVD from the right on this site. If not present, SVD starts on the last site or the orthogonality center.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Details

Put the MPS into the canonical form where all matrices to the left of k_0 (optionally down to k_l) are gauged according to the left-handed condition \sum_i A_i^T A_i=I and all matrices to the right of k_0 (optionally up to k_r) are gauged according to the right-handed condition \sum_i A_i A_i^T=I for OBC. This routine uses the SVD decomposition, which is rank revealing and so appropriate for compression. Additionally, the Schmidt coefficients are returned and so entropies can be computed.

Source Code

show / hide f90 code
MPSOps_f90.check_mps()[source]

fortran-subroutine - August 2017 (dj) Run basic checks on MPS, such as left-right unitary and normed.

Arguments

PsiTYPE(mps), in

Run checks on this MPS.

Source Code

show / hide f90 code
MPSOps_f90.check_mpsc()[source]

fortran-subroutine - August 2017 (dj) Run basic checks on MPS, such as left-right unitary and normed.

Arguments

PsiTYPE(mpsc), in

Run checks on this MPS.

Source Code

show / hide f90 code
MPSOps_f90.check_qmps()[source]

fortran-subroutine - August 2017 (dj) Run basic checks on MPS, such as left-right unitary and normed.

Arguments

PsiTYPE(qmps), in

Run checks on this MPS.

Source Code

show / hide f90 code
MPSOps_f90.check_qmpsc()[source]

fortran-subroutine - August 2017 (dj) Run basic checks on MPS, such as left-right unitary and normed.

Arguments

PsiTYPE(qmpsc), in

Run checks on this MPS.

Source Code

show / hide f90 code
MPSOps_f90.destroy_mps()[source]

fortran-subroutine - June 2017 (dj, update) Deallocate the MPS representing the wave function.

Arguments

PsiTYPE(mps), inout

Deallocate MPS including all tensors and vectors contained in the structure.

Source Code

show / hide f90 code
MPSOps_f90.destroy_mpsc()[source]

fortran-subroutine - June 2017 (dj, update) Deallocate the MPS representing the wave function.

Arguments

PsiTYPE(mpsc), inout

Deallocate MPS including all tensors and vectors contained in the structure.

Source Code

show / hide f90 code
MPSOps_f90.destroy_qmps()[source]

fortran-subroutine - June 2017 (dj, update) Deallocate the MPS representing the wave function.

Arguments

PsiTYPE(qmps), inout

Deallocate MPS including all tensors and vectors contained in the structure.

Source Code

show / hide f90 code
MPSOps_f90.destroy_qmpsc()[source]

fortran-subroutine - June 2017 (dj, update) Deallocate the MPS representing the wave function.

Arguments

PsiTYPE(qmpsc), inout

Deallocate MPS including all tensors and vectors contained in the structure.

Source Code

show / hide f90 code
MPSOps_f90.distance_mps_mps()[source]

fortran-function - September 2017 (dj) Measure the distance between two MPSs.

Arguments

PsiATYPE(mps), inout

First quantum state to calculate a fidelity.

PsiBTYPE(mps), in

Second quantum state to calculate a fidelity.

dist_typeCHARACTER, OPTIONAL, in

Specify the distance to be calculated. Option are ‘F’ (fidelity) and ‘O’ (overlap, default).

Source Code

show / hide f90 code
MPSOps_f90.distance_mps_mpsc()[source]

fortran-function - September 2017 (dj) Measure the distance between two MPSs.

Arguments

PsiATYPE(mps), inout

First quantum state to calculate a fidelity.

PsiBTYPE(mpsc), in

Second quantum state to calculate a fidelity.

dist_typeCHARACTER, OPTIONAL, in

Specify the distance to be calculated. Option are ‘F’ (fidelity) and ‘O’ (overlap, default).

Source Code

show / hide f90 code
MPSOps_f90.distance_mpsc_mps()[source]

fortran-function - September 2017 (dj) Measure the distance between two MPSs.

Arguments

PsiATYPE(mpsc), inout

First quantum state to calculate a fidelity.

PsiBTYPE(mps), in

Second quantum state to calculate a fidelity.

dist_typeCHARACTER, OPTIONAL, in

Specify the distance to be calculated. Option are ‘F’ (fidelity) and ‘O’ (overlap, default).

Source Code

show / hide f90 code
MPSOps_f90.distance_mpsc_mpsc()[source]

fortran-function - September 2017 (dj) Measure the distance between two MPSs.

Arguments

PsiATYPE(mpsc), inout

First quantum state to calculate a fidelity.

PsiBTYPE(mpsc), in

Second quantum state to calculate a fidelity.

dist_typeCHARACTER, OPTIONAL, in

Specify the distance to be calculated. Option are ‘F’ (fidelity) and ‘O’ (overlap, default).

Source Code

show / hide f90 code
MPSOps_f90.distance_qmps_qmps()[source]

fortran-function - September 2017 (dj) Measure the distance between two MPSs.

Arguments

PsiATYPE(qmps), inout

First quantum state to calculate a fidelity.

PsiBTYPE(qmps), in

Second quantum state to calculate a fidelity.

dist_typeCHARACTER, OPTIONAL, in

Specify the distance to be calculated. Option are ‘F’ (fidelity) and ‘O’ (overlap, default).

Source Code

show / hide f90 code
MPSOps_f90.distance_qmps_qmpsc()[source]

fortran-function - September 2017 (dj) Measure the distance between two MPSs.

Arguments

PsiATYPE(qmps), inout

First quantum state to calculate a fidelity.

PsiBTYPE(qmpsc), in

Second quantum state to calculate a fidelity.

dist_typeCHARACTER, OPTIONAL, in

Specify the distance to be calculated. Option are ‘F’ (fidelity) and ‘O’ (overlap, default).

Source Code

show / hide f90 code
MPSOps_f90.distance_qmpsc_qmps()[source]

fortran-function - September 2017 (dj) Measure the distance between two MPSs.

Arguments

PsiATYPE(qmpsc), inout

First quantum state to calculate a fidelity.

PsiBTYPE(qmps), in

Second quantum state to calculate a fidelity.

dist_typeCHARACTER, OPTIONAL, in

Specify the distance to be calculated. Option are ‘F’ (fidelity) and ‘O’ (overlap, default).

Source Code

show / hide f90 code
MPSOps_f90.distance_qmpsc_qmpsc()[source]

fortran-function - September 2017 (dj) Measure the distance between two MPSs.

Arguments

PsiATYPE(qmpsc), inout

First quantum state to calculate a fidelity.

PsiBTYPE(qmpsc), in

Second quantum state to calculate a fidelity.

dist_typeCHARACTER, OPTIONAL, in

Specify the distance to be calculated. Option are ‘F’ (fidelity) and ‘O’ (overlap, default).

Source Code

show / hide f90 code
MPSOps_f90.dot_mps_mps()[source]

fortran-function - June 2017 (dj) Compute the fidelity / inner product <A,B> between two quantum states.

Arguments

PsiATYPE(mps), inout

First quantum state to calculate a fidelity.

PsiBTYPE(mps), in

Second quantum state to calculate a fidelity.

Source Code

show / hide f90 code
MPSOps_f90.dot_mps_mpsc()[source]

fortran-function - June 2017 (dj) Compute the fidelity / inner product <A,B> between two quantum states.

Arguments

PsiATYPE(mps), inout

First quantum state to calculate a fidelity.

PsiBTYPE(mpsc), in

Second quantum state to calculate a fidelity.

Source Code

show / hide f90 code
MPSOps_f90.dot_mpsc_mps()[source]

fortran-function - June 2017 (dj) Compute the fidelity / inner product <A,B> between two quantum states.

Arguments

PsiATYPE(mpsc), inout

First quantum state to calculate a fidelity.

PsiBTYPE(mps), in

Second quantum state to calculate a fidelity.

Source Code

show / hide f90 code
MPSOps_f90.dot_mpsc_mpsc()[source]

fortran-function - June 2017 (dj) Compute the fidelity / inner product <A,B> between two quantum states.

Arguments

PsiATYPE(mpsc), inout

First quantum state to calculate a fidelity.

PsiBTYPE(mpsc), in

Second quantum state to calculate a fidelity.

Source Code

show / hide f90 code
MPSOps_f90.dot_qmps_qmps()[source]

fortran-function - June 2017 (dj) Compute the fidelity / inner product <A,B> between two quantum states.

Arguments

PsiATYPE(qmps), inout

First quantum state to calculate a fidelity.

PsiBTYPE(qmps), in

Second quantum state to calculate a fidelity.

Source Code

show / hide f90 code
MPSOps_f90.dot_qmps_qmpsc()[source]

fortran-function - June 2017 (dj) Compute the fidelity / inner product <A,B> between two quantum states.

Arguments

PsiATYPE(qmps), inout

First quantum state to calculate a fidelity.

PsiBTYPE(qmpsc), in

Second quantum state to calculate a fidelity.

Source Code

show / hide f90 code
MPSOps_f90.dot_qmpsc_qmps()[source]

fortran-function - June 2017 (dj) Compute the fidelity / inner product <A,B> between two quantum states.

Arguments

PsiATYPE(qmpsc), inout

First quantum state to calculate a fidelity.

PsiBTYPE(qmps), in

Second quantum state to calculate a fidelity.

Source Code

show / hide f90 code
MPSOps_f90.dot_qmpsc_qmpsc()[source]

fortran-function - June 2017 (dj) Compute the fidelity / inner product <A,B> between two quantum states.

Arguments

PsiATYPE(qmpsc), inout

First quantum state to calculate a fidelity.

PsiBTYPE(qmpsc), in

Second quantum state to calculate a fidelity.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_qr_tensor()[source]

fortran-subroutine - June 2017 (dj, updated) Shift gauge for two tensor to the right with a QR-decomposition.

Arguments

TlTYPE(tensor), inout

Run QR decomposition on last index vs the other ones.

TrTYPE(tensor), inout

On exit, this tensor is the new orhtogonality center.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_rq_tensor()[source]

fortran-subroutine - June 2017 (dj, updated) Shift gauge for two tensors to the left with a RQ-decompistion.

Arguments

TlTYPE(tensor), inout

On exit, this tensor is the new orhtogonality center.

TrTYPE(tensor), inout

Run RQ decomposition on first index vs the other ones.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_qr_tensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Shift gauge for two tensor to the right with a QR-decomposition.

Arguments

TlTYPE(tensorc), inout

Run QR decomposition on last index vs the other ones.

TrTYPE(tensorc), inout

On exit, this tensor is the new orhtogonality center.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_rq_tensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Shift gauge for two tensors to the left with a RQ-decompistion.

Arguments

TlTYPE(tensorc), inout

On exit, this tensor is the new orhtogonality center.

TrTYPE(tensorc), inout

Run RQ decomposition on first index vs the other ones.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_qr_qtensor()[source]

fortran-subroutine - June 2017 (dj, updated) Shift gauge for two tensor to the right with a QR-decomposition.

Arguments

TlTYPE(qtensor), inout

Run QR decomposition on last index vs the other ones.

TrTYPE(qtensor), inout

On exit, this tensor is the new orhtogonality center.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_rq_qtensor()[source]

fortran-subroutine - June 2017 (dj, updated) Shift gauge for two tensors to the left with a RQ-decompistion.

Arguments

TlTYPE(qtensor), inout

On exit, this tensor is the new orhtogonality center.

TrTYPE(qtensor), inout

Run RQ decomposition on first index vs the other ones.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_qr_qtensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Shift gauge for two tensor to the right with a QR-decomposition.

Arguments

TlTYPE(qtensorc), inout

Run QR decomposition on last index vs the other ones.

TrTYPE(qtensorc), inout

On exit, this tensor is the new orhtogonality center.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_rq_qtensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Shift gauge for two tensors to the left with a RQ-decompistion.

Arguments

TlTYPE(qtensorc), inout

On exit, this tensor is the new orhtogonality center.

TrTYPE(qtensorc), inout

Run RQ decomposition on first index vs the other ones.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_rsvd_tensor()[source]

fortran-subroutine - June 2017 (dj, updated) Shift the gauge from the left site to the right running an SVD.

Arguments

TlTYPE(tensor), inout

SVD decompose this tensor between the last index and the other ones.

LambTYPE(tensor), inout

Contains the singular values on exit.

TrTYPE(tensor), inout

On exit, this tensor is the new orthogonality center.

haslambdaLOGICAL, inout

Flag if singular values are already allocated.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_lsvd_tensor()[source]

fortran-subroutine - June 2017 (dj, updated) Shift the gauge from the right site to the left running an SVD.

Arguments

TlTYPE(tensor), inout

This tensor will be the new orthogonality center on exit.

LambTYPE(tensor), inout

Contains the singular values on exit.

TrTYPE(tensor), inout

SVD decompose this tensor between the first index and the other ones.

haslambdaLOGICAL, inout

Flag if singular values are already allocated.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_rsvd_tensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Shift the gauge from the left site to the right running an SVD.

Arguments

TlTYPE(tensorc), inout

SVD decompose this tensor between the last index and the other ones.

LambTYPE(tensor), inout

Contains the singular values on exit.

TrTYPE(tensorc), inout

On exit, this tensor is the new orthogonality center.

haslambdaLOGICAL, inout

Flag if singular values are already allocated.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_lsvd_tensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Shift the gauge from the right site to the left running an SVD.

Arguments

TlTYPE(tensorc), inout

This tensor will be the new orthogonality center on exit.

LambTYPE(tensor), inout

Contains the singular values on exit.

TrTYPE(tensorc), inout

SVD decompose this tensor between the first index and the other ones.

haslambdaLOGICAL, inout

Flag if singular values are already allocated.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_rsvd_qtensor()[source]

fortran-subroutine - June 2017 (dj, updated) Shift the gauge from the left site to the right running an SVD.

Arguments

TlTYPE(qtensor), inout

SVD decompose this tensor between the last index and the other ones.

LambTYPE(qtensor), inout

Contains the singular values on exit.

TrTYPE(qtensor), inout

On exit, this tensor is the new orthogonality center.

haslambdaLOGICAL, inout

Flag if singular values are already allocated.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_lsvd_qtensor()[source]

fortran-subroutine - June 2017 (dj, updated) Shift the gauge from the right site to the left running an SVD.

Arguments

TlTYPE(qtensor), inout

This tensor will be the new orthogonality center on exit.

LambTYPE(qtensor), inout

Contains the singular values on exit.

TrTYPE(qtensor), inout

SVD decompose this tensor between the first index and the other ones.

haslambdaLOGICAL, inout

Flag if singular values are already allocated.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_rsvd_qtensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Shift the gauge from the left site to the right running an SVD.

Arguments

TlTYPE(qtensorc), inout

SVD decompose this tensor between the last index and the other ones.

LambTYPE(qtensor), inout

Contains the singular values on exit.

TrTYPE(qtensorc), inout

On exit, this tensor is the new orthogonality center.

haslambdaLOGICAL, inout

Flag if singular values are already allocated.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Source Code

show / hide f90 code
MPSOps_f90.gaugesite_lsvd_qtensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Shift the gauge from the right site to the left running an SVD.

Arguments

TlTYPE(qtensorc), inout

This tensor will be the new orthogonality center on exit.

LambTYPE(qtensor), inout

Contains the singular values on exit.

TrTYPE(qtensorc), inout

SVD decompose this tensor between the first index and the other ones.

haslambdaLOGICAL, inout

Flag if singular values are already allocated.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

Source Code

show / hide f90 code
MPSOps_f90.maxchi_mps()[source]

fortran-function - July 2017 (dj, updated) Get the maximal bond dimension of the MPS.

Arguments

PsiTYPE(mps), in

Get the maximal bond dimension present in the MPS

Source Code

show / hide f90 code
MPSOps_f90.maxchi_mpsc()[source]

fortran-function - July 2017 (dj, updated) Get the maximal bond dimension of the MPS.

Arguments

PsiTYPE(mpsc), in

Get the maximal bond dimension present in the MPS

Source Code

show / hide f90 code
MPSOps_f90.maxchi_qmps()[source]

fortran-function - July 2017 (dj, updated) Get the maximal bond dimension of the MPS.

Arguments

PsiTYPE(qmps), in

Get the maximal bond dimension present in the MPS

Source Code

show / hide f90 code
MPSOps_f90.maxchi_qmpsc()[source]

fortran-function - July 2017 (dj, updated) Get the maximal bond dimension of the MPS.

Arguments

PsiTYPE(qmpsc), in

Get the maximal bond dimension present in the MPS

Source Code

show / hide f90 code
MPSOps_f90.maxkappa_mps()[source]

fortran-function - September 2017 (dj) Get the maximal bond dimension to conjugate tensor of MPS. MPS is a pure state, therefore always 1.

Arguments

PsiTYPE(mps), in

Maximal bond dimension kappa is always 1 for a pure state.

Source Code

show / hide f90 code
MPSOps_f90.maxkappa_mpsc()[source]

fortran-function - September 2017 (dj) Get the maximal bond dimension to conjugate tensor of MPS. MPS is a pure state, therefore always 1.

Arguments

PsiTYPE(mpsc), in

Maximal bond dimension kappa is always 1 for a pure state.

Source Code

show / hide f90 code
MPSOps_f90.maxkappa_qmps()[source]

fortran-function - September 2017 (dj) Get the maximal bond dimension to conjugate tensor of MPS. MPS is a pure state, therefore always 1.

Arguments

PsiTYPE(qmps), in

Maximal bond dimension kappa is always 1 for a pure state.

Source Code

show / hide f90 code
MPSOps_f90.maxkappa_qmpsc()[source]

fortran-function - September 2017 (dj) Get the maximal bond dimension to conjugate tensor of MPS. MPS is a pure state, therefore always 1.

Arguments

PsiTYPE(qmpsc), in

Maximal bond dimension kappa is always 1 for a pure state.

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_tensor_tensor()[source]

fortran-subroutine - April 2016 (dj) Compute | \phi \rangle = H | \psi \rangle.

Arguments

PhiTYPE(FOURtensor), out

On exit it contains H | \psi \rangle.

LcTYPE(tensorlist), in

Contains the contraction of Psi with H left of the sites considered in this subroutine.

WlTYPE(tensor), in

The MPO-matrix for the left of the two sites.

WrTYPE(tensor), in

The MPO-matrix for the right of the two sites.

RcTYPE(tensorlist), in

Contains the contraction of Psi with H right of the sites considered in this subroutine.

PsilTYPE(tensor), in

Left site of the two sites considered in Psi.

PsirTYPE(tensor), in

Right site of the two sites considered in Psi.

Details

(template defined in MPSOps_include_transfer.f90)

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_tensor_tensorc()[source]

fortran-subroutine - April 2016 (dj) Compute | \phi \rangle = H | \psi \rangle.

Arguments

PhiTYPE(FOURtensorc), out

On exit it contains H | \psi \rangle.

LcTYPE(tensorlistc), in

Contains the contraction of Psi with H left of the sites considered in this subroutine.

WlTYPE(tensor), in

The MPO-matrix for the left of the two sites.

WrTYPE(tensor), in

The MPO-matrix for the right of the two sites.

RcTYPE(tensorlistc), in

Contains the contraction of Psi with H right of the sites considered in this subroutine.

PsilTYPE(tensorc), in

Left site of the two sites considered in Psi.

PsirTYPE(tensorc), in

Right site of the two sites considered in Psi.

Details

(template defined in MPSOps_include_transfer.f90)

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_tensorc_tensorc()[source]

fortran-subroutine - April 2016 (dj) Compute | \phi \rangle = H | \psi \rangle.

Arguments

PhiTYPE(FOURtensorc), out

On exit it contains H | \psi \rangle.

LcTYPE(tensorlistc), in

Contains the contraction of Psi with H left of the sites considered in this subroutine.

WlTYPE(tensorc), in

The MPO-matrix for the left of the two sites.

WrTYPE(tensorc), in

The MPO-matrix for the right of the two sites.

RcTYPE(tensorlistc), in

Contains the contraction of Psi with H right of the sites considered in this subroutine.

PsilTYPE(tensorc), in

Left site of the two sites considered in Psi.

PsirTYPE(tensorc), in

Right site of the two sites considered in Psi.

Details

(template defined in MPSOps_include_transfer.f90)

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_qtensor_qtensor()[source]

fortran-subroutine - April 2016 (dj) Compute | \phi \rangle = H | \psi \rangle.

Arguments

PhiTYPE(FOURqtensor), out

On exit it contains H | \psi \rangle.

LcTYPE(qtensorlist), in

Contains the contraction of Psi with H left of the sites considered in this subroutine.

WlTYPE(qtensor), in

The MPO-matrix for the left of the two sites.

WrTYPE(qtensor), in

The MPO-matrix for the right of the two sites.

RcTYPE(qtensorlist), in

Contains the contraction of Psi with H right of the sites considered in this subroutine.

PsilTYPE(qtensor), in

Left site of the two sites considered in Psi.

PsirTYPE(qtensor), in

Right site of the two sites considered in Psi.

Details

(template defined in MPSOps_include_transfer.f90)

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_qtensor_qtensorc()[source]

fortran-subroutine - April 2016 (dj) Compute | \phi \rangle = H | \psi \rangle.

Arguments

PhiTYPE(FOURqtensorc), out

On exit it contains H | \psi \rangle.

LcTYPE(qtensorclist), in

Contains the contraction of Psi with H left of the sites considered in this subroutine.

WlTYPE(qtensor), in

The MPO-matrix for the left of the two sites.

WrTYPE(qtensor), in

The MPO-matrix for the right of the two sites.

RcTYPE(qtensorclist), in

Contains the contraction of Psi with H right of the sites considered in this subroutine.

PsilTYPE(qtensorc), in

Left site of the two sites considered in Psi.

PsirTYPE(qtensorc), in

Right site of the two sites considered in Psi.

Details

(template defined in MPSOps_include_transfer.f90)

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_qtensorc_qtensorc()[source]

fortran-subroutine - April 2016 (dj) Compute | \phi \rangle = H | \psi \rangle.

Arguments

PhiTYPE(FOURqtensorc), out

On exit it contains H | \psi \rangle.

LcTYPE(qtensorclist), in

Contains the contraction of Psi with H left of the sites considered in this subroutine.

WlTYPE(qtensorc), in

The MPO-matrix for the left of the two sites.

WrTYPE(qtensorc), in

The MPO-matrix for the right of the two sites.

RcTYPE(qtensorclist), in

Contains the contraction of Psi with H right of the sites considered in this subroutine.

PsilTYPE(qtensorc), in

Left site of the two sites considered in Psi.

PsirTYPE(qtensorc), in

Right site of the two sites considered in Psi.

Details

(template defined in MPSOps_include_transfer.f90)

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_n_tensor_tensor()[source]

fortran-subroutine - June 2017 (dj) Contract local MPO amtrices for n-sites with wave function represented on n-sites and the left right overlap.

Details

Subroutine has both, a 1 site and a 2 site version.

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_n_tensor_tensorc()[source]

fortran-subroutine - June 2017 (dj) Contract local MPO amtrices for n-sites with wave function represented on n-sites and the left right overlap.

Details

Subroutine has both, a 1 site and a 2 site version.

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_n_tensorc_tensorc()[source]

fortran-subroutine - June 2017 (dj) Contract local MPO amtrices for n-sites with wave function represented on n-sites and the left right overlap.

Details

Subroutine has both, a 1 site and a 2 site version.

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_n_qtensor_qtensor()[source]

fortran-subroutine - June 2017 (dj) Contract local MPO amtrices for n-sites with wave function represented on n-sites and the left right overlap.

Details

Subroutine has both, a 1 site and a 2 site version.

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_n_qtensor_qtensorc()[source]

fortran-subroutine - June 2017 (dj) Contract local MPO amtrices for n-sites with wave function represented on n-sites and the left right overlap.

Details

Subroutine has both, a 1 site and a 2 site version.

Source Code

show / hide f90 code
MPSOps_f90.mpo_dot_psi_n_qtensorc_qtensorc()[source]

fortran-subroutine - June 2017 (dj) Contract local MPO amtrices for n-sites with wave function represented on n-sites and the left right overlap.

Details

Subroutine has both, a 1 site and a 2 site version.

Source Code

show / hide f90 code
MPSOps_f90.mpo2_dot_psi_tensor_tensor()[source]

fortran-subroutine - June 2017 (dj) Multiply two-site Hamiltonian with two-site Psi.

Arguments

HPsiTYPE(tensor), inout

Contraction of 2-site Hamiltonian with 2-site Psi.

HamTYPE(tensor), inout

Contains the two-site Hamiltonian as rank-4 tensor.

PsiTYPE(tensor), inout

Rank-4 tensor representing the two sites.

Details

This it the version building the two site Hamiltonian first. The default scaling is d^4 \kappa + \chi^2 d^4 and avoids any step building the actual MPO. In comparison, contracting the MPO matrices should result in a scaling of 2 \kappa \chi^2 d^3. For large local dimension it could be worth implementing the contraction based on MPO matrices. Moreover, the cost d^4 \kappa can be done beforehand and occurs only once for each Trotter step and site.

Source Code

show / hide f90 code
MPSOps_f90.mpo2_dot_psi_tensor_tensorc()[source]

fortran-subroutine - June 2017 (dj) Multiply two-site Hamiltonian with two-site Psi.

Arguments

HPsiTYPE(tensorc), inout

Contraction of 2-site Hamiltonian with 2-site Psi.

HamTYPE(tensor), inout

Contains the two-site Hamiltonian as rank-4 tensor.

PsiTYPE(tensorc), inout

Rank-4 tensor representing the two sites.

Details

This it the version building the two site Hamiltonian first. The default scaling is d^4 \kappa + \chi^2 d^4 and avoids any step building the actual MPO. In comparison, contracting the MPO matrices should result in a scaling of 2 \kappa \chi^2 d^3. For large local dimension it could be worth implementing the contraction based on MPO matrices. Moreover, the cost d^4 \kappa can be done beforehand and occurs only once for each Trotter step and site.

Source Code

show / hide f90 code
MPSOps_f90.mpo2_dot_psi_tensorc_tensorc()[source]

fortran-subroutine - June 2017 (dj) Multiply two-site Hamiltonian with two-site Psi.

Arguments

HPsiTYPE(tensorc), inout

Contraction of 2-site Hamiltonian with 2-site Psi.

HamTYPE(tensorc), inout

Contains the two-site Hamiltonian as rank-4 tensor.

PsiTYPE(tensorc), inout

Rank-4 tensor representing the two sites.

Details

This it the version building the two site Hamiltonian first. The default scaling is d^4 \kappa + \chi^2 d^4 and avoids any step building the actual MPO. In comparison, contracting the MPO matrices should result in a scaling of 2 \kappa \chi^2 d^3. For large local dimension it could be worth implementing the contraction based on MPO matrices. Moreover, the cost d^4 \kappa can be done beforehand and occurs only once for each Trotter step and site.

Source Code

show / hide f90 code
MPSOps_f90.mpo2_dot_psi_qtensor_qtensor()[source]

fortran-subroutine - June 2017 (dj) Multiply two-site Hamiltonian with two-site Psi.

Arguments

HPsiTYPE(qtensor), inout

Contraction of 2-site Hamiltonian with 2-site Psi.

HamTYPE(qtensor), inout

Contains the two-site Hamiltonian as rank-4 tensor.

PsiTYPE(qtensor), inout

Rank-4 tensor representing the two sites.

Details

This it the version building the two site Hamiltonian first. The default scaling is d^4 \kappa + \chi^2 d^4 and avoids any step building the actual MPO. In comparison, contracting the MPO matrices should result in a scaling of 2 \kappa \chi^2 d^3. For large local dimension it could be worth implementing the contraction based on MPO matrices. Moreover, the cost d^4 \kappa can be done beforehand and occurs only once for each Trotter step and site.

Source Code

show / hide f90 code
MPSOps_f90.mpo2_dot_psi_qtensor_qtensorc()[source]

fortran-subroutine - June 2017 (dj) Multiply two-site Hamiltonian with two-site Psi.

Arguments

HPsiTYPE(qtensorc), inout

Contraction of 2-site Hamiltonian with 2-site Psi.

HamTYPE(qtensor), inout

Contains the two-site Hamiltonian as rank-4 tensor.

PsiTYPE(qtensorc), inout

Rank-4 tensor representing the two sites.

Details

This it the version building the two site Hamiltonian first. The default scaling is d^4 \kappa + \chi^2 d^4 and avoids any step building the actual MPO. In comparison, contracting the MPO matrices should result in a scaling of 2 \kappa \chi^2 d^3. For large local dimension it could be worth implementing the contraction based on MPO matrices. Moreover, the cost d^4 \kappa can be done beforehand and occurs only once for each Trotter step and site.

Source Code

show / hide f90 code
MPSOps_f90.mpo2_dot_psi_qtensorc_qtensorc()[source]

fortran-subroutine - June 2017 (dj) Multiply two-site Hamiltonian with two-site Psi.

Arguments

HPsiTYPE(qtensorc), inout

Contraction of 2-site Hamiltonian with 2-site Psi.

HamTYPE(qtensorc), inout

Contains the two-site Hamiltonian as rank-4 tensor.

PsiTYPE(qtensorc), inout

Rank-4 tensor representing the two sites.

Details

This it the version building the two site Hamiltonian first. The default scaling is d^4 \kappa + \chi^2 d^4 and avoids any step building the actual MPO. In comparison, contracting the MPO matrices should result in a scaling of 2 \kappa \chi^2 d^3. For large local dimension it could be worth implementing the contraction based on MPO matrices. Moreover, the cost d^4 \kappa can be done beforehand and occurs only once for each Trotter step and site.

Source Code

show / hide f90 code
MPSOps_f90.norm_mps()[source]

fortran-function - June 2017 (dj, updated) Compute the norm of Psi, assumed to have an orthogonality center.

Arguments

PsiTYPE(mps), inout

Compute the norm of this MPS with orthogonality center. If no orthogonality is installed, subroutine will crash accessing element -1)

Source Code

show / hide f90 code
MPSOps_f90.norm_mpsc()[source]

fortran-function - June 2017 (dj, updated) Compute the norm of Psi, assumed to have an orthogonality center.

Arguments

PsiTYPE(mpsc), inout

Compute the norm of this MPS with orthogonality center. If no orthogonality is installed, subroutine will crash accessing element -1)

Source Code

show / hide f90 code
MPSOps_f90.norm_qmps()[source]

fortran-function - June 2017 (dj, updated) Compute the norm of Psi, assumed to have an orthogonality center.

Arguments

PsiTYPE(qmps), inout

Compute the norm of this MPS with orthogonality center. If no orthogonality is installed, subroutine will crash accessing element -1)

Source Code

show / hide f90 code
MPSOps_f90.norm_qmpsc()[source]

fortran-function - June 2017 (dj, updated) Compute the norm of Psi, assumed to have an orthogonality center.

Arguments

PsiTYPE(qmpsc), inout

Compute the norm of this MPS with orthogonality center. If no orthogonality is installed, subroutine will crash accessing element -1)

Source Code

show / hide f90 code
MPSOps_f90.orthonormalize_mps()[source]

fortran-subroutine - June 2017 (dj, updated) Put psi into mixed canonical form at site k0 and normalize it.

Arguments

PsiTYPE(mps), inout

Gauge this MPS with QR, get the norm and rescale it such that it has trace 1.

k0INTEGER, in

The new orthogonality center on exit is at the site k0. All matrices to the left and right are gauged accordingly.

klINTEGER, OPTIONAL, in

start SVD from the left on this site. If not present SVD start at site 1 or the ortogonality center.

krINTEGER, OPTIONAL, in

start SVD from the right on this site. If not present, SVD starts on the last site or the orthogonality center.

Source Code

show / hide f90 code
MPSOps_f90.orthonormalize_mpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Put psi into mixed canonical form at site k0 and normalize it.

Arguments

PsiTYPE(mpsc), inout

Gauge this MPS with QR, get the norm and rescale it such that it has trace 1.

k0INTEGER, in

The new orthogonality center on exit is at the site k0. All matrices to the left and right are gauged accordingly.

klINTEGER, OPTIONAL, in

start SVD from the left on this site. If not present SVD start at site 1 or the ortogonality center.

krINTEGER, OPTIONAL, in

start SVD from the right on this site. If not present, SVD starts on the last site or the orthogonality center.

Source Code

show / hide f90 code
MPSOps_f90.orthonormalize_qmps()[source]

fortran-subroutine - June 2017 (dj, updated) Put psi into mixed canonical form at site k0 and normalize it.

Arguments

PsiTYPE(qmps), inout

Gauge this MPS with QR, get the norm and rescale it such that it has trace 1.

k0INTEGER, in

The new orthogonality center on exit is at the site k0. All matrices to the left and right are gauged accordingly.

klINTEGER, OPTIONAL, in

start SVD from the left on this site. If not present SVD start at site 1 or the ortogonality center.

krINTEGER, OPTIONAL, in

start SVD from the right on this site. If not present, SVD starts on the last site or the orthogonality center.

Source Code

show / hide f90 code
MPSOps_f90.orthonormalize_qmpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Put psi into mixed canonical form at site k0 and normalize it.

Arguments

PsiTYPE(qmpsc), inout

Gauge this MPS with QR, get the norm and rescale it such that it has trace 1.

k0INTEGER, in

The new orthogonality center on exit is at the site k0. All matrices to the left and right are gauged accordingly.

klINTEGER, OPTIONAL, in

start SVD from the left on this site. If not present SVD start at site 1 or the ortogonality center.

krINTEGER, OPTIONAL, in

start SVD from the right on this site. If not present, SVD starts on the last site or the orthogonality center.

Source Code

show / hide f90 code
MPSOps_f90.perturb_mps()[source]

fortran-subroutine - December 2018 (dj) Perturbate a MPS via a perturbation of each entry of each tensor.

Arguments

PsiTYPE(mps), inout

MPS to be perturbed.

epsilonreal, OPTIONAL, in

Scale a randomized tensor by epsilon and add to original tensor. Default to 1e-8

reorthLOGICAL, in

Re-orhtogonalize to the original oc center if true, otherwise, skip canonization. Default to no orthogonalization.

Source Code

show / hide f90 code
MPSOps_f90.perturb_mpsc()[source]

fortran-subroutine - December 2018 (dj) Perturbate a MPS via a perturbation of each entry of each tensor.

Arguments

PsiTYPE(mpsc), inout

MPS to be perturbed.

epsilonreal, OPTIONAL, in

Scale a randomized tensor by epsilon and add to original tensor. Default to 1e-8

reorthLOGICAL, in

Re-orhtogonalize to the original oc center if true, otherwise, skip canonization. Default to no orthogonalization.

Source Code

show / hide f90 code
MPSOps_f90.perturb_qmps()[source]

fortran-subroutine - December 2018 (dj) Perturbate a MPS via a perturbation of each entry of each tensor.

Arguments

PsiTYPE(qmps), inout

MPS to be perturbed.

epsilonreal, OPTIONAL, in

Scale a randomized tensor by epsilon and add to original tensor. Default to 1e-8

reorthLOGICAL, in

Re-orhtogonalize to the original oc center if true, otherwise, skip canonization. Default to no orthogonalization.

Source Code

show / hide f90 code
MPSOps_f90.perturb_qmpsc()[source]

fortran-subroutine - December 2018 (dj) Perturbate a MPS via a perturbation of each entry of each tensor.

Arguments

PsiTYPE(qmpsc), inout

MPS to be perturbed.

epsilonreal, OPTIONAL, in

Scale a randomized tensor by epsilon and add to original tensor. Default to 1e-8

reorthLOGICAL, in

Re-orhtogonalize to the original oc center if true, otherwise, skip canonization. Default to no orthogonalization.

Source Code

show / hide f90 code
MPSOps_f90.print_mps()[source]

fortran-subroutine - June 2016 (dj, updated) Write out all MPS data.

Arguments

PsiTYPE(mps), in

Print all information about the MPS.

Details

The information is written to the standard output with the following formatting: 1) infostring, Size of MPS, orthogonality center (both integers) In a loop for each site is written 2) infostring, number of the site (integer) 3) infostring, canonization (character) 4) infostring, haslambda (logical) 5) Depending on logical haslambda, lambda is printed with according function. 6) Tensor is printed with according function.

Source Code

show / hide f90 code
MPSOps_f90.print_mpsc()[source]

fortran-subroutine - June 2016 (dj, updated) Write out all MPS data.

Arguments

PsiTYPE(mpsc), in

Print all information about the MPS.

Details

The information is written to the standard output with the following formatting: 1) infostring, Size of MPS, orthogonality center (both integers) In a loop for each site is written 2) infostring, number of the site (integer) 3) infostring, canonization (character) 4) infostring, haslambda (logical) 5) Depending on logical haslambda, lambda is printed with according function. 6) Tensor is printed with according function.

Source Code

show / hide f90 code
MPSOps_f90.print_qmps()[source]

fortran-subroutine - June 2016 (dj, updated) Write out all MPS data.

Arguments

PsiTYPE(qmps), in

Print all information about the MPS.

Details

The information is written to the standard output with the following formatting: 1) infostring, Size of MPS, orthogonality center (both integers) In a loop for each site is written 2) infostring, number of the site (integer) 3) infostring, canonization (character) 4) infostring, haslambda (logical) 5) Depending on logical haslambda, lambda is printed with according function. 6) Tensor is printed with according function.

Source Code

show / hide f90 code
MPSOps_f90.print_qmpsc()[source]

fortran-subroutine - June 2016 (dj, updated) Write out all MPS data.

Arguments

PsiTYPE(qmpsc), in

Print all information about the MPS.

Details

The information is written to the standard output with the following formatting: 1) infostring, Size of MPS, orthogonality center (both integers) In a loop for each site is written 2) infostring, number of the site (integer) 3) infostring, canonization (character) 4) infostring, haslambda (logical) 5) Depending on logical haslambda, lambda is printed with according function. 6) Tensor is printed with according function.

Source Code

show / hide f90 code
MPSOps_f90.projected_mpo_dot_psi_n_tensor_tensor()[source]

fortran-subroutine - July 2017 (dj, updated) Compute the projection of Phi = H * psi, where H=L.W.R

Details

Since we need the projectors from the two site tensor, the two site algorithm is implemented.

Source Code

show / hide f90 code
MPSOps_f90.projected_mpo_dot_psi_n_tensor_tensorc()[source]

fortran-subroutine - July 2017 (dj, updated) Compute the projection of Phi = H * psi, where H=L.W.R

Details

Since we need the projectors from the two site tensor, the two site algorithm is implemented.

Source Code

show / hide f90 code
MPSOps_f90.projected_mpo_dot_psi_n_tensorc_tensorc()[source]

fortran-subroutine - July 2017 (dj, updated) Compute the projection of Phi = H * psi, where H=L.W.R

Details

Since we need the projectors from the two site tensor, the two site algorithm is implemented.

Source Code

show / hide f90 code
MPSOps_f90.projected_mpo_dot_psi_n_qtensor_qtensor()[source]

fortran-subroutine - July 2017 (dj, updated) Compute the projection of Phi = H * psi, where H=L.W.R

Details

Since we need the projectors from the two site tensor, the two site algorithm is implemented.

Source Code

show / hide f90 code
MPSOps_f90.projected_mpo_dot_psi_n_qtensor_qtensorc()[source]

fortran-subroutine - July 2017 (dj, updated) Compute the projection of Phi = H * psi, where H=L.W.R

Details

Since we need the projectors from the two site tensor, the two site algorithm is implemented.

Source Code

show / hide f90 code
MPSOps_f90.projected_mpo_dot_psi_n_qtensorc_qtensorc()[source]

fortran-subroutine - July 2017 (dj, updated) Compute the projection of Phi = H * psi, where H=L.W.R

Details

Since we need the projectors from the two site tensor, the two site algorithm is implemented.

Source Code

show / hide f90 code
MPSOps_f90.ptm_left_state_tensor()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the right to the left. This version is for states.

Arguments

MatTYPE(tensor), inout

This is the transfer matrix right of Bra and Ket.

BraTYPE(tensor), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(tensor), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

rightmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(tensor), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{k,l} = \sum_{i,j,m} Mat_{i,j} Ket_{k,m,i} (Bra_{l,m,j})^{\ast}. This is executed in two steps. This is the leftmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_left_state_tensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the right to the left. This version is for states.

Arguments

MatTYPE(tensorc), inout

This is the transfer matrix right of Bra and Ket.

BraTYPE(tensorc), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(tensorc), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

rightmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(tensorc), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{k,l} = \sum_{i,j,m} Mat_{i,j} Ket_{k,m,i} (Bra_{l,m,j})^{\ast}. This is executed in two steps. This is the leftmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_left_state_qtensor()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the right to the left. This version is for states.

Arguments

MatTYPE(qtensor), inout

This is the transfer matrix right of Bra and Ket.

BraTYPE(qtensor), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(qtensor), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

rightmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(qtensor), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{k,l} = \sum_{i,j,m} Mat_{i,j} Ket_{k,m,i} (Bra_{l,m,j})^{\ast}. This is executed in two steps. This is the leftmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_left_state_qtensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the right to the left. This version is for states.

Arguments

MatTYPE(qtensorc), inout

This is the transfer matrix right of Bra and Ket.

BraTYPE(qtensorc), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(qtensorc), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

rightmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(qtensorc), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{k,l} = \sum_{i,j,m} Mat_{i,j} Ket_{k,m,i} (Bra_{l,m,j})^{\ast}. This is executed in two steps. This is the leftmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_right_state_tensor_tensor()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the left to the right. This version is for states.

Arguments

MatTYPE(tensor), inout

This is the transfer matrix left of Bra and Ket.

BraTYPE(tensor), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(tensor), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

leftmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(tensor), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{l,k} = \sum_{i,j,m} Mat_{i,j} Ket_{j,m,k} Bra_{i,m,l}^{\ast}. This is executed in two steps. This is the rightmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_right_state_tensor_tensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the left to the right. This version is for states.

Arguments

MatTYPE(tensorc), inout

This is the transfer matrix left of Bra and Ket.

BraTYPE(tensorc), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(tensorc), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

leftmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(tensorc), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{l,k} = \sum_{i,j,m} Mat_{i,j} Ket_{j,m,k} Bra_{i,m,l}^{\ast}. This is executed in two steps. This is the rightmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_right_state_tensorc_tensor()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the left to the right. This version is for states.

Arguments

MatTYPE(tensorc), inout

This is the transfer matrix left of Bra and Ket.

BraTYPE(tensorc), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(tensorc), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

leftmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(tensorc), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{l,k} = \sum_{i,j,m} Mat_{i,j} Ket_{j,m,k} Bra_{i,m,l}^{\ast}. This is executed in two steps. This is the rightmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_right_state_tensorc_tensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the left to the right. This version is for states.

Arguments

MatTYPE(tensorc), inout

This is the transfer matrix left of Bra and Ket.

BraTYPE(tensorc), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(tensorc), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

leftmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(tensorc), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{l,k} = \sum_{i,j,m} Mat_{i,j} Ket_{j,m,k} Bra_{i,m,l}^{\ast}. This is executed in two steps. This is the rightmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_right_state_qtensor_qtensor()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the left to the right. This version is for states.

Arguments

MatTYPE(qtensor), inout

This is the transfer matrix left of Bra and Ket.

BraTYPE(qtensor), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(qtensor), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

leftmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(qtensor), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{l,k} = \sum_{i,j,m} Mat_{i,j} Ket_{j,m,k} Bra_{i,m,l}^{\ast}. This is executed in two steps. This is the rightmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_right_state_qtensor_qtensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the left to the right. This version is for states.

Arguments

MatTYPE(qtensorc), inout

This is the transfer matrix left of Bra and Ket.

BraTYPE(qtensorc), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(qtensorc), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

leftmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(qtensorc), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{l,k} = \sum_{i,j,m} Mat_{i,j} Ket_{j,m,k} Bra_{i,m,l}^{\ast}. This is executed in two steps. This is the rightmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_right_state_qtensorc_qtensor()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the left to the right. This version is for states.

Arguments

MatTYPE(qtensorc), inout

This is the transfer matrix left of Bra and Ket.

BraTYPE(qtensorc), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(qtensorc), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

leftmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(qtensorc), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{l,k} = \sum_{i,j,m} Mat_{i,j} Ket_{j,m,k} Bra_{i,m,l}^{\ast}. This is executed in two steps. This is the rightmoving version.

Source Code

show / hide f90 code
MPSOps_f90.ptm_right_state_qtensorc_qtensorc()[source]

fortran-subroutine - June 2017 (dj, updated) Propagate transfer matrix (PTM) moving from the left to the right. This version is for states.

Arguments

MatTYPE(qtensorc), inout

This is the transfer matrix left of Bra and Ket.

BraTYPE(qtensorc), inout

Contract conjagated of Bra into the transfer matrix. Intent inout is for contraction, but should used.

KetTYPE(qtensorc), inout

Contract Ket into the transfer matrix. Intent inout is for contraction, but should used.

leftmostLOGICAL, in

Indicate if this is the rightmost, and therefore first site, to be contracted.

MatinTYPE(qtensorc), OPTIONAL, in

If Matin is present, Matin is the present transfer matrix. It is not destroyed. If not present, Mat is assumed to be the present transfer matrix and is overwritten with the new one.

Details

The contraction is over both indices of Mat and can be written as Mat_{l,k} = \sum_{i,j,m} Mat_{i,j} Ket_{j,m,k} Bra_{i,m,l}^{\ast}. This is executed in two steps. This is the rightmoving version.

Source Code

show / hide f90 code
MPSOps_f90.randomize_mps()[source]

fortran-subroutine - June 2017 (dj, updated) Fill the MPS Psi with random numbers

Arguments

PsiTYPE(mps), inout

Fill the MPS with random numbers. The orthogonality center is not installed during this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.randomize_mpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Fill the MPS Psi with random numbers

Arguments

PsiTYPE(mpsc), inout

Fill the MPS with random numbers. The orthogonality center is not installed during this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.randomize_qmps()[source]

fortran-subroutine - June 2017 (dj, updated) Fill the MPS Psi with random numbers

Arguments

PsiTYPE(qmps), inout

Fill the MPS with random numbers. The orthogonality center is not installed during this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.randomize_qmpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Fill the MPS Psi with random numbers

Arguments

PsiTYPE(qmpsc), inout

Fill the MPS with random numbers. The orthogonality center is not installed during this subroutine.

Source Code

show / hide f90 code
MPSOps_f90.read_mps()[source]

fortran-subroutine - June 2016 (dj, updated) Read an MPS given a filename and a unit (assuming you know the type already).

Arguments

PsiTYPE(mps), in

Read MPS in file to this MPS

flnmCHARACTER(100), in

the MPS is stored in this file.

unitINTEGER, in

open file on this unit

formCHARACTER, in

Binary (‘B’) or human readable (‘H’)

skipLOGICAL, OPTIONAL, in

.true. : the first two lines were already read somewhere. Do not read them here (those lines contain the information about the type of the MPS in the file, real/complex, no symm/symmetries). Default to .false.

errflagINTEGER, out

0 : could read MPS; 1 : type of MPS does not correspond type of the MPS in the file (only checked for skip1st2=false).

closeunitLOGICAL, OPTIONAL, in

Flag if the unit should be closed on exit. Default to true.

Details

The file for MPS has the general form defined as below. Following these rules, it is possible to provide states to OpenMPS. * logical if MPS is real or complex valued (real=True, complex=False) [line 1] * logical if MPS or qMPS (qMPS=True, non-symmetry MPS=False) [line 2] * integer with number of size [line 3] * integer with position of the orthogonality center [line 4] * “H” : in a loop over the pairs of haslambda and can are written in l lines. “B” : the array of can is read, then haslambda. * In a loop over the sites of the system, the tensors of the MPS are written. The way how to write the tensors is specified in the corresponding subroutine. * Depending on the value of haslambda, read the vector (vectorlist) with the corresponding subroutine.

Source Code

show / hide f90 code
MPSOps_f90.read_mpsc()[source]

fortran-subroutine - June 2016 (dj, updated) Read an MPS given a filename and a unit (assuming you know the type already).

Arguments

PsiTYPE(mpsc), in

Read MPS in file to this MPS

flnmCHARACTER(100), in

the MPS is stored in this file.

unitINTEGER, in

open file on this unit

formCHARACTER, in

Binary (‘B’) or human readable (‘H’)

skipLOGICAL, OPTIONAL, in

.true. : the first two lines were already read somewhere. Do not read them here (those lines contain the information about the type of the MPS in the file, real/complex, no symm/symmetries). Default to .false.

errflagINTEGER, out

0 : could read MPS; 1 : type of MPS does not correspond type of the MPS in the file (only checked for skip1st2=false).

closeunitLOGICAL, OPTIONAL, in

Flag if the unit should be closed on exit. Default to true.

Details

The file for MPS has the general form defined as below. Following these rules, it is possible to provide states to OpenMPS. * logical if MPS is real or complex valued (real=True, complex=False) [line 1] * logical if MPS or qMPS (qMPS=True, non-symmetry MPS=False) [line 2] * integer with number of size [line 3] * integer with position of the orthogonality center [line 4] * “H” : in a loop over the pairs of haslambda and can are written in l lines. “B” : the array of can is read, then haslambda. * In a loop over the sites of the system, the tensors of the MPS are written. The way how to write the tensors is specified in the corresponding subroutine. * Depending on the value of haslambda, read the vector (vectorlist) with the corresponding subroutine.

Source Code

show / hide f90 code
MPSOps_f90.read_qmps()[source]

fortran-subroutine - June 2016 (dj, updated) Read an MPS given a filename and a unit (assuming you know the type already).

Arguments

PsiTYPE(qmps), in

Read MPS in file to this MPS

flnmCHARACTER(100), in

the MPS is stored in this file.

unitINTEGER, in

open file on this unit

formCHARACTER, in

Binary (‘B’) or human readable (‘H’)

skipLOGICAL, OPTIONAL, in

.true. : the first two lines were already read somewhere. Do not read them here (those lines contain the information about the type of the MPS in the file, real/complex, no symm/symmetries). Default to .false.

errflagINTEGER, out

0 : could read MPS; 1 : type of MPS does not correspond type of the MPS in the file (only checked for skip1st2=false).

closeunitLOGICAL, OPTIONAL, in

Flag if the unit should be closed on exit. Default to true.

Details

The file for MPS has the general form defined as below. Following these rules, it is possible to provide states to OpenMPS. * logical if MPS is real or complex valued (real=True, complex=False) [line 1] * logical if MPS or qMPS (qMPS=True, non-symmetry MPS=False) [line 2] * integer with number of size [line 3] * integer with position of the orthogonality center [line 4] * “H” : in a loop over the pairs of haslambda and can are written in l lines. “B” : the array of can is read, then haslambda. * In a loop over the sites of the system, the tensors of the MPS are written. The way how to write the tensors is specified in the corresponding subroutine. * Depending on the value of haslambda, read the vector (vectorlist) with the corresponding subroutine.

Source Code

show / hide f90 code
MPSOps_f90.read_qmpsc()[source]

fortran-subroutine - June 2016 (dj, updated) Read an MPS given a filename and a unit (assuming you know the type already).

Arguments

PsiTYPE(qmpsc), in

Read MPS in file to this MPS

flnmCHARACTER(100), in

the MPS is stored in this file.

unitINTEGER, in

open file on this unit

formCHARACTER, in

Binary (‘B’) or human readable (‘H’)

skipLOGICAL, OPTIONAL, in

.true. : the first two lines were already read somewhere. Do not read them here (those lines contain the information about the type of the MPS in the file, real/complex, no symm/symmetries). Default to .false.

errflagINTEGER, out

0 : could read MPS; 1 : type of MPS does not correspond type of the MPS in the file (only checked for skip1st2=false).

closeunitLOGICAL, OPTIONAL, in

Flag if the unit should be closed on exit. Default to true.

Details

The file for MPS has the general form defined as below. Following these rules, it is possible to provide states to OpenMPS. * logical if MPS is real or complex valued (real=True, complex=False) [line 1] * logical if MPS or qMPS (qMPS=True, non-symmetry MPS=False) [line 2] * integer with number of size [line 3] * integer with position of the orthogonality center [line 4] * “H” : in a loop over the pairs of haslambda and can are written in l lines. “B” : the array of can is read, then haslambda. * In a loop over the sites of the system, the tensors of the MPS are written. The way how to write the tensors is specified in the corresponding subroutine. * Depending on the value of haslambda, read the vector (vectorlist) with the corresponding subroutine.

Source Code

show / hide f90 code
MPSOps_f90.read_allmps()[source]

fortran-subroutine - June 2017 (dj, updated) Read MPS from file if you do not know what kind of MPS is saved.

Arguments

PsiTYPE(mps), out

On exit set if MPS representing Psi is real and has no symmetries.

PsicTYPE(mpsc), out

On exit set if MPS representing Psi is complex and has no symmetries.

PsiqTYPE(qmps), out

On exit set if MPS representing is real and has symmetries.

PsiqcTYPE(qmpsc), out

On exit set if MPS representing is complex and has symmetries.

flagINTEGER, out

0: reading real MPS, 1: complex MPS, 2: real symmetric MPS, 3: complex symmetric MPS

flnmCHARACTER(100), in

the MPS is stored in this file.

unitINTEGER, in

open file on this unit

formCHARACTER, in

Binary (‘B’) or human readable (‘H’)

Source Code

show / hide f90 code
MPSOps_f90.rho_block_mps()[source]

fortran-subroutine - June 2018 (dj) Internal subroutine to build the reduced density matrix of a continuous block of sites.

Arguments

RhoTYPE(tensor), out

On exit the reduced density matrix with the sites specified. The first half of the indices corresponds to the kets on each site. The second half corresponds to the bra-indices.

PsiTYPE(mps), inout

Pure state to build density matrix from. Intent(inout) to shift orthogonality center.

k1INTEGER, in

First site of the subsystem.

k2INTEGER, in

Last site of the subsystem.

Source Code

show / hide f90 code
MPSOps_f90.rho_block_mpsc()[source]

fortran-subroutine - June 2018 (dj) Internal subroutine to build the reduced density matrix of a continuous block of sites.

Arguments

RhoTYPE(tensorc), out

On exit the reduced density matrix with the sites specified. The first half of the indices corresponds to the kets on each site. The second half corresponds to the bra-indices.

PsiTYPE(mpsc), inout

Pure state to build density matrix from. Intent(inout) to shift orthogonality center.

k1INTEGER, in

First site of the subsystem.

k2INTEGER, in

Last site of the subsystem.

Source Code

show / hide f90 code
MPSOps_f90.rho_block_qmps()[source]

fortran-subroutine - June 2018 (dj) Internal subroutine to build the reduced density matrix of a continuous block of sites.

Arguments

RhoTYPE(qtensor), out

On exit the reduced density matrix with the sites specified. The first half of the indices corresponds to the kets on each site. The second half corresponds to the bra-indices.

PsiTYPE(qmps), inout

Pure state to build density matrix from. Intent(inout) to shift orthogonality center.

k1INTEGER, in

First site of the subsystem.

k2INTEGER, in

Last site of the subsystem.

Source Code

show / hide f90 code
MPSOps_f90.rho_block_qmpsc()[source]

fortran-subroutine - June 2018 (dj) Internal subroutine to build the reduced density matrix of a continuous block of sites.

Arguments

RhoTYPE(qtensorc), out

On exit the reduced density matrix with the sites specified. The first half of the indices corresponds to the kets on each site. The second half corresponds to the bra-indices.

PsiTYPE(qmpsc), inout

Pure state to build density matrix from. Intent(inout) to shift orthogonality center.

k1INTEGER, in

First site of the subsystem.

k2INTEGER, in

Last site of the subsystem.

Source Code

show / hide f90 code
MPSOps_f90.rho_kk_mps()[source]

fortran-subroutine - July 2017 (dj) Calculate the reduced density matrix represented as tensor.

Arguments

RhoTYPE(tensor), out

The density matrix is stored in this tensor

PsiTYPE(mps), in

Calculate reduced density matrix for this MPS.

kkINTEGER, in

Select site where reduced density matrix should be calculated. It must be the orthogonality center.

Source Code

show / hide f90 code
MPSOps_f90.rho_kk_mpsc()[source]

fortran-subroutine - July 2017 (dj) Calculate the reduced density matrix represented as tensor.

Arguments

RhoTYPE(tensorc), out

The density matrix is stored in this tensor

PsiTYPE(mpsc), in

Calculate reduced density matrix for this MPS.

kkINTEGER, in

Select site where reduced density matrix should be calculated. It must be the orthogonality center.

Source Code

show / hide f90 code
MPSOps_f90.rho_kk_qmps()[source]

fortran-subroutine - July 2017 (dj) Calculate the reduced density matrix represented as tensor.

Arguments

RhoTYPE(qtensor), out

The density matrix is stored in this tensor

PsiTYPE(qmps), in

Calculate reduced density matrix for this MPS.

kkINTEGER, in

Select site where reduced density matrix should be calculated. It must be the orthogonality center.

Source Code

show / hide f90 code
MPSOps_f90.rho_kk_qmpsc()[source]

fortran-subroutine - July 2017 (dj) Calculate the reduced density matrix represented as tensor.

Arguments

RhoTYPE(qtensorc), out

The density matrix is stored in this tensor

PsiTYPE(qmpsc), in

Calculate reduced density matrix for this MPS.

kkINTEGER, in

Select site where reduced density matrix should be calculated. It must be the orthogonality center.

Source Code

show / hide f90 code
MPSOps_f90.rho_red_mps()[source]

fortran-subroutine - June 2018 (dj) Build a general reduced density matrix on multiple sites.

Arguments

RhoTYPE(tensor), out

On exit the reduced density matrix with the sites specified. The first half of the indices corresponds to the kets on each site. The second half corresponds to the bra-indices.

PsiTYPE(mps), inout

Pure state to build density matrix from. Intent(inout) to shift orthogonality center.

sitesINTEGER(*), in

List of sites for the reduced density matrix.

contLOGICAL, in

Indicator if sites are one continuous block of indices (true) or separated by indices to be traced out (false).

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

errREAL, out

Truncation error for tracking it from calling routine.

Source Code

show / hide f90 code
MPSOps_f90.rho_red_mpsc()[source]

fortran-subroutine - June 2018 (dj) Build a general reduced density matrix on multiple sites.

Arguments

RhoTYPE(tensorc), out

On exit the reduced density matrix with the sites specified. The first half of the indices corresponds to the kets on each site. The second half corresponds to the bra-indices.

PsiTYPE(mpsc), inout

Pure state to build density matrix from. Intent(inout) to shift orthogonality center.

sitesINTEGER(*), in

List of sites for the reduced density matrix.

contLOGICAL, in

Indicator if sites are one continuous block of indices (true) or separated by indices to be traced out (false).

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

errREAL, out

Truncation error for tracking it from calling routine.

Source Code

show / hide f90 code
MPSOps_f90.rho_red_qmps()[source]

fortran-subroutine - June 2018 (dj) Build a general reduced density matrix on multiple sites.

Arguments

RhoTYPE(qtensor), out

On exit the reduced density matrix with the sites specified. The first half of the indices corresponds to the kets on each site. The second half corresponds to the bra-indices.

PsiTYPE(qmps), inout

Pure state to build density matrix from. Intent(inout) to shift orthogonality center.

sitesINTEGER(*), in

List of sites for the reduced density matrix.

contLOGICAL, in

Indicator if sites are one continuous block of indices (true) or separated by indices to be traced out (false).

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

errREAL, out

Truncation error for tracking it from calling routine.

Source Code

show / hide f90 code
MPSOps_f90.rho_red_qmpsc()[source]

fortran-subroutine - June 2018 (dj) Build a general reduced density matrix on multiple sites.

Arguments

RhoTYPE(qtensorc), out

On exit the reduced density matrix with the sites specified. The first half of the indices corresponds to the kets on each site. The second half corresponds to the bra-indices.

PsiTYPE(qmpsc), inout

Pure state to build density matrix from. Intent(inout) to shift orthogonality center.

sitesINTEGER(*), in

List of sites for the reduced density matrix.

contLOGICAL, in

Indicator if sites are one continuous block of indices (true) or separated by indices to be traced out (false).

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

errREAL, out

Truncation error for tracking it from calling routine.

Source Code

show / hide f90 code
MPSOps_f90.scale_real_mps()[source]

fortran-subroutine - June 2017 (dj, updated) Rescale Psi by some factor.

Arguments

scalefactorreal, in

some real number to scale MPS

PsiTYPE(mps), inout

Mutliply the orthogonality center (or 1 if no orthogonality center) with a scalar factor).

Source Code

show / hide f90 code
MPSOps_f90.scale_real_mpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Rescale Psi by some factor.

Arguments

scalefactorreal, in

some real number to scale MPS

PsiTYPE(mpsc), inout

Mutliply the orthogonality center (or 1 if no orthogonality center) with a scalar factor).

Source Code

show / hide f90 code
MPSOps_f90.scale_real_qmps()[source]

fortran-subroutine - June 2017 (dj, updated) Rescale Psi by some factor.

Arguments

scalefactorreal, in

some real number to scale MPS

PsiTYPE(qmps), inout

Mutliply the orthogonality center (or 1 if no orthogonality center) with a scalar factor).

Source Code

show / hide f90 code
MPSOps_f90.scale_real_qmpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Rescale Psi by some factor.

Arguments

scalefactorreal, in

some real number to scale MPS

PsiTYPE(qmpsc), inout

Mutliply the orthogonality center (or 1 if no orthogonality center) with a scalar factor).

Source Code

show / hide f90 code
MPSOps_f90.scale_complex_mpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Rescale Psi by some factor.

Arguments

scalefactorcomplex, in

some real number to scale MPS

PsiTYPE(mpsc), inout

Mutliply the orthogonality center (or 1 if no orthogonality center) with a scalar factor).

Source Code

show / hide f90 code
MPSOps_f90.scale_complex_qmpsc()[source]

fortran-subroutine - June 2017 (dj, updated) Rescale Psi by some factor.

Arguments

scalefactorcomplex, in

some real number to scale MPS

PsiTYPE(qmpsc), inout

Mutliply the orthogonality center (or 1 if no orthogonality center) with a scalar factor).

Source Code

show / hide f90 code
MPSOps_f90.setuplr_mps()[source]

fortran-subroutine - June 2017 (dj) Initialize the left-right overlaps of two states.

Arguments

LRTYPE(tensorlist), inout

Contains on exit the left-right overlaps between Psia and Psib.

PsiaTYPE(mps), inout

The first wave function for the overlap.

PsibTYPE(mps), inout

The second wave function for the overlap.

kkINTEGER, OPTIONAL, in

Center for the left-right overlap. Default to the first site kk = 1.

Details

The array of left-right overlaps in an array of length L, where L is the number of sites. There are no identities padded to the left and right boundary.

Source Code

show / hide f90 code
MPSOps_f90.setuplr_mpsc()[source]

fortran-subroutine - June 2017 (dj) Initialize the left-right overlaps of two states.

Arguments

LRTYPE(tensorlistc), inout

Contains on exit the left-right overlaps between Psia and Psib.

PsiaTYPE(mpsc), inout

The first wave function for the overlap.

PsibTYPE(mpsc), inout

The second wave function for the overlap.

kkINTEGER, OPTIONAL, in

Center for the left-right overlap. Default to the first site kk = 1.

Details

The array of left-right overlaps in an array of length L, where L is the number of sites. There are no identities padded to the left and right boundary.

Source Code

show / hide f90 code
MPSOps_f90.setuplr_qmps()[source]

fortran-subroutine - June 2017 (dj) Initialize the left-right overlaps of two states.

Arguments

LRTYPE(qtensorlist), inout

Contains on exit the left-right overlaps between Psia and Psib.

PsiaTYPE(qmps), inout

The first wave function for the overlap.

PsibTYPE(qmps), inout

The second wave function for the overlap.

kkINTEGER, OPTIONAL, in

Center for the left-right overlap. Default to the first site kk = 1.

Details

The array of left-right overlaps in an array of length L, where L is the number of sites. There are no identities padded to the left and right boundary.

Source Code

show / hide f90 code
MPSOps_f90.setuplr_qmpsc()[source]

fortran-subroutine - June 2017 (dj) Initialize the left-right overlaps of two states.

Arguments

LRTYPE(qtensorclist), inout

Contains on exit the left-right overlaps between Psia and Psib.

PsiaTYPE(qmpsc), inout

The first wave function for the overlap.

PsibTYPE(qmpsc), inout

The second wave function for the overlap.

kkINTEGER, OPTIONAL, in

Center for the left-right overlap. Default to the first site kk = 1.

Details

The array of left-right overlaps in an array of length L, where L is the number of sites. There are no identities padded to the left and right boundary.

Source Code

show / hide f90 code
MPSOps_f90.swap_mps_tensor()[source]

fortran-subroutine - May 2018 (dj) Swap two nearest-neighbor sites in an MPS.

Arguments

TensaTYPE(tensor), inout

The second index of this tensor is on exit contained in Tensb.

TensbTYPE(tensor), inout

The second index of this tensor is on exit contained in Tensa.

LamTYPE(tensor), inout

On exit, new singular values at splitting Tensa/Tensb.

dirINTEGER, in

Multiply singular values to Tensa for dir < 0 and to Tensa for dir > 0 to Tensb.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

cerrREAL, OPTIONAL, inout

Cumulative error from SVDs.

Source Code

show / hide f90 code
MPSOps_f90.swap_mps_tensorc()[source]

fortran-subroutine - May 2018 (dj) Swap two nearest-neighbor sites in an MPS.

Arguments

TensaTYPE(tensorc), inout

The second index of this tensor is on exit contained in Tensb.

TensbTYPE(tensorc), inout

The second index of this tensor is on exit contained in Tensa.

LamTYPE(tensor), inout

On exit, new singular values at splitting Tensa/Tensb.

dirINTEGER, in

Multiply singular values to Tensa for dir < 0 and to Tensa for dir > 0 to Tensb.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

cerrREAL, OPTIONAL, inout

Cumulative error from SVDs.

Source Code

show / hide f90 code
MPSOps_f90.swap_mps_qtensor()[source]

fortran-subroutine - May 2018 (dj) Swap two nearest-neighbor sites in an MPS.

Arguments

TensaTYPE(qtensor), inout

The second index of this tensor is on exit contained in Tensb.

TensbTYPE(qtensor), inout

The second index of this tensor is on exit contained in Tensa.

LamTYPE(qtensor), inout

On exit, new singular values at splitting Tensa/Tensb.

dirINTEGER, in

Multiply singular values to Tensa for dir < 0 and to Tensa for dir > 0 to Tensb.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

cerrREAL, OPTIONAL, inout

Cumulative error from SVDs.

Source Code

show / hide f90 code
MPSOps_f90.swap_mps_qtensorc()[source]

fortran-subroutine - May 2018 (dj) Swap two nearest-neighbor sites in an MPS.

Arguments

TensaTYPE(qtensorc), inout

The second index of this tensor is on exit contained in Tensb.

TensbTYPE(qtensorc), inout

The second index of this tensor is on exit contained in Tensa.

LamTYPE(qtensor), inout

On exit, new singular values at splitting Tensa/Tensb.

dirINTEGER, in

Multiply singular values to Tensa for dir < 0 and to Tensa for dir > 0 to Tensb.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

cerrREAL, OPTIONAL, inout

Cumulative error from SVDs.

Source Code

show / hide f90 code
MPSOps_f90.transposed_mps()[source]

fortran-subroutine - May 2018 (dj) Permute the local Hilbert spaces.

Arguments

PsiTYPE(mps), inout

Permute MPS sites in-place. Error can be introduced due to SVDs.

permINTEGER(*), in

Permutation array has length equal to the number of sites L in the MPS with unique entries 1 to L.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

cerrREAL, OPTIONAL, inout

Cumulative error from SVDs.

Source Code

show / hide f90 code
MPSOps_f90.transposed_mpsc()[source]

fortran-subroutine - May 2018 (dj) Permute the local Hilbert spaces.

Arguments

PsiTYPE(mpsc), inout

Permute MPS sites in-place. Error can be introduced due to SVDs.

permINTEGER(*), in

Permutation array has length equal to the number of sites L in the MPS with unique entries 1 to L.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

cerrREAL, OPTIONAL, inout

Cumulative error from SVDs.

Source Code

show / hide f90 code
MPSOps_f90.transposed_qmps()[source]

fortran-subroutine - May 2018 (dj) Permute the local Hilbert spaces.

Arguments

PsiTYPE(qmps), inout

Permute MPS sites in-place. Error can be introduced due to SVDs.

permINTEGER(*), in

Permutation array has length equal to the number of sites L in the MPS with unique entries 1 to L.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

cerrREAL, OPTIONAL, inout

Cumulative error from SVDs.

Source Code

show / hide f90 code
MPSOps_f90.transposed_qmpsc()[source]

fortran-subroutine - May 2018 (dj) Permute the local Hilbert spaces.

Arguments

PsiTYPE(qmpsc), inout

Permute MPS sites in-place. Error can be introduced due to SVDs.

permINTEGER(*), in

Permutation array has length equal to the number of sites L in the MPS with unique entries 1 to L.

truncREAL, OPTIONAL, in

Keep infidelity below trunc (infidelity is sum of squared discarded singular values for MPS). Default does not truncate.

ncutINTEGER, OPTIONAL, in

Maximal bond dimension / number of singular values. Default is keeping all singular values.

cerrREAL, OPTIONAL, inout

Cumulative error from SVDs.

Source Code

show / hide f90 code
MPSOps_f90.updatelr_mps()[source]

fortran-subroutine - June 2017 (dj) Shift the left-right overlap by one site.

Arguments

LRTYPE(tensorlist), inout

Contains on exit the left-right overlaps between Psia and Psib.

PsiaTYPE(mps), inout

The first wave function for the overlap.

PsibTYPE(mps), inout

The second wave function for the overlap.

kkINTEGER, in

New center for the left-right overlap.

senseINTEGER, in

Move center of the left-right overlap to the right for sense > 0 and to the left for sense < 0.

Source Code

show / hide f90 code
MPSOps_f90.updatelr_mpsc()[source]

fortran-subroutine - June 2017 (dj) Shift the left-right overlap by one site.

Arguments

LRTYPE(tensorlistc), inout

Contains on exit the left-right overlaps between Psia and Psib.

PsiaTYPE(mpsc), inout

The first wave function for the overlap.

PsibTYPE(mpsc), inout

The second wave function for the overlap.

kkINTEGER, in

New center for the left-right overlap.

senseINTEGER, in

Move center of the left-right overlap to the right for sense > 0 and to the left for sense < 0.

Source Code

show / hide f90 code
MPSOps_f90.updatelr_qmps()[source]

fortran-subroutine - June 2017 (dj) Shift the left-right overlap by one site.

Arguments

LRTYPE(qtensorlist), inout

Contains on exit the left-right overlaps between Psia and Psib.

PsiaTYPE(qmps), inout

The first wave function for the overlap.

PsibTYPE(qmps), inout

The second wave function for the overlap.

kkINTEGER, in

New center for the left-right overlap.

senseINTEGER, in

Move center of the left-right overlap to the right for sense > 0 and to the left for sense < 0.

Source Code

show / hide f90 code
MPSOps_f90.updatelr_qmpsc()[source]

fortran-subroutine - June 2017 (dj) Shift the left-right overlap by one site.

Arguments

LRTYPE(qtensorclist), inout

Contains on exit the left-right overlaps between Psia and Psib.

PsiaTYPE(qmpsc), inout

The first wave function for the overlap.

PsibTYPE(qmpsc), inout

The second wave function for the overlap.

kkINTEGER, in

New center for the left-right overlap.

senseINTEGER, in

Move center of the left-right overlap to the right for sense > 0 and to the left for sense < 0.

Source Code

show / hide f90 code
MPSOps_f90.write_mps()[source]

fortran-subroutine - August 2015 (dj) Write an MPS to file

Arguments

PsiTYPE(mps), in

save this MPS

unitINTEGER, in

open file on this unit

formCHARACTER, in

Binary (‘B’), human readable (‘H’), or user-friendly (“6”).

Details

For details see the description of the order which the information is written, please see read_mps

Source Code

show / hide f90 code
MPSOps_f90.write_mpsc()[source]

fortran-subroutine - August 2015 (dj) Write an MPS to file

Arguments

PsiTYPE(mpsc), in

save this MPS

unitINTEGER, in

open file on this unit

formCHARACTER, in

Binary (‘B’), human readable (‘H’), or user-friendly (“6”).

Details

For details see the description of the order which the information is written, please see read_mpsc

Source Code

show / hide f90 code
MPSOps_f90.write_qmps()[source]

fortran-subroutine - August 2015 (dj) Write an MPS to file

Arguments

PsiTYPE(qmps), in

save this MPS

unitINTEGER, in

open file on this unit

formCHARACTER, in

Binary (‘B’), human readable (‘H’), or user-friendly (“6”).

Details

For details see the description of the order which the information is written, please see read_qmps

Source Code

show / hide f90 code
MPSOps_f90.write_qmpsc()[source]

fortran-subroutine - August 2015 (dj) Write an MPS to file

Arguments

PsiTYPE(qmpsc), in

save this MPS

unitINTEGER, in

open file on this unit

formCHARACTER, in

Binary (‘B’), human readable (‘H’), or user-friendly (“6”).

Details

For details see the description of the order which the information is written, please see read_qmpsc

Source Code

show / hide f90 code