resfreqs_matrix#
- torchspin.resfreqs_matrix(sys, phi, theta, B, freq_range=None, threshold=1e-4, exp=None, opt=None, init_state=None, photo_weight=1.0)[source]#
Compute resonance frequencies and intensities for one orientation.
Diagonalizes
H = H0 - B * muzLat fixed static fieldBand returns all transition frequenciesE_j - E_i(MHz) together with their chi-averaged perpendicular transition rates.- Parameters:
sys (SpinSystem) – Spin system.
phi (float) – Azimuthal angle of the static field in the molecular frame (radians).
theta (float) – Polar angle of the static field in the molecular frame (radians).
B (float) – Static magnetic field (mT).
freq_range (tuple[float, float] | None) – Optional
(nu_min, nu_max)in GHz. Transitions outside this range are removed from the output. IfNone, all transitions are returned.threshold (float) – Relative intensity threshold for discarding weak transitions (default
1e-4). Set to0to keep all.exp (Experiment | None) – Optional
Experimentobject. If provided,exp.Temperatureis used for Boltzmann weighting.
- Returns:
freq – Resonance frequencies in MHz, shape
(nTransitions,).intensities – Transition intensities (a.u.), shape
(nTransitions,).
- Return type:
Notes
The transition rate formula is identical to
resfields():TR = (|mu_L|² - |nB0·mu_L|²) / 2
which chi-averages over all orientations of the oscillating field B1 perpendicular to the static field B0.