tschoonj / xraylib

A library for X-ray matter interaction cross sections for X-ray fluorescence applications
https://github.com/tschoonj/xraylib/wiki
Other
120 stars 55 forks source link

XRF production cs calculation #16

Closed licode closed 9 years ago

licode commented 9 years ago

I am still a bit confused about xrf production cs. For instance:

In [42]: xraylib.CS_FluorLine_Kissel(82,xraylib.MA1_LINE,20.0)
Out[42]: 1.3438984155654907

In [43]: xraylib.CS_FluorLine(82,xraylib.MA1_LINE,20.0)
Out[43]: 0.0

When I compare the two methods for cs on K lines, the results are similar. So Kissel method is much accurate for M line calculation?

tschoonj commented 9 years ago

Hi Li,

This is not a matter of accuracy: the CS_FluorLine just doesn't support calculating M-line XRF cross sections, which is due to the fact that xraylib doesn't have the required jump factors to do so.

I have updated the documentation with a comment regarding this behavior.

Cheers,

Tom

licode commented 9 years ago

Hi Tom,

I am working on data analysis for general XRF scanning experiments at synchrotron. We basically scan each point of the sample, and do fitting to get the elemental distribution. So correction branching ratio for each element is important for the fitting. The branching ratio is a function of both incident energy, and sample absorption information. So do you think xraylib.CS_FluorLine_Kissel is appropriate to use to get branching ratio? Or any other recommendation?

tschoonj commented 9 years ago

Hi Li,

Yes absolutely: I recommend to use CS_FluorLine_Kissel over CS_FluorLine in all cases. Just keep in mind that the fundamental parameters involved in M-line XRF cross sections tend to be quite inaccurate, which may result in poor fittings.

As long as you're just looking at elemental distributions this should be no problem though: the trouble will come in once you start doing (reference-free) quantifications…

Best,

Tom