Unitary Calculations
Unitary Evolution and Derivatives
RobustGRAPE.calculate_unitary_and_derivatives
— Functioncalculate_unitary_and_derivatives(problem::UnitaryRobustGRAPEProblem, x::Vector{<:Real})
Calculate the unitary evolution operator and its derivatives with respect to control parameters and error sources.
Arguments
problem::UnitaryRobustGRAPEProblem
: The robust GRAPE problem definitionx::Vector{<:Real}
: The optimization vector containing control parameters and additional parameters
Returns
A tuple with:
U
: Final unitary evolutionU_dx
: Derivatives with respect to control parametersU_dx_add
: Derivatives with respect to additional parametersU_derr
: Derivatives with respect to error sourcesU_derr_dx
: Mixed derivatives (error and control parameters)U_derr_dx_add
: Mixed derivatives (error and additional parameters)
RobustGRAPE.calculate_interaction_error_operators
— Functioncalculate_interaction_error_operators(problem::UnitaryRobustGRAPEProblem, x::Vector{<:Real})
Calculate the interaction picture representation of error operators at each time step.
This function transforms error operators from the Schrödinger picture to the interaction picture, which is essential for analyzing how errors affect the quantum dynamics throughout the evolution. The interaction picture provides a way to separate the influence of the control Hamiltonian from the error terms.
Parameters
problem::UnitaryRobustGRAPEProblem
: The robust GRAPE problem definitionx::Vector{<:Real}
: The optimization vector containing control parameters and additional parameters
Returns
- A tensor of dimensions (ndim, ndim, ntimes, nerr) containing the interaction picture representation of each error operator at each time step.
Notes
- The interaction picture transformation uses the cumulative evolution operator
- Error operators are scaled by the small parameter ϵ used for numerical differentiation
- The returned tensor has dimensions permuted for convenient access to time-dependent error operators