oslocyclotronlab / ompy_Archive_Sept2019

Archived version om ompy as of 27. Sept 2019 -- Please use this instead:
https://github.com/oslocyclotronlab/ompy/
GNU General Public License v3.0
0 stars 1 forks source link

Implement response function manipulation #3

Closed fzeiser closed 5 years ago

fzeiser commented 5 years ago

Issue by jorgenem Monday Nov 05, 2018 at 09:59 GMT Originally opened as https://github.com/oslocyclotronlab/ompy/issues/3


It should be possible to change the calibration of the response functions inside pyma, instead of having to supply a response with the correct bin width etc. from MAMA. It may be that the easiest route is to compile the response routine from MAMA with f2py.

fzeiser commented 5 years ago

Comment by jorgenem Friday Jul 12, 2019 at 12:58 GMT


Fixed in 9ca2e3ecb5632388b02bb495c81a951390ff8a8c

fzeiser commented 5 years ago

Comment by Caronthir Wednesday Sep 04, 2019 at 14:13 GMT


The function interpolate_response does not give expected results in the case of Dy163.

Screenshot_2019-09-04_16-11-03

fzeiser commented 5 years ago

Comment by fzeiser Thursday Sep 05, 2019 at 15:17 GMT


Found the "mistake". We probably just had a /very/ wrong fwhm for the smoothing. In the linear scale shown here we then get some smoothing of counts up to quite high energies.

However, when going through this, I found a bug for the response at ~511 keV incident energy. I'll upload the corrections asap. (tomorrow?)

fzeiser commented 5 years ago

Comment by fzeiser Friday Sep 06, 2019 at 05:44 GMT


See commit message. I improved the interpolation for low energies. (Esp. below the 1. simulated spectrum and or bacscatter peak).

Status can be seen in notebooks/code_testing/resp and the notebook test_response_function_interpolation.ipynb.

A visual comparison (pasting in the files) response_compare_1

response_compare_2

But the comparison to geant4 (see notebook for comments) resp_600

resp_3000

fzeiser commented 5 years ago

Comment by fzeiser Friday Sep 06, 2019 at 14:20 GMT


@Caronthir: For now, I'd use FWHM = 2.27 for Oscar!

fzeiser commented 5 years ago

Comment by fzeiser Monday Sep 09, 2019 at 09:59 GMT


@Caronthir: Implemented the FWHM read-out differently in #38. How it should be absolute fwhm 1.33 MeV, which is around 30 for oscar. Be aware of changes when you merge it in.

Resp interpolation is now similar to the above. But have a look at the notebook/pictures in the code test folder.