seemps.analysis.derivatives.finite_differences_mpo#
- seemps.analysis.derivatives.finite_differences_mpo(order: int, interval: TypeAliasForwardRef('~seemps.analysis.mesh.QuantizedInterval') | tuple[float, float, int], filter: int = 3, periodic: bool = False, base: int = 2, tol: float = 1e-4) MPO[source]#
Finite differences operator with noise resilience. Create the operator that implements a finite-difference approximation to the derivative of given order for a function encoded in L units of dimension base (which defaults to 2 for qubits). It assumes a uniformly spaced grid with separation dx.
- Parameters:
- order
int Order of the derivative (currently 1 or 2)
- interval: QuantizedInterval | IntervalTuple
The interval over which the function is defined.
- filter
int,default= 3 Size of the finite-difference formula with implicit filtering
- periodicbool,
default=False Whether the grid assumes periodic boundary conditions
- base
int,default= 2 Quantization of the tensor train (i.e. dimension of the register units)
- tol
float,deafult= 1e-4 Tolerance of the step size to avoid rounding errors
- order
- Returns:
- operator
MPO Matrix product operator encoding the finite difference formula
- operator
Notes