mretegan / crispy

Core-Level Spectroscopy Simulations in Python
http://www.esrf.eu/computing/scientific/crispy
MIT License
40 stars 14 forks source link

Transition operators for quadrupolar transitions are wrong #26

Closed mretegan closed 1 month ago

mretegan commented 5 years ago

The function that calculates the transition operators for an arbitrary polarization and k-vector has wrong prefactors. Isotropic spectra are correct, but the XMCD and XMLD are not.

The correct function is:

function CalculateT(e, k)
    -- Calculate the transition operator for arbitrary
    -- polarization and wave vectors.
    if k == nil then
        T = e[1] * Tx_1s_4p + e[2] * Ty_1s_4p + e[3] * Tz_1s_4p
    else
        T = (e[1] * k[2] + e[2] * k[1]) * Txy_1s_3d / math.sqrt(3)
          + (e[1] * k[3] + e[3] * k[1]) * Txz_1s_3d / math.sqrt(3)
          + (e[2] * k[3] + e[3] * k[2]) * Tyz_1s_3d / math.sqrt(3)
          + (e[1] * k[1] - e[2] * k[2]) * Tx2y2_1s_3d / math.sqrt(3)
          + e[3] * k[3] * Tz2_1s_3d
    end
    return Chop(T)
end
mretegan commented 1 month ago

Fixed in version 0.8.0.