seemps.state.random_mps#

seemps.state.random_mps(dimensions: list[int], D: int = 1, truncate: bool = True, complex: bool = False, rng: Generator | None = None) MPS[source]#

Create a random state with N elements of dimension d and bond dimension D.

Parameters:
dimensionslist[int]

List of physical dimensions of each quantum system

Dint, default = 1

The maximum bond dimension

truncatebool, default = True

Do not reach D for tensors that do not require it.

complexbool, default = False

If true, return states with complex wavefunctions.

rngnp.random.Generator, default = np.random.default_rng()

Random number generator used to create the state. Provide a seeded generator to ensure reproducibility

Returns:
MPS

A random matrix-product state.