Skip to main content

canonical_schmidt_spectrum_subsystem

Function canonical_schmidt_spectrum_subsystem 

Source
pub fn canonical_schmidt_spectrum_subsystem(
    state: &[Complex64],
    local_dimensions: &[usize],
    retained_sites: &[usize],
    noncommuting_groups: &[Vec<usize>],
) -> Result<Vec<f64>>
Expand description

Canonical Schmidt spectrum for a pure bipartition.

A pure state has the same nonzero reduced spectrum on both sides of a bipartition. Computing two density-matrix decompositions independently is both wasteful and capable of producing last-bit entropy differences. This routine chooses the smaller factor, with a lexicographic tie-break on sorted site sets, so complementary calls take the identical numerical path. Optional noncommuting groups are reordered against that same canonical factor before the spectrum is evaluated.