| _version_ | 1866901608427683840 |
|---|---|
| author | Sarria, David |
| author_facet | Sarria, David |
| contents | <div> <div> <div># CALCULATE_RESP_MATRIX_FOR_BINNING.m</div> <br> <div>This MATLAB function calculates a response matrix and related efficiency data for provided parameters:</div> <br> <div>- Energy bins (`BINS`) in keV</div> <div>- Altitude (`alt`) in km</div> <div>- Radial distance (`rd`) in km</div> <div>- Minimum energy threshold (`MINE`) in keV</div> <br> <div>## Functionality</div> <br><br> <div>1. Loads raw response data (database_RESP_MATRIX.mat), if not already loaded.</div> <div>2. Calculates the nadir angle from 'alt' and 'rd' and identifies the nearest precomputed nadir angles.</div> <div>3. Calculates the two closest response matrices surrounding the given nadir angle.</div> <div>4. Computes a weighted average (interpolation) of two closest response matrices based on the proximity to the calculated nadir angle, to get the response matrix.</div> <div>5. Also calculates effective area, and efficiency across provided energy bins.</div> <div> </div> <div>The function optimizes performance through caching. If a previous calculation for a specific set of inputs exists, the function quickly retrieves and returns this cached data.</div> <br> <div>## Output</div> <br> <div>The output structure contains:</div> <br> <div>- `energy_grid`: Midpoints of the provided energy bins.</div> <div>- `effective_area`: Effective detection area (cm²) for given Radial distance and Altitude (and the TGF/FGF spectrum after atmospheric propagation)</div> <div>- `efficiency`: Detection efficiency relative to geometric area (between 0 and 1).</div> <div>- `RESP_MATRIX`: Interpolated response matrix.</div> <div>Cached responses matrices for given {energy bins, altitude, radial distance} are stored as `.mat` files in a temporary directory for efficient reuse in subsequent calculations.</div> <br> <div># database_RESP_MATRIX.mat</div> <div>Contains raw data used for `CALCULATE_RESP_MATRIX_FOR_BINNING.m`</div> <div>'alt' and 'rd' are used to calculate an incident angle. database_RESP_MATRIX.mat contains raw photon energy deposit data for various initial energies and incoming (nadir) angles.</div> <br><br> <div># LOAD_RESP_MATRIX_DATA.m</div> <div>Function to load `database_RESP_MATRIX.mat`, used by `CALCULATE_RESP_MATRIX_FOR_BINNING.m`</div> </div> </div> |
| format | Recurso digital |
| id | zenodo_https___doi_org_10_5281_zenodo_15350194 |
| institution | Zenodo |
| language | |
| publishDate | 2025 |
| publisher | Zenodo |
| record_format | zenodo |
| spellingShingle | ALOFT UiB BGO Instrument response matrices Sarria, David <div> <div> <div># CALCULATE_RESP_MATRIX_FOR_BINNING.m</div> <br> <div>This MATLAB function calculates a response matrix and related efficiency data for provided parameters:</div> <br> <div>- Energy bins (`BINS`) in keV</div> <div>- Altitude (`alt`) in km</div> <div>- Radial distance (`rd`) in km</div> <div>- Minimum energy threshold (`MINE`) in keV</div> <br> <div>## Functionality</div> <br><br> <div>1. Loads raw response data (database_RESP_MATRIX.mat), if not already loaded.</div> <div>2. Calculates the nadir angle from 'alt' and 'rd' and identifies the nearest precomputed nadir angles.</div> <div>3. Calculates the two closest response matrices surrounding the given nadir angle.</div> <div>4. Computes a weighted average (interpolation) of two closest response matrices based on the proximity to the calculated nadir angle, to get the response matrix.</div> <div>5. Also calculates effective area, and efficiency across provided energy bins.</div> <div> </div> <div>The function optimizes performance through caching. If a previous calculation for a specific set of inputs exists, the function quickly retrieves and returns this cached data.</div> <br> <div>## Output</div> <br> <div>The output structure contains:</div> <br> <div>- `energy_grid`: Midpoints of the provided energy bins.</div> <div>- `effective_area`: Effective detection area (cm²) for given Radial distance and Altitude (and the TGF/FGF spectrum after atmospheric propagation)</div> <div>- `efficiency`: Detection efficiency relative to geometric area (between 0 and 1).</div> <div>- `RESP_MATRIX`: Interpolated response matrix.</div> <div>Cached responses matrices for given {energy bins, altitude, radial distance} are stored as `.mat` files in a temporary directory for efficient reuse in subsequent calculations.</div> <br> <div># database_RESP_MATRIX.mat</div> <div>Contains raw data used for `CALCULATE_RESP_MATRIX_FOR_BINNING.m`</div> <div>'alt' and 'rd' are used to calculate an incident angle. database_RESP_MATRIX.mat contains raw photon energy deposit data for various initial energies and incoming (nadir) angles.</div> <br><br> <div># LOAD_RESP_MATRIX_DATA.m</div> <div>Function to load `database_RESP_MATRIX.mat`, used by `CALCULATE_RESP_MATRIX_FOR_BINNING.m`</div> </div> </div> |
| title | ALOFT UiB BGO Instrument response matrices |
| url | https://doi.org/10.5281/zenodo.15350194 |