1
0
forked from IPKM/nmreval

add isotropic line shift to czjzek (#317)

Co-authored-by: Dominik Demuth <dominik.demuth@physik.tu-darmstadt.de>
Reviewed-on: IPKM/nmreval#317
This commit is contained in:
2025-07-18 16:44:22 +00:00
parent bc318a04d6
commit 8710d9b831

View File

@@ -176,8 +176,8 @@ class CzjzekCT:
type = 'Spectrum'
name = 'Czjzek (Central Line)'
equation = ''
params = ['A', r'\sigma', 'GB', r'\omega_{L}']
bounds = [(0, None), (0, None), (0, None), (0, None)]
params = ['A', r'\sigma', r'f_{iso}', 'GB', r'\omega_{L}']
bounds = [(0, None), (0, None), (None, None), (0, None), (0, None)]
choices = [('Spin', 'spin', {'3/2': 1.5, '5/2': 2.5}),
('Broadening', 'broad', {'Gaussian': 'g', 'Lorentzian': 'l'})]
@@ -186,6 +186,7 @@ class CzjzekCT:
x: np.ndarray,
c: float,
sigma: float,
f_iso: float,
gb: float,
f_l: float,
spin: float = 1.5,
@@ -218,7 +219,7 @@ class CzjzekCT:
orient += prefactor_b * cos_theta_square
orient += prefactor_c
vQ = -orient[..., None] * coupling[None, None, :]
vQ = -(orient[..., None] * coupling[None, None, :]) + f_iso
weights = np.ones_like(vQ) * dist
bins = _make_bins(x)
@@ -239,4 +240,5 @@ class CzjzekCT:
@staticmethod
def czjzek(cq, eta, sigma):
return np.exp(-cq ** 2 * (1 + eta**2 / 3) / 2 / sigma**2) * cq**4 * eta * (1 - eta**2 / 9) * np.sqrt(2 / np.pi) / sigma**5
return np.exp(-cq ** 2 * (1 + eta ** 2 / 3) / 2 / sigma ** 2) * cq ** 4 * eta * (
1 - eta ** 2 / 9) * np.sqrt(2 / np.pi) / sigma ** 5