simulate
Simulates the evolution of a quantum state through a given quantum circuit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
circuit
|
Circuit
|
The quantum circuit to simulate. The circuit is composed of layers, each of which can generate unitary or Kraus operators. |
required |
initial_state
|
Qarray
|
The initial quantum state to be evolved. This can be a state vector or a density matrix. |
required |
mode
|
SimulateMode
|
The mode of simulation. It can be either SimulateMode.UNITARY for unitary evolution or SimulateMode.KRAUS for Kraus operator evolution. Defaults to SimulateMode.UNITARY. |
UNITARY
|
Returns:
Name | Type | Description |
---|---|---|
Results |
Results
|
An object containing the results of the simulation, which includes the quantum states at each step of the circuit. |
Source code in jaxquantum/circuits/simulate.py
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 |
|