scqubits.utils.spectrum_utils.standardize_sign#
- scqubits.utils.spectrum_utils.standardize_sign(real_array)[source]#
Standardizes the sign of a real-valued wavefunction by calculating the sign of the sum of all amplitudes up to the wavefunctions mid-position and making it positive.
Summing up to the midpoint only is to address the danger that the sum is actually zero, which may is the case for odd wavefunctions taken over an interval centered at zero.
- Return type
ndarray- Parameters
real_array (ndarray) –