Esempio n. 1
0
    efficiency_neutron_multiplicity_cut / 100.0 * efficiency_distance_cut /
    100.0 * error_efficiency_muon_veto)

# spectrum of all simulated IBD-like events (cut efficiencies are considered):
Evis_histo = Evis_histo_without_eff * cut_efficiency / 100.0
# number of simulated IBD-like events (cut efficiencies are considered):
number_IBDlike_events_simu = number_IBDlike_events_simu_without_eff * cut_efficiency / 100.0
print(
    "number of IBD-like events from simulation (with cut efficiency) = {0:.2f}"
    .format(number_IBDlike_events_simu))
""" Event rate calculation: """
# calculate the theoretical event rate in NC events/sec in JUNO for neutrino energies from 0 MeV to 10 GeV (float)
# (event_rate = A * (flux_nue*xsec_nue + flux_nuebar*xsec_nuebar + flux_numu*xsec_numu + flux_numubar*xsec_numubar)):
event_rate = NC_background_functions.event_rate(bin_width_energy, r_cut,
                                                output_path, PLOT_FLUX,
                                                SHOW_FLUXPLOT, SAVE_FLUXPLOT,
                                                PLOT_EVT_RATE, SHOW_EVT_RATE,
                                                SAVE_EVT_RATE)

# number of NC events in JUNO after 10 years:
number_NC_events_JUNO = event_rate * time_seconds

# number of IBD-like events in JUNO after 10 years (cut efficiencies are considered):
number_IBDlike_events_JUNO = int(
    number_NC_events_JUNO * number_IBDlike_events_simu / number_NC_events_simu)

# normalize the spectrum of IBD-like events to the spectrum, JUNO will measure after 10 years (cut efficiencies are
# considered):
Evis_histo_JUNO = float(number_IBDlike_events_JUNO) / float(
    number_IBDlike_events_simu) * Evis_histo
""" display simulated spectrum: """
Esempio n. 2
0
)
plt.xlim(xmin=E_vis_min, xmax=E_vis_max)
plt.ylim(ymin=0.0)
plt.legend()
if SHOW_SIMU_SPECTRUM:
    plt.show()
else:
    plt.close(h3)
""" Event rate calculation: """
# path, where plots are saved:
output_path = "/home/astro/blum/juno/atmoNC/data_NC/output_detsim/"
# calculate the theoretical event rate in events/sec for neutrino energies from 0 MeV to 10 GeV (float)
# (event_rate = A * (flux_nue*xsec_nue + flux_nuebar*xsec_nuebar + flux_numu*xsec_numu + flux_numubar*xsec_numubar)):
event_rate = NC_background_functions.event_rate(interval_energy, R_cut_meter,
                                                output_path, PLOT_FLUX,
                                                SHOW_FLUXPLOT, SAVE_FLUXPLOT,
                                                PLOT_EVT_RATE, SHOW_EVT_RATE,
                                                SAVE_EVT_RATE)

# This event rate (event_rate) corresponds to the number of simulated events (number_events) per time "time" ("time" is
# unknown). The time "time, in which 'number_events' NC interactions proceed (stattfinden), is given by
# number_events/event_rate, so number of simulated NC events / event rate.
# time in seconds (float):
time = number_events / event_rate

# number of NC interactions during time exposure (normally 10 years) (float):
number_NC_interaction_exposure = event_rate * time_exposure_sec

# number of IBD-like events of the NC interactions during time exposure (float):
number_IBD_exposure = number_NC_interaction_exposure * number_IBDevts / number_events
print("number of IBD-like events after {0:d} years = {1:.2f}".format(