script for convert .t3pa files to .t3pa_cls
.t3pa file example:
Index $\quad$ Matrix $\quad$ Index $\quad$ ToA $\quad$ ToT $\quad$ FToA $\quad$ Overflow
0 $\quad$ 4574 $\quad$ 832 $\quad$ 29 $\quad$ 6 $\quad$ 0
1 $\quad$ 4831 $\quad$ 832 $\quad$ 35 $\quad$ 7 $\quad$ 0
2 $\quad$ 4575 $\quad$ 832 $\quad$ 100 $\quad$ 8 $\quad$ 0
3 $\quad$ 31031 $\quad$ 1745 $\quad$ 22 $\quad$ 11 $\quad$ 0
.
.
.
.t3pa_cls file example:
% Index $\quad$ Matrix Index $\quad$ [ RowNo, ClmNo ] $\quad$ ToA $\quad$ FToA $\quad$ ( ToA_in_ns ) $\quad$ ToT ( ToT_in_keV ) $\quad$ Overflow
# 1, $\quad$ Nunmasked = 3, $\quad$ Nmasked = 0, $\quad$ Ntot = 3 # Tfirst = 2.0787500000000000e+04 ns, $\quad$ Tlast = 2.0790625000000000e+04 ns, $\quad$ dT = 3.125000 ns, $\quad$ Etot = 64.428148 keV
2 $\quad$ 4575 $\quad$ [ 17, 223 ] $\quad$ 832 $\quad$ 8 $\quad$ ( 2.0787500000000000e+04 ns ) $\quad$ 100 $\quad$ ( 37.867914 keV ) $\quad$ 0
1 $\quad$ 4831 $\quad$ [ 18, 223 ] $\quad$ 832 $\quad$ 7 $\quad$ ( 2.0789062500000000e+04 ns ) $\quad$ 35 $\quad$ ( 14.733453 keV ) $\quad$ 0
0 $\quad$ 4574 $\quad$ [ 17, 222 ] $\quad$ 832 $\quad$ 6 $\quad$ ( 2.0790625000000000e+04 ns ) $\quad$ 29 $\quad$ ( 11.826781 keV ) $\quad$ 0
# 2, $\quad$ Nunmasked = 3, $\quad$ Nmasked = 0, $\quad$ Ntot = 3 # Tfirst = 4.3601562500000000e+04 ns, $\quad$ Tlast = 4.3607812500000000e+04 ns, $\quad$ dT = 6.250000 ns, $\quad$ Etot = 63.577435 keV
5 $\quad$ 30775 $\quad$ [ 120, 55 ] $\quad$ 1745 $\quad$ 15 $\quad$ ( 4.3601562500000000e+04 ns ) $\quad$ 99 $\quad$ ( 37.617059 keV ) $\quad$ 0
4 $\quad$ 30776 $\quad$ [ 120, 56 ] $\quad$ 1745 $\quad$ 13 $\quad$ ( 4.3604687500000000e+04 ns ) $\quad$ 44 $\quad$ ( 14.715446 keV ) $\quad$ 0
3 $\quad$ 31031 $\quad$ [ 121, 55 ] $\quad$ 1745 $\quad$ 11 $\quad$ ( 4.3607812500000000e+04 ns ) $\quad$2 2 $\quad$ ( 11.244929 keV ) $\quad$ 0
.
.
.
import numpy as np
import math
#import pandas as pd
import matplotlib.pyplot as plt
import matplotlib.cm as cm
#from matplotlib.mlab import griddata
from urllib.error import HTTPError # recognise the error stemming from missing data
#import urllib
import urllib.request
t3pa2cls_XII - upravena fce energy(a, b, c, t, ToT, pocet_udalosti, RowNo, ClmNo) - nyni je se pocita i s pripadem "nan" t3pa2cls_XV_pc - zkousim vyzobat vysoke energie (jednotlive interakce) - funkce single_interaction. Dale delam prumernou velikost stopy stopy interakce pro danou energii - funkce size_of_interactions_average. Dale delam spektra 2 casti vyboje podle zadaneho casu - primarne pro double breakdown, tj. funkce energy_spectra_doublebreakdown
#Define an exception which will be raised if the data is missing and stop the notebook execution
class StopExecution(Exception):
def _render_traceback_(self):
pass
#shot_no = 44395 #test discharge for which the notebook will definitely work
shot_no = 44852
shot = shot_no
identifier='H03-W0051_shot_'+str(shot)+'_450V'
detector = 'H03-W0051'
ds = np.DataSource('/tmp') # temporary storage for downloaded files
scalars_URL = 'http://golem.fjfi.cvut.cz/shots/{shot_no}/Diagnostics/PlasmaDetection/Results/{name}'
def get_scalar(shot_no, name):
return float(ds.open(scalars_URL.format(shot_no=shot_no, name=name)).read())
t_plasma_start = get_scalar(shot_no, 't_plasma_start')
t_plasma_end = get_scalar(shot_no, 't_plasma_end')
is_plasma = get_scalar(shot_no, 'b_plasma')
def get_file(shot, identifier):
#Pick the discharge to analyse
URL = 'http://golem.fjfi.cvut.cz/shots/{shot}/Diagnostics/TimepixDetector/H03/{identifier}.t3pa'
url = URL.format(shot=shot, identifier=identifier)
try:
file_name_t3pa=url
with urllib.request.urlopen(file_name_t3pa) as ft3pa:
line = ft3pa.readline()
line = line.decode('utf‐8')
ft3pa.close
except HTTPError:
print('File not found at %s. Aborting notebook execution.' % url)
raise StopExecution
return file_name_t3pa
def get_file_calib(name_calib):
#Pick the discharge to analyse
URL = 'http://golem.fjfi.cvut.cz/shots/{shot}/Diagnostics/TimepixDetector/calib_matrix_H03/{name_calib}.txt'
url = URL.format(shot=shot, name_calib=name_calib)
#print(url)
try:
file_calib=url
with urllib.request.urlopen(file_calib) as calib:
line = calib.readline()
line = line.decode('utf‐8')
calib.close
except HTTPError:
print('File not found at %s. Aborting notebook execution.' % url)
raise StopExecution
return file_calib
def load_calib(file_calib):
with urllib.request.urlopen(file_calib) as fc:
calib=[] #vytvoreni 1D pole
for i in range(0,256): #tj. rozsah 0-255
temp = [] # docasne pole
for j in range(0,256):
temp.append(0) #naplneni docasneho pole 0
calib.append(temp) #naplneni pole a[] docasnym polem temp
for i in range(0,256): #nacteni calib matice do pole calib
line = fc.readline()
line = line.decode('utf‐8')
word=line.strip().split(' ')
for j in range(0,256):
#calib[i][j]=float(word[j]) #i = radek, j = sloupec0
calib[j][i]=float(word[j]) #j = radek, i = sloupec0 - pouze pro stavajici kalibraci - verze XV
fc.close
return calib
def load_t3pa_file(file_t3pa):
index=[]
matrix_index=[]
ToA=[]
ToT=[]
FToA=[]
overflow=[]
pocet_udalosti = 0
with urllib.request.urlopen(file_t3pa) as ft3pa:
line = ft3pa.readline()
line = line.decode('utf‐8')
while True:
line = ft3pa.readline()
line = line.decode('utf‐8')
word=line.strip().split('\t') #v t3pa souboru je oddelovac \t
if line == '':
break
index.append(word[0])
matrix_index.append(word[1])
ToA.append(float(word[2]))
ToT.append(float(word[3]))
FToA.append(float(word[4]))
overflow.append(float(word[5]))
pocet_udalosti = pocet_udalosti + 1
ft3pa.close
return index, matrix_index, ToA, ToT, FToA, overflow, pocet_udalosti
def noise(index, matrix_index, ToA, ToT, FToA, overflow, pocet_udalosti): #tuto fci nemus9m explicitn2 volat - volam ji v fci load_t3pa
pocet=int(0) #pocet sumicich pixelu
konst=int(len(index)/1000)+1
noise_matrix_index=[]
for i in range(0,konst):
pom = [] # pomocne pole
k=0 #pomocna promenna - udava, kolik je v czklu ve skutecnosti udalosti - aby nebyla chyba 'list index out of range'
for j in range(0,1001):
if i*1000+j>=len(index):
break
pom.append(matrix_index[i*1000+j])
k=k+1
for m in range(0,k):
count=int(0) #pocet vvyskytu stejneho matrix index behem 1000 udalosti
index_=int(-1) #budu testovat, jestli pixel na ktery koukam je sumici (abych ho nezapocital 2x)
for p in range(0,pocet):
#index=int(p)
if pom[m]==noise_matrix_index[p]:
index_=p #pixel na ktery jsem uz koukal a byl sumici
break
if index_ >=0 and pom[m]==noise_matrix_index[index_]:
continue
for l in range(0,k):
if pom[m]==pom[l]:
count=count+1
####podminka na sumici pixely
if count>=50: #kdyz se pixel vyskytne behem tisice udalosti vicekrat nez toto cislo, je sumici
noise_matrix_index.append(pom[m])
#noise_matrix_index[pocet]=pom[i]
pocet=pocet+1
pom.clear()
pocet_udalosti=len(index)
for n in range (0,pocet_udalosti):
for o in range(0,len(noise_matrix_index)):
if n >=pocet_udalosti:
break
if(matrix_index[n]==noise_matrix_index[o]):
del matrix_index[n]
del index[n]
del ToA[n]
del ToT[n]
del FToA[n]
del overflow[n]
pocet_udalosti=pocet_udalosti-1
continue
return pocet_udalosti,index, matrix_index, ToA, ToT, FToA, overflow
def t3pa_data(pocet_udalosti,index, matrix_index, ToA, ToT, FToA, overflow):
#rovnou vyhodim sumici pixely
pocet_udalosti,index, matrix_index, ToA, ToT, FToA, overflow=noise(index, matrix_index, ToA, ToT, FToA, overflow, pocet_udalosti)
RowNo=[]
ClmNo=[]
for i in range(0,len(matrix_index)):
#RowNo.append(int(int(matrix_index[i]))//int(256))
#ClmNo.append(int(int(matrix_index[i]))%int(256))
ClmNo.append(int(int(matrix_index[i]))//int(256)) #ver XV - bude pro novou kalibraci - nyn9 to bere 3patnou kalibraci jednotlivych pixelu (cislovani radku a sloupcu stejne jako v pixetu)
RowNo.append(int(int(matrix_index[i]))%int(256)) ##ver XV - bude super pro novou kalibraci - odpovida radkum a sloupcum v pixetu. Nyni bere spatne kalibrace pixelu (viz fce load_calib)
return index, matrix_index, ToA, ToT, FToA, overflow, pocet_udalosti, RowNo, ClmNo
def hit_map(detector,hit_map_fig,RowNo,ClmNo):
plt.hist2d(RowNo,ClmNo,bins=(256,256),cmap='Blues')
cb=plt.colorbar()
cb.set_label('Counts in pixel')
plt.xlabel('x [pixel]')
plt.ylabel('y [pixel]')
plt.title(detector)
plt.savefig(hit_map_fig, dpi = 1000)
return
def energy(a, b, c, t, ToT, pocet_udalosti, RowNo, ClmNo):
E=[] #energy in keV
#for i in range (0,pocet_udalosti):
pom=0
for i in range (0,len(ToT)):
Sqrt=float(0.0)
e1=float(0.0)
e2=float(0.0)
# promenna sqrt je vnitrek odmocniny
Sqrt = (((float(b[RowNo[i]][ClmNo[i]])+float(a[RowNo[i]][ClmNo[i]])*float(t[RowNo[i]][ClmNo[i]])-float(ToT[i])))*(((float(b[RowNo[i]][ClmNo[i]])+float(a[RowNo[i]][ClmNo[i]])*float(t[RowNo[i]][ClmNo[i]])-float(ToT[i])))) + (float(4)*float(a[RowNo[i]][ClmNo[i]])*float(c[RowNo[i]][ClmNo[i]]))) #zmena oproti verzi VI
if float(Sqrt)<float(0):
E.append(float(0))
else:
'''
V kalibracni matici a se obcas vyskytne 0 -> ve vypoctu energie
je tim padem deleni nulou -> energie diverguje. Jak to vyresit?
zatim polozim energii = 0 (kdyz a=0), pak se uvidi
nakonec udelam limitu vyrazu energie pro a->0 (L'hopital)
'''
if a[RowNo[i]][ClmNo[i]]==0:
e1=((float(t[RowNo[i]][ClmNo[i]]))/float(2)) + ((((float(b[RowNo[i]][ClmNo[i]])+float(a[RowNo[i]][ClmNo[i]])*float(t[RowNo[i]][ClmNo[i]])-float(ToT[i]))*(float(t[RowNo[i]][ClmNo[i]]))) - 2*(float(c[RowNo[i]][ClmNo[i]])))/(float(2)*np.sqrt(float(Sqrt))))
e2=((float(t[RowNo[i]][ClmNo[i]]))/float(2)) - ((((float(b[RowNo[i]][ClmNo[i]])+float(a[RowNo[i]][ClmNo[i]])*float(t[RowNo[i]][ClmNo[i]])-float(ToT[i]))*(float(t[RowNo[i]][ClmNo[i]]))) - 2*(float(c[RowNo[i]][ClmNo[i]])))/(float(2)*np.sqrt(float(Sqrt))))
else:
e1=((-(float(b[RowNo[i]][ClmNo[i]]) - (float(a[RowNo[i]][ClmNo[i]])*float(t[RowNo[i]][ClmNo[i]]))-float(ToT[i])))+np.sqrt(float(Sqrt)))/(float(2)*float(a[RowNo[i]][ClmNo[i]]))
e2=((-(float(b[RowNo[i]][ClmNo[i]]) - (float(a[RowNo[i]][ClmNo[i]])*float(t[RowNo[i]][ClmNo[i]]))-float(ToT[i])))-np.sqrt(float(Sqrt)))/(float(2)*float(a[RowNo[i]][ClmNo[i]]))
if a[RowNo[i]][ClmNo[i]]<0:
e1=-1
e2=-1
if math.isnan(e1):
e1=-1
if math.isnan(e2):
e2=-1
if e1<0 and e2<0:
E.append(float(0))
if e1>=0 and e1>e2:
E.append(float(e1))
if e2>=0 and e2>e1:
E.append(float(e2))
if e1>=0 and e2==e1:
E.append(float(e1))
return E
def Time(ToA, FToA, pocet_udalosti, RowNo, ClmNo):
T=[] #time in ns
for i in range (0,pocet_udalosti):
Time=float(0.0)
Time=(float(ToA[i])-((float(FToA[i])/float(16))))*float(25)
T.append(float(Time))
return T
def Timewalk_parameters_Si():
#SI - korekce na TimeWalk - parametry
A = -1.21988
B = 4.33638
C = 29.5075
D = 1
sigma_A=0.7013
sigma_B=0.1366
sigma_C=4.753
sigma_D=0
return A, B, C, D, sigma_A, sigma_B, sigma_C, sigma_D
def Timewalk(E,T):
i=0
A, B, C, D, sigma_A, sigma_B, sigma_C, sigma_D = Timewalk_parameters_Si()
while i < len(T):
timewalk=float(0)
timewalk = (C / (E[i] - B)) + A
if(timewalk<0):
timewalk=0
T[i]=T[i]-timewalk
i=i+1
return E,T
def remove_interactions_with_zero_energy(index, matrix_index, ToA, ToT, FToA, overflow, RowNo, ClmNo, E, T):
i=0
treshold=5.015347
while i < len(T):
if E[i]<treshold: #E[i] < energy treshold
index.pop(i)
matrix_index.pop(i)
ToA.pop(i)
ToT.pop(i)
FToA.pop(i)
overflow.pop(i)
RowNo.pop(i)
ClmNo.pop(i)
E.pop(i)
T.pop(i)
continue
i=i+1
return index, matrix_index, ToA, ToT, FToA, overflow, RowNo, ClmNo, E, T
def clustering_new(index, matrix_index, ToA, ToT, FToA, overflow, RowNo, ClmNo, E, T):
dT=float(50)
indexCl, TCl,ECl, matrix_indexCl, ToACl,ToTCl,FToACl,RowNoCl,ClmNoCl,overflowCl=[],[],[],[],[],[],[],[],[],[]
StartLastElem=len(T)-1
indexCl.append(int(index[StartLastElem]))
TCl.append(float(T[StartLastElem]))
ECl.append(float(E[StartLastElem]))
matrix_indexCl.append(int(matrix_index[StartLastElem]))
RowNoCl.append(int(RowNo[StartLastElem]))
ClmNoCl.append(int(ClmNo[StartLastElem]))
ToACl.append(float(ToA[StartLastElem]))
ToTCl.append(float(ToT[StartLastElem]))
FToACl.append(float(FToA[StartLastElem]))
overflowCl.append(float(overflow[StartLastElem]))
del index[StartLastElem]
del T[StartLastElem]
del E[StartLastElem]
del matrix_index[StartLastElem]
del RowNo[StartLastElem]
del ClmNo[StartLastElem]
del ToA[StartLastElem]
del ToT[StartLastElem]
del FToA[StartLastElem]
del overflow[StartLastElem]
j=1
pom=float(TCl[0]+dT)
while(j >0):
if(len(T) == 0):
break
k=0
j=0
while (k<=(len(TCl)-1)):
i=len(T)-1
if(len(T) == 0):
break
pocet_sousedu=0 #pocet sousednich pixelu - mohou byt maximalne 4
delka=0
# verze X
count=0 #pomocna promanna, kterou urcuji, ze se ma nasledujici cyklus while projit jeste jednou, pokud je i = -1
while(float(T[i])<=(pom)):
delka=delka+1
if(((((int(RowNoCl[k]))==(int(RowNo[i])+1))or((int(RowNoCl[k]))==(int(RowNo[i])-1))) and ((int(ClmNoCl[k]))==(int(ClmNo[i])))) or (((int(RowNoCl[k]))==(int(RowNo[i]))) and (((int(ClmNoCl[k]))==(int(ClmNo[i])+1))or((int(ClmNoCl[k]))==(int(ClmNo[i])-1))))):
#beru jen pixely, které mají společnou jednu stranu.
#pixely, kter0 spolu sousedí přes roh neuvažuji
indexCl.append(int(index[i]))
TCl.append(float(T[i]))
ECl.append(float(E[i]))
matrix_indexCl.append(int(matrix_index[i]))
RowNoCl.append(int(RowNo[i]))
ClmNoCl.append(int(ClmNo[i]))
ToACl.append(float(ToA[i]))
ToTCl.append(float(ToT[i]))
FToACl.append(float(FToA[i]))
overflowCl.append(float(overflow[i]))
# Removes i-th Row
del index[i]
del T[i]
del E[i]
del matrix_index[i]
del RowNo[i]
del ClmNo[i]
del ToA[i]
del ToT[i]
del FToA[i]
del overflow[i]
j=j+1
i=len(T)-1
pocet_sousedu=pocet_sousedu+1
if(len(T) == 0):
break
if(pocet_sousedu==4):
break
continue
i=i-1
if(i==-1): # verze X
count=count+1
if(i<0 and len(T)>0): # verze X
i=0
if(count>1):
break
if(i>=len(T)):
break
k=k+1
if(len(TCl)>2):
indexCl, TCl, ECl, matrix_indexCl, RowNoCl, ClmNoCl, ToACl, ToTCl, FToACl, overflowCl = insertionSort(indexCl, TCl, ECl, matrix_indexCl, RowNoCl, ClmNoCl, ToACl, ToTCl, FToACl, overflowCl)
return T, indexCl,TCl, ECl, matrix_indexCl, RowNoCl, ClmNoCl, ToACl, ToTCl, FToACl, overflowCl
def insertionSort(indexCl, TCl, ECl, matrix_indexCl, RowNoCl, ClmNoCl, ToACl, ToTCl, FToACl, overflowCl):
# Function to do insertion sort
# Traverse through 1 to len(arr)
for i in range(1, len(TCl)):
key = TCl[i]
# Move elements of arr[0..i-1], that are
# greater than key, to one position ahead
# of their current position
#ostatni
key1 = indexCl[i]
key2 = ECl[i]
key3 = matrix_indexCl[i]
key4 = RowNoCl[i]
key5 = ClmNoCl[i]
key6 = ToACl[i]
key7 = ToTCl[i]
key8 = FToACl[i]
key9 = overflowCl[i]
j = i-1
while j >= 0 and key < TCl[j] :
TCl[j + 1] = TCl[j]
#ostatni
indexCl[j + 1] = indexCl[j]
ECl[j + 1] = ECl[j]
matrix_indexCl[j + 1] = matrix_indexCl[j]
RowNoCl[j + 1] = RowNoCl[j]
ClmNoCl[j + 1] = ClmNoCl[j]
ToACl[j + 1] = ToACl[j]
ToTCl[j + 1] = ToTCl[j]
FToACl[j + 1] = FToACl[j]
overflowCl[j + 1] = overflowCl[j]
j -= 1
TCl[j + 1] = key
#ostatni
indexCl[j + 1] = key1
ECl[j + 1] = key2
matrix_indexCl[j + 1] = key3
RowNoCl[j + 1] =key4
ClmNoCl[j + 1] = key5
ToACl[j + 1] = key6
ToTCl[j + 1] = key7
FToACl[j + 1] = key8
overflowCl [j + 1] = key9
return indexCl, TCl, ECl, matrix_indexCl, RowNoCl, ClmNoCl, ToACl, ToTCl, FToACl, overflowCl
def file_t3pa_cls_new(file_t3pa_cls,T):
with open(file_t3pa_cls, "w", encoding="utf-8") as t3pa_cls:
t3pa_cls.write('%\n')
t3pa_cls.write('% Index Matrix Index [ RowNo, ClmNo ] ToA FToA ( ToA_in_ns ) ToT ( ToT_in_keV ) Overflow\n')
t3pa_cls.write('\n')
i=1
T_first=[]
E_tot=[]
N_tot=[]
eventNo=0 #for high_energy_event function
while(len(T) > 0):
T, indexCl,TCl, ECl, matrix_indexCl, RowNoCl, ClmNoCl, ToACl, ToTCl, FToACl, overflowCl = clustering_new(index, matrix_index, ToA, ToT, FToA, overflow, RowNo, ClmNo, E, T)
Tfirst=float(TCl[0])
Tlast=float(TCl[len(TCl)-1])
dT=Tlast-Tfirst
Etot=float(0)
for k in range(0,len(TCl)):
Etot=Etot+float(ECl[k])
T_first.append(float(Tfirst))
dT=Tlast-Tfirst
E_tot.append(float(Etot))
N_tot.append(len(TCl)) #new in ver. XV
t3pa_cls.write('# '+str(i)+', Nunmasked = '+str(len(TCl))+', Nmasked = 0, Ntot = '+str(len(TCl))+'\n')
t3pa_cls.write('# Tfirst = '+str(Tfirst)+' ns, Tlast = '+str(Tlast)+' ns, dT = '+str(dT)+' ns, Etot = '+str(Etot)+' keV\n')
for j in range(0,len(TCl)):
t3pa_cls.write(str(indexCl[j])+' '+str(matrix_indexCl[j])+' [ '+str(RowNoCl[j])+', '+str(ClmNoCl[j])+' ] '+str(ToACl[j])+' '+str(FToACl[j])+' ( '+str(TCl[j])+' ns ) '+str(ToTCl[j])+' ( '+str(ECl[j])+' keV ) '+str(overflowCl[j])+'\n')
t3pa_cls.write('\n')
#eventNo=single_interaction(eventNo,Etot, Tfirst, ECl, TCl, RowNoCl, ClmNoCl,path)
i=i+1
t3pa_cls.close
return T_first, E_tot, N_tot
def energy_spectrum_in_time(Tfirst, Etot): #dela histogram - energie zaznamenana v case
pom = 0
dt=100 #(ns) time width of 1 bin
T_first=0 #cas, kdy prisel trigger a yacalo mereni
T_last=(max(Tfirst)) #posledni z Tfirst
Delta_T = T_last - T_first
poc = int(int(Delta_T) / float(dt)) + 1 #pocet casovych oken
T_int_first=[] #cas
E=[] #energie
for i in range(0,poc):
T_int_first.append((i*dt) + dt/2)
E.append(0)
#XII
for j in range(0,len(Tfirst)):
time_index=0
time_index=int(((Tfirst[j]-T_first)/dt))
if float(Tfirst[j]-T_first) >= (T_int_first[time_index] - dt / 2) and float(Tfirst[j]-T_first) < (T_int_first[time_index] + dt / 2):
E[time_index]=float(E[time_index])+float(Etot[j])
pom=pom+1
for l in range(0,len(T_int_first)):
T_int_first[l]=T_int_first[l]+T_first
caption, T_int_first = energy_in_time_hist(T_int_first, E, figure_E_in_time_hist, t_plasma_start, t_plasma_end, is_plasma, dt)
return dt, caption, T_int_first, E
def energy_in_time_hist(T_int_first, E,figure_E_in_time_hist, t_plasma_start, t_plasma_end, is_plasma, dt):
plt.rcParams.update({'font.size': 20})
fig, ax = plt.subplots(figsize =(10, 7))
for k in range(0,len(T_int_first)):
T_int_first[k] = T_int_first[k] / 1000000
plt.plot(T_int_first, E, drawstyle='steps-mid')
plt.title(detector+', #'+str(shot_no))
plt.xlabel('Time [ms]')
plt.ylabel('Energy [keV]')
if is_plasma == 1:
for t in (t_plasma_start, t_plasma_end):
plt.axvline(t, color='k', linestyle='--')
plt.xlim([0, (t_plasma_start + t_plasma_end)])
else:
plt.xlim(0,)
plt.ylim(0,) #10 000 keV
plt.savefig(figure_E_in_time_hist, dpi = 1000)
caption = '# x = time in ms, count = energy in keV, dT= '+str(dt)+' ns'
return caption, T_int_first
def hits_in_time_hist_new(T, dt, t_plasma_start, t_plasma_end, is_plasma,figure_count_in_time_hist):
pom = 0
T_first=0 #cas, kdy prisel trigger a yacalo mereni
T_last=(max(T)) #posledni z Tfirst
Delta_T = T_last - T_first
poc = int(int(Delta_T) / float(dt)) + 1 #pocet casovych oken
T_hit=[] #cas
count=[] #energie
for i in range(0,poc):
T_hit.append((i*dt) + dt/2)
count.append(0)
for j in range(0,len(T)):
time_index=0
time_index=int(((T[j]-T_first)/dt))
k=time_index
for j in range(0,len(T)):
time_index=0
time_index=int(((T[j]-T_first)/dt))
if float(T[j]-T_first) >= (T_hit[time_index] - dt / 2) and float(T[j]-T_first) < (T_hit[time_index] + dt / 2):
count[time_index] = count[time_index] + 1
pom=pom+1
for l in range(0,len(T_hit)):
T_hit[l]=T_hit[l]+T_first
plt.rcParams.update({'font.size': 20})
fig, ax = plt.subplots(figsize =(10, 7))
for k in range(0,len(T_hit)):
T_hit[k] = T_hit[k] / 1000000
#plt.plot(T_hit, count)
plt.plot(T_hit, count, drawstyle='steps-mid')
plt.title(detector+', #'+str(shot_no))
plt.xlabel('Time [ms]')
plt.ylabel('Count')
if is_plasma == 1:
for t in (t_plasma_start, t_plasma_end):
plt.axvline(t, color='k', linestyle='--')
plt.xlim([0, (t_plasma_start + t_plasma_end)])
else:
plt.xlim(0,)
plt.ylim(0,) #10 000 keV
plt.savefig(figure_count_in_time_hist, dpi = 1000)
caption = '# x = time in ms, dT= '+str(dt)+' ns'
return caption, T_hit,count
def energy_spectrum(Etot):
E_min=0
dE=5 #keV
E_max=max(Etot)
pocet=(E_max//dE) + 3
pocet=int(pocet)
E_max=float(dE*pocet)
xle=[]
xre=[]
xmean=[]
for p in range (0,pocet):
xle.append(E_min + (p * (E_max - E_min)) / pocet)
xre.append(xle[p]+dE)
xmean.append((xle[p] + xre[p]) / 2)
count=[]
for l in range(0,pocet):
count.append(0)
#XII
for i in range(0,len(Etot)):
E_index=int(((Etot[i]-E_min)/dE))
if ((xle[E_index] <= Etot[i]) and (Etot[i] < xre[E_index])):
count[E_index]=count[E_index]+1
plt.rcParams.update({'font.size': 20})
fig, ax = plt.subplots(figsize =(10, 7))
#ax.hist(Etot, bins = xle)
plt.fill_between(xmean, count,step='mid') #pre mid post
plt.plot(xmean, count, drawstyle='steps-mid')
plt.title(detector+', #'+str(shot_no))
plt.xlabel('Energy [keV]')
plt.ylabel('Count')
plt.xlim(0,)
ax.set_yscale('log') #log scale y
caption = '# x = energy in keV, dE= '+str(dE)+' keV'
plt.savefig(figure_E_hist, dpi = 1000)
return caption, xmean,count, xle, Etot
def hist_file(file_hist, xmean, count, caption ):
with open(file_hist, "w", encoding="utf-8") as hist:
hist.write('#\n')
hist.write('#'+str(caption)+'\n')
hist.write('# x_mean count\n')
hist.write('\n')
for m in range(0,len(xmean)):
hist.write(str(xmean[m])+' '+str(count[m])+'\n')
hist.close
return T_first, E_tot
def multiplot(icon_fig, x1,y1,x2,y2):
plt.rcParams.update({'font.size': 20})
fig, ax = plt.subplots(nrows=2,figsize =(10, 7))
ax[0].plot(x1, y1, drawstyle='steps-mid')
ax[0].set_xlabel('Time [ms]')
ax[0].set_ylabel('Energy [keV]')
if is_plasma == 1:
for t in (t_plasma_start, t_plasma_end):
ax[0].axvline(t, color='k', linestyle='--')
ax[0].set_xlim([0, (t_plasma_start + t_plasma_end)])
else:
ax[0].set_xlim(0,)
ax[0].set_ylim(0,) #keV
#ax[1].hist(y2, bins = x2)
ax[1].fill_between(x2, y2,step='mid') #pre mid post
ax[1].plot(x2, y2, drawstyle='steps-mid')
ax[1].set_xlabel('Energy [keV]')
ax[1].set_ylabel('Count')
ax[1].set_xlim(0,)
#ax[1].set_ylim(0,)
ax[1].set_yscale('log') #log scale y
fig.subplots_adjust(hspace=0.3)
plt.savefig(icon_fig, dpi = 1000)
return
def single_interaction(eventNo,Etot, Tfirst, ECl, TCl, RowNoCl, ClmNoCl,path): # ver XV
#tuto funkci volam ve funkci file_t3pa_cls_new(file_t3pa_cls,T):
#This function is calling in function file_t3pa_cls_new(file_t3pa_cls,T)
high_E = 1500 #[keV] - zadani, jaka energie je pro me vysoka
if(Etot>=high_E or len(ECl)>15):
#if (len(ECl)>15): #len(ECl) = pocet pixelu dane interakce
print("Total energy of track: "+str(Etot)+" keV\n")
A, B, C, D, sigma_A, sigma_B, sigma_C, sigma_D = Timewalk_parameters_Si()
######################
#SI - rekonstrukce z(t) - parametry
a=0.0193947
b=-0.0273934
sigma_a=0.0004163
sigma_b=0.009832
#######################
time=[]
sigma_time=[]
time_min = []
time_max=[]
z_rec=[]
z_rec_min=[]
z_rec_max=[]
sigma_z_rec=[]
for i in range(0, len(TCl)):
time.append(TCl[i] - Tfirst)
#chyba urceni casu = chyba timewalk ->
sigma_time.append(np.sqrt(((sigma_C / (pow((ECl[i] - B), D)))*(sigma_C / (pow((ECl[i] - B), D)))) + (((sigma_B*C*D) / (pow((ECl[i] - B), (D + 1))))*((sigma_B*C*D) / (pow((ECl[i] - B), (D + 1))))) + (((sigma_D*C*math.log(ECl[i] - B)) / (pow((ECl[i] - B), D)))* ((sigma_D*C*math.log(ECl[i] - B)) / (pow((ECl[i] - B), D)))) + (sigma_A*sigma_A)))
time_min.append(time[i] - sigma_time[i])
time_max.append(time[i] + sigma_time[i])
#//
#//rekonstrukce hloubky interakce
z_rec.append(a * time[i] + (b))
sigma_z_rec.append(np.sqrt(((time[i]*time[i])*(sigma_a*sigma_a)) + (sigma_b*sigma_b) + (a*a)*(sigma_time[i]*sigma_time[i])))
z_rec_min.append(z_rec[i] - sigma_z_rec[i])
z_rec_max.append(z_rec[i] + sigma_z_rec[i])
#//
single_interaction_file=str(path)+'event'+str(eventNo)+'.txt'
single_interaction_2D_fig=str(path)+'2D_event'+str(eventNo)+'.png'
single_interaction_3D_fig=str(path)+'3D_event'+str(eventNo)+'.png'
with open(single_interaction_file, "w", encoding="utf-8") as f:
f.write('#\n')
f.write('# x_mean y_mean z_rec z_rec_min z_rec_max sigma_z_rec\n')
f.write('#E_tot='+str(Etot)+'\n')
f.write('\n')
for m in range(0,len(TCl)):
#print(str(RowNoCl[m])+' '+str(ClmNoCl[m])+' '+str(z_rec[m])+' '+str(z_rec_min[m])+' '+str(z_rec_max[m])+' '+str(sigma_z_rec[m])+' '+str(ECl[m])+'\n')
f.write(str(RowNoCl[m])+' '+str(ClmNoCl[m])+' '+str(z_rec[m])+' '+str(z_rec_min[m])+' '+str(z_rec_max[m])+' '+str(sigma_z_rec[m])+' '+str(ECl[m])+'\n')
f.close
############################### plot
#binwidth=1
if ((max(RowNoCl)-min(RowNoCl))>=(max(ClmNoCl)-min(ClmNoCl))):
rang=max(RowNoCl)-min(RowNoCl)
#bins=(range((min(RowNoCl)-1), (max(RowNoCl)+3), binwidth), range((min(ClmNoCl)-1), (min(ClmNoCl)+rang+3), binwidth))
x_min=min(RowNoCl)-1
x_max=max(RowNoCl)+2
y_min=min(ClmNoCl)-1
y_max=min(ClmNoCl)+rang+2
else:
rang = max(ClmNoCl)-min(ClmNoCl)
#bins=(range((min(RowNoCl)-1), (min(RowNoCl)+rang+3), binwidth), range((min(ClmNoCl)-1), (max(ClmNoCl)+3), binwidth))
x_min=min(RowNoCl)-1
x_max=min(RowNoCl)+rang+2
y_min=min(ClmNoCl)-1
y_max=max(ClmNoCl)+2
###############$$$$$$$$$$$$$$$$$$$$
rows, cols = (x_max-x_min, x_max-x_min)
#arrECl = [[0]*cols]*rows
arrECl= [[0] * cols for _ in range(rows)]
for i in range (x_min,x_max):
for j in range (y_min,y_max):
for k in range(0,len(RowNoCl)):
if ((i==RowNoCl[k]) and (j==ClmNoCl[k])):
#print(str(i)+" "+str(j)+" "+str(RowNoCl[k])+" "+str(ClmNoCl[k])+"\n")
arrECl[i-x_min][j-y_min]=ECl[k]
arrECl=np.transpose(arrECl)
arrECl[arrECl == 0] = np.nan
#2D plot
plt.imshow(arrECl,cmap='jet', interpolation='none', origin=[(x_min-0.2),(y_min-0.2)], aspect='equal', extent=[x_min-0.2,x_max,y_min-0.2,y_max])
###############$$$$$$$$$$$$$$$$$$$$
cb=plt.colorbar(pad=0.005)
plt.tick_params(axis="x",direction="in")
plt.tick_params(axis="y",direction="in")
cb.ax.tick_params(axis='y', direction='in')
cb.set_label('Energy in pixel [keV]')
plt.xlabel('x [pixel]')
plt.ylabel('y [pixel]')
plt.title('$E_{tot}$ = '+str(round(Etot, 2))+' keV, $N_{tot}$ = '+str(len(ECl)))
plt.savefig(single_interaction_2D_fig, dpi = 1000)
plt.show()
plt.close()
############################### plot
############## 3D plot
# Creating figure
fig = plt.figure(figsize = (16, 9))
ax = plt.axes(projection ="3d")
# Add x, y gridlines
ax.grid(b = True, color ='grey', #
linestyle ='-.', linewidth = 0.3,
alpha = 0.2)
# Creating plot
sctt = ax.scatter3D(RowNoCl, ClmNoCl, z_rec,
alpha = 0.8,
c = ECl,
cmap = 'jet',
s = 4000, #size of bubbles in plot
marker ='o')
plt.title('$E_{tot}$ = '+str(round(Etot, 2))+' keV, $N_{tot}$ = '+str(len(ECl)))
ax.set_xlabel('x [pixel]', fontweight ='bold')
ax.set_ylabel('y [pixel]', fontweight ='bold')
ax.set_zlabel('z [mm]', fontweight ='bold')
cb=fig.colorbar(sctt, ax = ax, shrink = 0.5,aspect = 10,pad=0.00005) #
cb.ax.tick_params(axis='y', direction='in')
cb.set_label('Energy in pixel [keV]', fontweight ='bold')
plt.savefig(single_interaction_3D_fig, dpi = 1000)
# show plot
plt.show()
plt.close()
############## 3D plot
eventNo=eventNo+1
return eventNo
def size_of_interactions_average(Etot, Ntot,file_hist): #ver XV
E_min=0
dE=5 #keV
E_max=max(Etot)
pocet=(E_max//dE) + 3
pocet=int(pocet)
E_max=float(dE*pocet)
xle=[]
xre=[]
xmean=[]
count=[]
nop=[] #number of pixels
nop_mean=[] #mean number of pixels in dE
sigma=[] #root mean square error of the mean - stredni kvadraticka chyba prumeru
for p in range (0,pocet):
xle.append(E_min + (p * (E_max - E_min)) / pocet)
xre.append(xle[p]+dE)
xmean.append((xle[p] + xre[p]) / 2)
count.append(0)
nop.append(0)
nop_mean.append(0)
sigma.append(0)
#XII
for i in range(0,len(Etot)):
E_index=int(((Etot[i]-E_min)/dE))
if ((xle[E_index] <= Etot[i]) and (Etot[i] < xre[E_index])):
count[E_index]=count[E_index]+1
nop[E_index]=nop[E_index]+Ntot[i] #ver XV
for l in range(0,pocet):
if nop[l]!=0:
nop_mean[l]=float(nop[l])/float(count[l])
#####Computing sigma
for i in range(0,len(Etot)):
E_index=int(((Etot[i]-E_min)/dE))
if ((xle[E_index] <= Etot[i]) and (Etot[i] < xre[E_index])):
if nop_mean[E_index]!=0:
sigma[E_index]=sigma[E_index]+((float(Ntot[i])-float(nop_mean[E_index]))*(float(Ntot[i])-float(nop_mean[E_index])))
for l in range(0,pocet):
if nop[l]!=0 and count[l]>1:
sigma[l]=np.sqrt(sigma[l]/(float(count[l])*(float(count[l])-1)))
if nop[l]!=0 and count[l]==1:
sigma[l]=10
#####Computing sigma
#####write to file
with open(file_hist, "w", encoding="utf-8") as hist:
hist.write('# x_mean [keV] mean_size_of_interaction [pixel] sigma_mean_size_of_interaction\n')
for m in range(0,len(xmean)):
hist.write(str(xmean[m])+' '+str(nop_mean[m])+' '+str(sigma[m])+'\n')
hist.close
#####write to file
plt.rcParams.update({'font.size': 20})
fig, ax = plt.subplots(figsize =(10, 7))
#plt.fill_between(xmean, nop,step='mid',color='blue', alpha=0.3) #pre mid post
#plt.fill_between(xmean, nop,step='mid') #pre mid post
plt.plot(xmean, nop_mean, drawstyle='steps-mid')
plt.errorbar(xmean, nop_mean, yerr = sigma,fmt ='.', linewidth=0.7)
plt.title(detector+', #'+str(shot_no))
plt.xlabel('Energy [keV]')
plt.ylabel('Average size of interaction [pixel]')
plt.xlim(0,500)
plt.ylim(0,17)
#ax.set_yscale('log') #log scale y
caption = '# x = energy in keV, dE= '+str(dE)+' keV'
plt.savefig(figure_size_interaction, dpi = 1000)
return
def energy_spectra_doublebreakdown(Etot, Tfirst, file_hist):
#this function separates discharge into two parts acording to time Tsep and creates energy spectrum for each part.
#This is for discharges with double brakdown
Tsep=14636000 # [ns]
E_min=0
dE=5 #keV
E_max=max(Etot)
pocet=(E_max//dE) + 3
pocet=int(pocet)
E_max=float(dE*pocet)
xle=[]
xre=[]
xmean=[]
for p in range (0,pocet):
xle.append(E_min + (p * (E_max - E_min)) / pocet)
xre.append(xle[p]+dE)
xmean.append((xle[p] + xre[p]) / 2)
count_first=[]
count_second=[]
for l in range(0,pocet):
count_first.append(0)
count_second.append(0)
#XII
for i in range(0,len(Etot)):
E_index=int(((Etot[i]-E_min)/dE))
if ((xle[E_index] <= Etot[i]) and (Etot[i] < xre[E_index])):
if(Tfirst[i]<Tsep):
count_first[E_index]=count_first[E_index]+1
else:
count_second[E_index]=count_second[E_index]+1
caption = '# x = energy in keV, dE= '+str(dE)+' keV'
with open(file_hist, "w", encoding="utf-8") as hist:
hist.write('#\n')
hist.write('#'+str(caption)+'\n')
hist.write('# x_mean count_before_2nd_breakdown count_2nd_breakdown\n')
hist.write('\n')
for m in range(0,len(xmean)):
hist.write(str(xmean[m])+' '+str(count_first[m])+' '+str(count_second[m])+'\n')
hist.close
plt.rcParams.update({'font.size': 20})
fig, ax = plt.subplots(figsize =(10, 7))
#plt.fill_between(xmean, count_first,step='mid') #pre mid post
plt.plot(xmean, count_first, label='Before 2nd breakdown', drawstyle='steps-mid')
plt.plot(xmean, count_second, label='2nd breakdown', drawstyle='steps-mid')
plt.legend(loc='best')
plt.title(detector+', #'+str(shot_no))
plt.xlabel('Energy [keV]')
plt.ylabel('Count')
plt.xlim(0,500)
ax.set_yscale('log') #log scale y
plt.savefig(figure_energy_spectra_doublebreakdown, dpi = 1000)
return
#soubory, ktere ctu
#read files
t3pa=get_file(shot, identifier)
name_calib='caliba'
caliba=get_file_calib(name_calib)
name_calib='calibb'
calibb=get_file_calib(name_calib)
name_calib='calibc'
calibc=get_file_calib(name_calib)
name_calib='calibt'
calibt=get_file_calib(name_calib)
#vytvorene soubory:
#created files
t3pa_cls= 'H03-W0051_shot_'+str(shot)+'_450V.t3pa_cls'
E_hist= 'H03-W0051_shot_'+str(shot)+'_450V_E_hist.txt'
E_in_time_hist= 'H03-W0051_shot_'+str(shot)+'_450V_discharge_energy.txt'
count_in_time_hist= 'H03-W0051_shot_'+str(shot)+'_450V_discharge_hits.txt'
size_interaction= 'H03-W0051_shot_'+str(shot)+'size_interaction.txt'
file_energy_spectra_doublebreakdown= 'H03-W0051_shot_'+str(shot)+'energy_spectra_doublebreakdown.txt'
#created figures
icon_fig='icon-fig'
figure_E_in_time_hist='discharge_energy'
figure_count_in_time_hist='discharge_hits'
figure_E_hist='Energy_spectrum'
hit_map_fig='hit-map'
figure_size_interaction= 'H03-W0051_shot_'+str(shot)+'size_interaction'
figure_energy_spectra_doublebreakdown= 'H03-W0051_shot_'+str(shot)+'energy_spectra_doublebreakdown'
#nactu jednotlive kalibracni matice - abych to nemusel delat v kazde funkci
a=load_calib(caliba)
b=load_calib(calibb)
c=load_calib(calibc)
t=load_calib(calibt)
#nactu a urcim jednotlive hodnoty - abych to nemusel delat v kazde funkci
index, matrix_index, ToA, ToT, FToA, overflow, pocet_udalosti = load_t3pa_file(t3pa)
index, matrix_index, ToA, ToT, FToA, overflow, pocet_udalosti, RowNo, ClmNo = t3pa_data(pocet_udalosti,index, matrix_index, ToA, ToT, FToA, overflow)
raw data
#hit map
hit_map(detector,hit_map_fig,RowNo,ClmNo)
Energy and time calculation from raw data.
E=energy(a, b, c, t, ToT, pocet_udalosti, RowNo, ClmNo)
T=Time(ToA, FToA, pocet_udalosti, RowNo, ClmNo)
index, matrix_index, ToA, ToT, FToA, overflow, RowNo, ClmNo, E, T = remove_interactions_with_zero_energy(index, matrix_index, ToA, ToT, FToA, overflow, RowNo, ClmNo, E, T)
E,T=Timewalk(E,T)
#sort by time
T, index, matrix_index, ToA, ToT, FToA, overflow, RowNo, ClmNo, E = (list(t) for t in zip(*sorted(zip(T, index, matrix_index, ToA, ToT, FToA, overflow, RowNo, ClmNo, E), reverse=True))) #serazeni od nejvetsiho po nejmensi
T_pom=T.copy()
#save to file
T_first, E_tot, Ntot = file_t3pa_cls_new(t3pa_cls,T)
dt, caption, T_int_first, E = energy_spectrum_in_time(T_first, E_tot)
hist_file(E_in_time_hist, T_int_first, E, caption);
([5356727.004834287, 5412437.5, 5412724.236069978, 5413212.089081489, 5452507.8125, 5506310.395061531, 5523897.5610526735, 5556264.013757781, 5563609.334413721, 5568065.5032075215, 5568117.341418395, 5568212.898875559, 5598303.759339977, 5607839.7085107695, 5617273.419326149, 5617793.75, 5618598.058157952, 5619641.090305967, 5731809.460820146, 5797154.39136749, 6019979.6875, 6178842.156730506, 6385717.1875, 6407283.70787121, 6413373.190051958, 6416339.0625, 6440596.066235717, 6444824.404978089, 6447893.175794366, 6567386.921481827, 6581158.256948133, 6581362.0199150685, 6581459.873822057, 6581573.584803856, 6582623.93567818, 6583136.704245793, 6625505.916505342, 6626415.446264924, 6627657.455054869, 6628691.229393056, 6634797.639417223, 6634804.6875, 6634949.850595625, 6635241.652302874, 6637199.277179419, 6637777.142762568, 6639304.6875, 6640178.125, 6641061.788756883, 6641839.203882026, 6680078.706455051, 6757820.696221837, 6758500.394687126, 6759179.6875, 6760634.2058227835, 6760662.539231905, 6763251.79385334, 6763272.072718127, 6763275.917799129, 6763522.727523747, 6764111.366977115, 6765460.9375, 6765549.263125735, 6767471.364310191, 6776241.854895551, 6777449.024916585, 6799166.759584791, 6881093.510545386, 6881881.642164879, 6903234.758357596, 6913000.0, 6919749.902682336, 6920603.488896889, 6922861.642965976, 6925774.835547088, 6926674.5077780895, 6927935.19819469, 6928581.665587935, 6938213.313344321, 6938247.610755668, 6944685.023375467, 6956443.605796732, 6958187.220684964, 6970862.355973403, 6971933.756800761, 6972684.952288593, 6980410.392754983, 6981762.609012001, 6982014.0625, 6984038.59555275, 6984045.3125, 7046102.830799229, 7056289.360195838, 7057360.9375, 7057472.421476544, 7058058.237065478, 7059331.408014607, 7059457.146678924, 7060747.829493654, 7064011.976842781, 7064736.887072117, 7064806.408529516, 7065073.4375, 7068518.428342672, 7073840.567616501, 7076910.833257483, 7076938.729475941, 7077614.0625, 7083772.339351821, 7086215.514415732, 7093140.625, 7157310.722434715, 7178068.75, 7188094.0469776215, 7189418.175682824, 7203830.744603644, 7206250.650820706, 7206382.8125, 7206559.079554168, 7206784.085241071, 7206915.625, 7207887.5, 7208681.208016071, 7214146.814933129, 7223889.528206746, 7240521.8720258325, 7262266.95985665, 7268490.085537349, 7272279.909991096, 7272314.474884368, 7276640.214824598, 7277800.314238586, 7370755.909209557, 7373013.909831344, 7375076.005995586, 7441832.4693415435, 7443645.461989808, 7449841.806984547, 7449871.898449208, 7451202.1625257805, 7451261.480398384, 7473810.323089484, 7591629.308209476, 7595509.375, 7659170.3125, 7687965.625, 7737012.5, 7738050.0, 7739556.904152181, 7739629.703595201, 7742153.379949709, 7749618.896220707, 7751801.285092634, 7754870.3125, 7755694.797378819, 7775051.77336465, 7776303.125, 7778237.5, 7781844.897420731, 7783434.767146574, 7784181.25, 7787835.525160363, 7812422.600508421, 7813728.122632602, 7816327.328043405, 7816643.75, 7817704.6875, 7818945.3125, 7825326.188672803, 7879115.87720442, 7883618.953000282, 7893863.856210309, 7893867.1875, 7911819.883063709, 7953670.3125, 7955866.350607039, 7957807.80150395, 7958040.625, 7965495.279613888, 7966928.913770086, 7969322.5846999595, 7970529.942486488, 7970533.753997719, 7970803.566754834, 7971238.675783872, 7982435.9375, 8021488.203267423, 8022391.639283832, 8022900.0, 8023159.375, 8023285.093359421, 8023404.6190544255, 8023586.526855242, 8023685.530304328, 8024177.172063752, 8025479.6875, 8026029.6875, 8026289.464285008, 8027480.817484384, 8028157.888580409, 8028823.788763495, 8029734.375, 8029785.170598705, 8029811.652328297, 8030388.772926005, 8030698.4375, 8030824.022780811, 8031397.922354737, 8032438.30995158, 8032699.470098844, 8033404.080401273, 8034111.00102973, 8034259.150689852, 8034946.06797733, 8035036.576489801, 8036673.209939736, 8039917.553008488, 8040132.8125, 8056235.9375, 8056237.599968048, 8056396.875, 8058678.8506355975, 8060251.815988842, 8060678.125, 8060898.484793781, 8060938.525335184, 8061234.375, 8062214.973219852, 8063993.75, 8064087.251304194, 8067204.05328359, 8075186.525583609, 8120651.225909826, 8133264.326428939, 8135929.985563106, 8139045.758811901, 8189457.332432603, 8196908.679689175, 8196918.75, 8198014.515066432, 8203362.938976419, 8203442.13084651, 8216580.168334588, 8219663.229172113, 8220094.547756197, 8220116.995343285, 8221006.608016464, 8257250.338714804, 8262801.5625, 8263624.616429675, 8268959.3429323705, 8269431.511652474, 8271823.4375, 8272420.714351522, 8273080.059228648, 8282841.408209785, 8283568.585706409, 8283881.715184148, 8284893.24815555, 8288034.1430885745, 8290337.230161628, 8306332.09810478, 8307232.8125, 8309153.90018271, 8340547.205849162, 8341348.4375, 8399568.984107459, 8403208.053864663, 8426646.462703198, 8433809.328216488, 8433813.588332182, 8435191.88478725, 8437885.340376219, 8444815.13217219, 8448508.40631809, 8449889.573850036, 8451107.8125, 8451536.961809816, 8452718.75, 8456215.287888309, 8462976.771234112, 8492846.773870451, 8494503.125, 8496007.047345852, 8498251.399731202, 8505915.315048017, 8505966.557892831, 8508305.506097147, 8509550.380510243, 8515701.94549958, 8528523.28265888, 8541859.375, 8545043.209533647, 8545855.965010455, 8546231.25, 8547358.01030741, 8549512.5, 8550069.417905482, 8550193.153885307, 8550204.825036008, 8550443.26000287, 8550591.42468856, 8552415.454190057, 8552825.931125253, 8554049.89420516, 8554220.3125, 8554378.155072466, 8555541.080871211, 8562293.594145898, 8567653.125, 8568321.875, 8569989.621554606, 8575500.922631133, 8576328.125, 8576343.75, 8589668.671338467, 8589731.217951333, 8591583.23513863, 8591666.254086608, 8593441.620816676, 8593515.68059628, 8595602.758051183, 8598477.47637535, 8604240.625, 8607042.1875, 8616064.0625, 8630235.607359521, 8630829.49500028, 8631848.4375, 8632360.565711958, 8632415.441074789, 8633033.04491448, 8638521.408571098, 8639004.9622293, 8652146.875, 8653815.667816726, 8656705.839896603, 8656829.273476351, 8657649.994063213, 8659086.876605209, 8659105.196528103, 8659545.3125, 8659566.095779046, 8659875.576065963, 8660263.863255054, 8662366.686212566, 8662796.576845536, 8664457.417338997, 8665380.093274446, 8665852.478229763, 8665998.41022549, 8666526.251762474, 8667580.852679728, 8667726.5625, 8668624.226875028, 8693212.5, 8718868.54619806, 8727568.777408568, 8729337.475126086, 8731105.050140414, 8736754.462282935, 8738747.717061957, 8738764.0625, 8743978.305839552, 8743987.160945522, 8753414.492357852, 8756755.713364234, 8760431.012678925, 8774360.718554065, 8775205.387743777, 8775763.557962166, 8776038.113216866, 8781720.233039109, 8784108.428672232, 8829831.25, 8848106.25, 8855524.274627216, 8857956.108438391, 8917198.4375, 8923723.4375, 8939228.125, 8968032.49184102, 8993998.623811249, 8994798.4375, 8997629.232695887, 9021356.43230678, 9029073.974179894, 9079715.625, 9081253.868423961, 9084804.919827227, 9087259.142455827, 9087746.281824294, 9151750.478577929, 9176490.613185164, 9204851.005319161, 9209728.860312594, 9211658.394538416, 9254101.715199197, 9269326.5625, 9271180.001726074, 9271385.9375, 9275095.189178327, 9362087.5, 9381250.043560483, 9402120.319640407, 9402347.251256373, 10261156.25, 10263960.074816708, 10267975.216479521, 10283688.488067705, 10348991.852806043, 10355395.915645422, 10369242.330339117, 10369244.258485507, 10401533.455605334, 10410799.416673984, 10414021.38958228, 10417435.336415194, 10417471.135799907, 10419012.5, 10420997.031156858, 10421175.0, 10421272.232490703, 10421506.25, 10422743.027804261, 10423434.359300498, 10425872.346938878, 10427473.624325365, 10427543.75, 10428926.976780703, 10429354.6875, 10431457.021339264, 10432050.874699201, 10433126.700821247, 10434318.10680712, 10450815.45595366, 358290559.3898266], [16.94617639403435, 48.47169926158175, 38.18990690195111, 34.64603535954055, 42.9015459459598, 59.16804477490452, 18.412187544711685, 38.969830240499824, 44.39677892846152, 8.223204686575537, 5.071705971136317, 6.5514907396206565, 32.992773611432234, 8.660539652268385, 33.83589321132992, 34.96018662931216, 5.683033628369458, 51.5328337272081, 21.152231184710217, 13.921366224272353, 58.33911093878483, 27.930120798346195, 56.993499623696096, 68.76028630470205, 14.075381550402444, 58.2674806202753, 6.612114355335094, 13.073125220128194, 35.377760966243294, 10.329699850529991, 9.737783627001862, 5.588025552211271, 5.1771439412804705, 28.106107996577386, 23.785411801472698, 26.5755969577951, 15.294311278525385, 16.354910041778517, 23.04368353093749, 86.77690082155286, 6.613990650208919, 55.65072699569521, 58.416264485116855, 33.67224089395635, 30.105267236310915, 7.28282305686059, 103.56902674194343, 31.3168954646442, 6.381092650563234, 24.403221895021144, 17.743243335945614, 20.1525728576041, 73.09308318839622, 65.23177874710936, 9.19233690906564, 59.15038843314706, 9.534998993019343, 15.752766920765954, 13.450668081169143, 12.853514936275996, 98.89520933096338, 57.521515108452704, 28.86395219596976, 21.387122393580256, 9.065157810350133, 63.89118150618075, 10.518815807119461, 40.776320225574324, 19.075788406128556, 155.29879595749412, 49.094940247809674, 26.73810512668109, 31.044291316929844, 54.436213803885934, 38.8458608998048, 10.43662360612696, 19.397487212474683, 16.803677160724714, 31.160830996395166, 5.113217705727644, 7.303000072770163, 38.87058410583617, 163.28414846650418, 66.84875734618338, 43.50458994959223, 12.16830677138197, 10.371096342965997, 11.302484706585782, 80.46640493528398, 13.417490557705207, 65.05145544859619, 13.927384496074781, 78.31762064217637, 40.52049002328214, 14.690026095363653, 16.851147266608926, 15.580050594233272, 48.67394063571711, 105.49796627928941, 6.2032890199204225, 5.581012154344956, 48.03477813215794, 53.787291290912115, 98.90183148735932, 59.35662021746862, 26.6209493078805, 30.74852742724402, 109.61483636806716, 14.760520992640132, 10.959146612351212, 29.76543759851334, 30.953009977510895, 71.88850906176185, 48.857903598072866, 59.572790517780476, 21.439437088344214, 7.856906308592888, 47.95957146847728, 10.695308459865432, 9.097851437055304, 251.05422991986615, 41.73085026560864, 14.783865074056582, 107.3341202812519, 8.54922553216543, 70.182956219057, 41.05893594320422, 77.54911993252531, 342.9539457714429, 33.48459011803348, 93.01866222934997, 105.09259370509238, 10.633771239054235, 17.16134816423757, 26.33468836028614, 23.214674313975678, 11.369694816099228, 15.442779611329035, 7.611740936766289, 48.27842383482713, 9.836911479022774, 91.14833823606672, 50.25544941804038, 46.54623319709455, 46.2548456639227, 66.10913464900811, 60.6066264413465, 68.48428203988857, 5.490561887894404, 6.269234023599763, 16.011281622941972, 47.844110112301344, 24.0436858100293, 57.44730530357847, 16.951971218460464, 15.811131648666235, 72.1437994653259, 45.59021134737762, 51.7261321713182, 9.68656152818824, 48.25781078334943, 22.41452299273639, 10.030751145195877, 14.93249368043309, 18.966965379317838, 38.21448369076622, 88.88775749409552, 38.85842443590062, 13.68541767671755, 35.45966400487068, 52.09402748334933, 31.24508335501687, 33.3295404926442, 61.20727615432668, 62.0799359364911, 12.489260514921101, 5.532547106439369, 49.10090507830243, 22.37157414412283, 69.71698857601712, 10.013432024824406, 11.55111552253751, 82.60470721270352, 11.896347651569315, 42.41437788028593, 112.48322690448937, 14.740076197821558, 10.366815329629407, 28.90182157803231, 96.45449092843971, 17.058505130193502, 37.81175768446475, 144.5361795881605, 13.5876105796301, 23.514065577353144, 55.07943678414798, 80.48394735974999, 19.390716796272066, 13.51474954257768, 38.45010187147041, 16.473807366703863, 35.90242643012101, 10.108829621715962, 45.98102497290695, 9.097993531807171, 30.6286149006811, 17.76658840749702, 68.20199824764714, 58.472451666644176, 10.389472242689136, 15.598918621949627, 15.189313068403568, 16.159702866996184, 37.8000055473966, 30.76348891091525, 10.789717450687638, 8.489808625346829, 40.58895846499722, 51.83453218715001, 41.48350171281402, 33.64439110203594, 10.030890903479902, 11.54847458195187, 38.06664305474708, 75.98754354741743, 43.39702729907952, 47.44358275647099, 12.928728267448403, 33.523150130164304, 59.68136369032091, 20.776249650450175, 74.07138694242249, 23.294340450878103, 7.70156956341812, 161.9761223203772, 5.415814682901082, 74.7863998007804, 12.821176806887628, 95.59132931982575, 17.00155647558967, 16.92810779482423, 5.040590503582923, 63.934864483662466, 6.918368382780728, 76.79450234692395, 23.50899721833288, 266.74233957706707, 5.549748404972917, 50.94890789599654, 22.738883368612274, 27.90565662264086, 22.358996670896975, 66.19259659116467, 19.640724232875698, 18.755791425129384, 24.846338279963582, 35.860958476808804, 11.942001968041545, 40.206363004613564, 7.061795022794153, 29.28781485785425, 12.774869220488041, 76.95846036017431, 19.037226871115212, 50.64731834867763, 77.62699777605837, 15.915792929827104, 154.8016935777881, 81.68529574383432, 143.35637351185144, 123.41009272386358, 88.02740633818881, 20.57602700176501, 8.946777174225009, 17.397068039877645, 8.576858973349488, 41.09456831720343, 43.720264379929205, 112.09234239815822, 68.8004938646525, 73.4041360627958, 16.89579702233454, 66.57177849615569, 24.489098047454135, 25.67766351885448, 10.675491723886275, 28.064966544537754, 63.132723562261006, 20.035493771327346, 53.9048559376122, 14.382440139033957, 33.80259938365314, 45.32937298516778, 58.4136160361673, 79.18091803307247, 22.62723574957679, 65.42268750818003, 6.355439936967914, 20.585050825391022, 8.36067291854465, 5.509762808373612, 19.218927738955323, 6.245856302807697, 20.275569386126815, 169.2813586047208, 53.076245863874746, 49.709197193441874, 16.158364145443098, 87.7857351736132, 105.66664460274065, 86.46891238372326, 37.15049682852552, 18.51123783335037, 41.508866979743885, 28.93175614395938, 9.26576444150657, 5.068313974421133, 42.82597294379326, 12.277483522920141, 85.08380680322952, 6.49584189386638, 31.678622037061004, 10.245556434328059, 36.03174727943375, 35.3566590023147, 56.56233279774479, 48.43026791963797, 7.071752330150838, 56.29902633855228, 9.035649043430988, 16.4737003851812, 11.511516146750315, 8.05441824212704, 25.36825318836346, 45.0538604921817, 11.195298180534508, 9.007148112443614, 9.004251510963572, 8.283440346575794, 65.58997684589443, 8.57544447634005, 31.149218000376244, 26.84978479295325, 8.616666622824035, 16.46200251447364, 54.45671590887147, 23.774344484687095, 6.426880480573433, 16.75219714911695, 49.65252084144649, 36.48848109454463, 93.68699694406115, 7.4655886860562255, 65.92702409237008, 14.69470702900567, 44.915160148534746, 30.230187924236247, 37.913873349352514, 14.847541765739944, 11.746155167662433, 74.29193431999384, 116.30585976233814, 54.746630745648844, 6.107109019297703, 13.78956577239658, 7.239226602062396, 53.85033579993784, 14.108042579095914, 56.275358048695004, 12.43252408604688, 33.090504771387884, 17.93955236171341, 22.57310280033016, 17.958111229211454, 86.39993521724126, 64.62551968105736, 102.26040672909848, 14.428065793091152, 102.71463207364029, 47.171635559873486, 44.62838433748215, 17.338783515024428, 11.431970276690782, 58.533493951475826, 21.956120795862848, 74.89491370331807, 9.830542663795494, 36.87334707355329, 12.529593988424251, 40.89158994255435, 49.10805027672425, 47.29394047089133, 6.139322403889644, 14.89666721044509, 20.941045048302417, 24.203705644751288, 12.178192987070107, 26.98076408418831, 75.26048146470067, 9.612025975058447, 53.9894042033079, 26.304413988487905, 29.637566572037997, 35.79794560607858, 7.123329918743028, 35.352024711058796, 50.816813639616605, 18.505217083700387, 6.110904256764241, 33.37127686609671, 169.72391896374748, 20.834366868029818, 8.363585590029807, 16.61225076057379, 6.899068562975761, 12.480591487989896, 21.639810151354077, 7.992386525443285, 83.14159614318834, 80.4885332411204, 9.467027737620274, 60.062557091218494, 16.504976748931213, 47.44627104641105, 10.159758517394138, 14.88200601739068, 17.107750683794052, 22.917628656526176, 39.87191654714365, 11.843504939200926, 87.83738552531915, 12.593596633462976, 73.81710893760595, 5.295379111315015, 8.840947850729872, 87.16817026046773, 5.707702262336843])
caption, xmean,count, xle, Etot = energy_spectrum(E_tot)
hist_file(E_hist, xmean, count, caption);
([5356727.004834287, 5412437.5, 5412724.236069978, 5413212.089081489, 5452507.8125, 5506310.395061531, 5523897.5610526735, 5556264.013757781, 5563609.334413721, 5568065.5032075215, 5568117.341418395, 5568212.898875559, 5598303.759339977, 5607839.7085107695, 5617273.419326149, 5617793.75, 5618598.058157952, 5619641.090305967, 5731809.460820146, 5797154.39136749, 6019979.6875, 6178842.156730506, 6385717.1875, 6407283.70787121, 6413373.190051958, 6416339.0625, 6440596.066235717, 6444824.404978089, 6447893.175794366, 6567386.921481827, 6581158.256948133, 6581362.0199150685, 6581459.873822057, 6581573.584803856, 6582623.93567818, 6583136.704245793, 6625505.916505342, 6626415.446264924, 6627657.455054869, 6628691.229393056, 6634797.639417223, 6634804.6875, 6634949.850595625, 6635241.652302874, 6637199.277179419, 6637777.142762568, 6639304.6875, 6640178.125, 6641061.788756883, 6641839.203882026, 6680078.706455051, 6757820.696221837, 6758500.394687126, 6759179.6875, 6760634.2058227835, 6760662.539231905, 6763251.79385334, 6763272.072718127, 6763275.917799129, 6763522.727523747, 6764111.366977115, 6765460.9375, 6765549.263125735, 6767471.364310191, 6776241.854895551, 6777449.024916585, 6799166.759584791, 6881093.510545386, 6881881.642164879, 6903234.758357596, 6913000.0, 6919749.902682336, 6920603.488896889, 6922861.642965976, 6925774.835547088, 6926674.5077780895, 6927935.19819469, 6928581.665587935, 6938213.313344321, 6938247.610755668, 6944685.023375467, 6956443.605796732, 6958187.220684964, 6970862.355973403, 6971933.756800761, 6972684.952288593, 6980410.392754983, 6981762.609012001, 6982014.0625, 6984038.59555275, 6984045.3125, 7046102.830799229, 7056289.360195838, 7057360.9375, 7057472.421476544, 7058058.237065478, 7059331.408014607, 7059457.146678924, 7060747.829493654, 7064011.976842781, 7064736.887072117, 7064806.408529516, 7065073.4375, 7068518.428342672, 7073840.567616501, 7076910.833257483, 7076938.729475941, 7077614.0625, 7083772.339351821, 7086215.514415732, 7093140.625, 7157310.722434715, 7178068.75, 7188094.0469776215, 7189418.175682824, 7203830.744603644, 7206250.650820706, 7206382.8125, 7206559.079554168, 7206784.085241071, 7206915.625, 7207887.5, 7208681.208016071, 7214146.814933129, 7223889.528206746, 7240521.8720258325, 7262266.95985665, 7268490.085537349, 7272279.909991096, 7272314.474884368, 7276640.214824598, 7277800.314238586, 7370755.909209557, 7373013.909831344, 7375076.005995586, 7441832.4693415435, 7443645.461989808, 7449841.806984547, 7449871.898449208, 7451202.1625257805, 7451261.480398384, 7473810.323089484, 7591629.308209476, 7595509.375, 7659170.3125, 7687965.625, 7737012.5, 7738050.0, 7739556.904152181, 7739629.703595201, 7742153.379949709, 7749618.896220707, 7751801.285092634, 7754870.3125, 7755694.797378819, 7775051.77336465, 7776303.125, 7778237.5, 7781844.897420731, 7783434.767146574, 7784181.25, 7787835.525160363, 7812422.600508421, 7813728.122632602, 7816327.328043405, 7816643.75, 7817704.6875, 7818945.3125, 7825326.188672803, 7879115.87720442, 7883618.953000282, 7893863.856210309, 7893867.1875, 7911819.883063709, 7953670.3125, 7955866.350607039, 7957807.80150395, 7958040.625, 7965495.279613888, 7966928.913770086, 7969322.5846999595, 7970529.942486488, 7970533.753997719, 7970803.566754834, 7971238.675783872, 7982435.9375, 8021488.203267423, 8022391.639283832, 8022900.0, 8023159.375, 8023285.093359421, 8023404.6190544255, 8023586.526855242, 8023685.530304328, 8024177.172063752, 8025479.6875, 8026029.6875, 8026289.464285008, 8027480.817484384, 8028157.888580409, 8028823.788763495, 8029734.375, 8029785.170598705, 8029811.652328297, 8030388.772926005, 8030698.4375, 8030824.022780811, 8031397.922354737, 8032438.30995158, 8032699.470098844, 8033404.080401273, 8034111.00102973, 8034259.150689852, 8034946.06797733, 8035036.576489801, 8036673.209939736, 8039917.553008488, 8040132.8125, 8056235.9375, 8056237.599968048, 8056396.875, 8058678.8506355975, 8060251.815988842, 8060678.125, 8060898.484793781, 8060938.525335184, 8061234.375, 8062214.973219852, 8063993.75, 8064087.251304194, 8067204.05328359, 8075186.525583609, 8120651.225909826, 8133264.326428939, 8135929.985563106, 8139045.758811901, 8189457.332432603, 8196908.679689175, 8196918.75, 8198014.515066432, 8203362.938976419, 8203442.13084651, 8216580.168334588, 8219663.229172113, 8220094.547756197, 8220116.995343285, 8221006.608016464, 8257250.338714804, 8262801.5625, 8263624.616429675, 8268959.3429323705, 8269431.511652474, 8271823.4375, 8272420.714351522, 8273080.059228648, 8282841.408209785, 8283568.585706409, 8283881.715184148, 8284893.24815555, 8288034.1430885745, 8290337.230161628, 8306332.09810478, 8307232.8125, 8309153.90018271, 8340547.205849162, 8341348.4375, 8399568.984107459, 8403208.053864663, 8426646.462703198, 8433809.328216488, 8433813.588332182, 8435191.88478725, 8437885.340376219, 8444815.13217219, 8448508.40631809, 8449889.573850036, 8451107.8125, 8451536.961809816, 8452718.75, 8456215.287888309, 8462976.771234112, 8492846.773870451, 8494503.125, 8496007.047345852, 8498251.399731202, 8505915.315048017, 8505966.557892831, 8508305.506097147, 8509550.380510243, 8515701.94549958, 8528523.28265888, 8541859.375, 8545043.209533647, 8545855.965010455, 8546231.25, 8547358.01030741, 8549512.5, 8550069.417905482, 8550193.153885307, 8550204.825036008, 8550443.26000287, 8550591.42468856, 8552415.454190057, 8552825.931125253, 8554049.89420516, 8554220.3125, 8554378.155072466, 8555541.080871211, 8562293.594145898, 8567653.125, 8568321.875, 8569989.621554606, 8575500.922631133, 8576328.125, 8576343.75, 8589668.671338467, 8589731.217951333, 8591583.23513863, 8591666.254086608, 8593441.620816676, 8593515.68059628, 8595602.758051183, 8598477.47637535, 8604240.625, 8607042.1875, 8616064.0625, 8630235.607359521, 8630829.49500028, 8631848.4375, 8632360.565711958, 8632415.441074789, 8633033.04491448, 8638521.408571098, 8639004.9622293, 8652146.875, 8653815.667816726, 8656705.839896603, 8656829.273476351, 8657649.994063213, 8659086.876605209, 8659105.196528103, 8659545.3125, 8659566.095779046, 8659875.576065963, 8660263.863255054, 8662366.686212566, 8662796.576845536, 8664457.417338997, 8665380.093274446, 8665852.478229763, 8665998.41022549, 8666526.251762474, 8667580.852679728, 8667726.5625, 8668624.226875028, 8693212.5, 8718868.54619806, 8727568.777408568, 8729337.475126086, 8731105.050140414, 8736754.462282935, 8738747.717061957, 8738764.0625, 8743978.305839552, 8743987.160945522, 8753414.492357852, 8756755.713364234, 8760431.012678925, 8774360.718554065, 8775205.387743777, 8775763.557962166, 8776038.113216866, 8781720.233039109, 8784108.428672232, 8829831.25, 8848106.25, 8855524.274627216, 8857956.108438391, 8917198.4375, 8923723.4375, 8939228.125, 8968032.49184102, 8993998.623811249, 8994798.4375, 8997629.232695887, 9021356.43230678, 9029073.974179894, 9079715.625, 9081253.868423961, 9084804.919827227, 9087259.142455827, 9087746.281824294, 9151750.478577929, 9176490.613185164, 9204851.005319161, 9209728.860312594, 9211658.394538416, 9254101.715199197, 9269326.5625, 9271180.001726074, 9271385.9375, 9275095.189178327, 9362087.5, 9381250.043560483, 9402120.319640407, 9402347.251256373, 10261156.25, 10263960.074816708, 10267975.216479521, 10283688.488067705, 10348991.852806043, 10355395.915645422, 10369242.330339117, 10369244.258485507, 10401533.455605334, 10410799.416673984, 10414021.38958228, 10417435.336415194, 10417471.135799907, 10419012.5, 10420997.031156858, 10421175.0, 10421272.232490703, 10421506.25, 10422743.027804261, 10423434.359300498, 10425872.346938878, 10427473.624325365, 10427543.75, 10428926.976780703, 10429354.6875, 10431457.021339264, 10432050.874699201, 10433126.700821247, 10434318.10680712, 10450815.45595366, 358290559.3898266], [16.94617639403435, 48.47169926158175, 38.18990690195111, 34.64603535954055, 42.9015459459598, 59.16804477490452, 18.412187544711685, 38.969830240499824, 44.39677892846152, 8.223204686575537, 5.071705971136317, 6.5514907396206565, 32.992773611432234, 8.660539652268385, 33.83589321132992, 34.96018662931216, 5.683033628369458, 51.5328337272081, 21.152231184710217, 13.921366224272353, 58.33911093878483, 27.930120798346195, 56.993499623696096, 68.76028630470205, 14.075381550402444, 58.2674806202753, 6.612114355335094, 13.073125220128194, 35.377760966243294, 10.329699850529991, 9.737783627001862, 5.588025552211271, 5.1771439412804705, 28.106107996577386, 23.785411801472698, 26.5755969577951, 15.294311278525385, 16.354910041778517, 23.04368353093749, 86.77690082155286, 6.613990650208919, 55.65072699569521, 58.416264485116855, 33.67224089395635, 30.105267236310915, 7.28282305686059, 103.56902674194343, 31.3168954646442, 6.381092650563234, 24.403221895021144, 17.743243335945614, 20.1525728576041, 73.09308318839622, 65.23177874710936, 9.19233690906564, 59.15038843314706, 9.534998993019343, 15.752766920765954, 13.450668081169143, 12.853514936275996, 98.89520933096338, 57.521515108452704, 28.86395219596976, 21.387122393580256, 9.065157810350133, 63.89118150618075, 10.518815807119461, 40.776320225574324, 19.075788406128556, 155.29879595749412, 49.094940247809674, 26.73810512668109, 31.044291316929844, 54.436213803885934, 38.8458608998048, 10.43662360612696, 19.397487212474683, 16.803677160724714, 31.160830996395166, 5.113217705727644, 7.303000072770163, 38.87058410583617, 163.28414846650418, 66.84875734618338, 43.50458994959223, 12.16830677138197, 10.371096342965997, 11.302484706585782, 80.46640493528398, 13.417490557705207, 65.05145544859619, 13.927384496074781, 78.31762064217637, 40.52049002328214, 14.690026095363653, 16.851147266608926, 15.580050594233272, 48.67394063571711, 105.49796627928941, 6.2032890199204225, 5.581012154344956, 48.03477813215794, 53.787291290912115, 98.90183148735932, 59.35662021746862, 26.6209493078805, 30.74852742724402, 109.61483636806716, 14.760520992640132, 10.959146612351212, 29.76543759851334, 30.953009977510895, 71.88850906176185, 48.857903598072866, 59.572790517780476, 21.439437088344214, 7.856906308592888, 47.95957146847728, 10.695308459865432, 9.097851437055304, 251.05422991986615, 41.73085026560864, 14.783865074056582, 107.3341202812519, 8.54922553216543, 70.182956219057, 41.05893594320422, 77.54911993252531, 342.9539457714429, 33.48459011803348, 93.01866222934997, 105.09259370509238, 10.633771239054235, 17.16134816423757, 26.33468836028614, 23.214674313975678, 11.369694816099228, 15.442779611329035, 7.611740936766289, 48.27842383482713, 9.836911479022774, 91.14833823606672, 50.25544941804038, 46.54623319709455, 46.2548456639227, 66.10913464900811, 60.6066264413465, 68.48428203988857, 5.490561887894404, 6.269234023599763, 16.011281622941972, 47.844110112301344, 24.0436858100293, 57.44730530357847, 16.951971218460464, 15.811131648666235, 72.1437994653259, 45.59021134737762, 51.7261321713182, 9.68656152818824, 48.25781078334943, 22.41452299273639, 10.030751145195877, 14.93249368043309, 18.966965379317838, 38.21448369076622, 88.88775749409552, 38.85842443590062, 13.68541767671755, 35.45966400487068, 52.09402748334933, 31.24508335501687, 33.3295404926442, 61.20727615432668, 62.0799359364911, 12.489260514921101, 5.532547106439369, 49.10090507830243, 22.37157414412283, 69.71698857601712, 10.013432024824406, 11.55111552253751, 82.60470721270352, 11.896347651569315, 42.41437788028593, 112.48322690448937, 14.740076197821558, 10.366815329629407, 28.90182157803231, 96.45449092843971, 17.058505130193502, 37.81175768446475, 144.5361795881605, 13.5876105796301, 23.514065577353144, 55.07943678414798, 80.48394735974999, 19.390716796272066, 13.51474954257768, 38.45010187147041, 16.473807366703863, 35.90242643012101, 10.108829621715962, 45.98102497290695, 9.097993531807171, 30.6286149006811, 17.76658840749702, 68.20199824764714, 58.472451666644176, 10.389472242689136, 15.598918621949627, 15.189313068403568, 16.159702866996184, 37.8000055473966, 30.76348891091525, 10.789717450687638, 8.489808625346829, 40.58895846499722, 51.83453218715001, 41.48350171281402, 33.64439110203594, 10.030890903479902, 11.54847458195187, 38.06664305474708, 75.98754354741743, 43.39702729907952, 47.44358275647099, 12.928728267448403, 33.523150130164304, 59.68136369032091, 20.776249650450175, 74.07138694242249, 23.294340450878103, 7.70156956341812, 161.9761223203772, 5.415814682901082, 74.7863998007804, 12.821176806887628, 95.59132931982575, 17.00155647558967, 16.92810779482423, 5.040590503582923, 63.934864483662466, 6.918368382780728, 76.79450234692395, 23.50899721833288, 266.74233957706707, 5.549748404972917, 50.94890789599654, 22.738883368612274, 27.90565662264086, 22.358996670896975, 66.19259659116467, 19.640724232875698, 18.755791425129384, 24.846338279963582, 35.860958476808804, 11.942001968041545, 40.206363004613564, 7.061795022794153, 29.28781485785425, 12.774869220488041, 76.95846036017431, 19.037226871115212, 50.64731834867763, 77.62699777605837, 15.915792929827104, 154.8016935777881, 81.68529574383432, 143.35637351185144, 123.41009272386358, 88.02740633818881, 20.57602700176501, 8.946777174225009, 17.397068039877645, 8.576858973349488, 41.09456831720343, 43.720264379929205, 112.09234239815822, 68.8004938646525, 73.4041360627958, 16.89579702233454, 66.57177849615569, 24.489098047454135, 25.67766351885448, 10.675491723886275, 28.064966544537754, 63.132723562261006, 20.035493771327346, 53.9048559376122, 14.382440139033957, 33.80259938365314, 45.32937298516778, 58.4136160361673, 79.18091803307247, 22.62723574957679, 65.42268750818003, 6.355439936967914, 20.585050825391022, 8.36067291854465, 5.509762808373612, 19.218927738955323, 6.245856302807697, 20.275569386126815, 169.2813586047208, 53.076245863874746, 49.709197193441874, 16.158364145443098, 87.7857351736132, 105.66664460274065, 86.46891238372326, 37.15049682852552, 18.51123783335037, 41.508866979743885, 28.93175614395938, 9.26576444150657, 5.068313974421133, 42.82597294379326, 12.277483522920141, 85.08380680322952, 6.49584189386638, 31.678622037061004, 10.245556434328059, 36.03174727943375, 35.3566590023147, 56.56233279774479, 48.43026791963797, 7.071752330150838, 56.29902633855228, 9.035649043430988, 16.4737003851812, 11.511516146750315, 8.05441824212704, 25.36825318836346, 45.0538604921817, 11.195298180534508, 9.007148112443614, 9.004251510963572, 8.283440346575794, 65.58997684589443, 8.57544447634005, 31.149218000376244, 26.84978479295325, 8.616666622824035, 16.46200251447364, 54.45671590887147, 23.774344484687095, 6.426880480573433, 16.75219714911695, 49.65252084144649, 36.48848109454463, 93.68699694406115, 7.4655886860562255, 65.92702409237008, 14.69470702900567, 44.915160148534746, 30.230187924236247, 37.913873349352514, 14.847541765739944, 11.746155167662433, 74.29193431999384, 116.30585976233814, 54.746630745648844, 6.107109019297703, 13.78956577239658, 7.239226602062396, 53.85033579993784, 14.108042579095914, 56.275358048695004, 12.43252408604688, 33.090504771387884, 17.93955236171341, 22.57310280033016, 17.958111229211454, 86.39993521724126, 64.62551968105736, 102.26040672909848, 14.428065793091152, 102.71463207364029, 47.171635559873486, 44.62838433748215, 17.338783515024428, 11.431970276690782, 58.533493951475826, 21.956120795862848, 74.89491370331807, 9.830542663795494, 36.87334707355329, 12.529593988424251, 40.89158994255435, 49.10805027672425, 47.29394047089133, 6.139322403889644, 14.89666721044509, 20.941045048302417, 24.203705644751288, 12.178192987070107, 26.98076408418831, 75.26048146470067, 9.612025975058447, 53.9894042033079, 26.304413988487905, 29.637566572037997, 35.79794560607858, 7.123329918743028, 35.352024711058796, 50.816813639616605, 18.505217083700387, 6.110904256764241, 33.37127686609671, 169.72391896374748, 20.834366868029818, 8.363585590029807, 16.61225076057379, 6.899068562975761, 12.480591487989896, 21.639810151354077, 7.992386525443285, 83.14159614318834, 80.4885332411204, 9.467027737620274, 60.062557091218494, 16.504976748931213, 47.44627104641105, 10.159758517394138, 14.88200601739068, 17.107750683794052, 22.917628656526176, 39.87191654714365, 11.843504939200926, 87.83738552531915, 12.593596633462976, 73.81710893760595, 5.295379111315015, 8.840947850729872, 87.16817026046773, 5.707702262336843])
caption, T_hit,count1 = hits_in_time_hist_new(T_pom, dt, t_plasma_start, t_plasma_end, is_plasma, figure_count_in_time_hist)
hist_file(count_in_time_hist, T_hit, count1, caption);
([5356727.004834287, 5412437.5, 5412724.236069978, 5413212.089081489, 5452507.8125, 5506310.395061531, 5523897.5610526735, 5556264.013757781, 5563609.334413721, 5568065.5032075215, 5568117.341418395, 5568212.898875559, 5598303.759339977, 5607839.7085107695, 5617273.419326149, 5617793.75, 5618598.058157952, 5619641.090305967, 5731809.460820146, 5797154.39136749, 6019979.6875, 6178842.156730506, 6385717.1875, 6407283.70787121, 6413373.190051958, 6416339.0625, 6440596.066235717, 6444824.404978089, 6447893.175794366, 6567386.921481827, 6581158.256948133, 6581362.0199150685, 6581459.873822057, 6581573.584803856, 6582623.93567818, 6583136.704245793, 6625505.916505342, 6626415.446264924, 6627657.455054869, 6628691.229393056, 6634797.639417223, 6634804.6875, 6634949.850595625, 6635241.652302874, 6637199.277179419, 6637777.142762568, 6639304.6875, 6640178.125, 6641061.788756883, 6641839.203882026, 6680078.706455051, 6757820.696221837, 6758500.394687126, 6759179.6875, 6760634.2058227835, 6760662.539231905, 6763251.79385334, 6763272.072718127, 6763275.917799129, 6763522.727523747, 6764111.366977115, 6765460.9375, 6765549.263125735, 6767471.364310191, 6776241.854895551, 6777449.024916585, 6799166.759584791, 6881093.510545386, 6881881.642164879, 6903234.758357596, 6913000.0, 6919749.902682336, 6920603.488896889, 6922861.642965976, 6925774.835547088, 6926674.5077780895, 6927935.19819469, 6928581.665587935, 6938213.313344321, 6938247.610755668, 6944685.023375467, 6956443.605796732, 6958187.220684964, 6970862.355973403, 6971933.756800761, 6972684.952288593, 6980410.392754983, 6981762.609012001, 6982014.0625, 6984038.59555275, 6984045.3125, 7046102.830799229, 7056289.360195838, 7057360.9375, 7057472.421476544, 7058058.237065478, 7059331.408014607, 7059457.146678924, 7060747.829493654, 7064011.976842781, 7064736.887072117, 7064806.408529516, 7065073.4375, 7068518.428342672, 7073840.567616501, 7076910.833257483, 7076938.729475941, 7077614.0625, 7083772.339351821, 7086215.514415732, 7093140.625, 7157310.722434715, 7178068.75, 7188094.0469776215, 7189418.175682824, 7203830.744603644, 7206250.650820706, 7206382.8125, 7206559.079554168, 7206784.085241071, 7206915.625, 7207887.5, 7208681.208016071, 7214146.814933129, 7223889.528206746, 7240521.8720258325, 7262266.95985665, 7268490.085537349, 7272279.909991096, 7272314.474884368, 7276640.214824598, 7277800.314238586, 7370755.909209557, 7373013.909831344, 7375076.005995586, 7441832.4693415435, 7443645.461989808, 7449841.806984547, 7449871.898449208, 7451202.1625257805, 7451261.480398384, 7473810.323089484, 7591629.308209476, 7595509.375, 7659170.3125, 7687965.625, 7737012.5, 7738050.0, 7739556.904152181, 7739629.703595201, 7742153.379949709, 7749618.896220707, 7751801.285092634, 7754870.3125, 7755694.797378819, 7775051.77336465, 7776303.125, 7778237.5, 7781844.897420731, 7783434.767146574, 7784181.25, 7787835.525160363, 7812422.600508421, 7813728.122632602, 7816327.328043405, 7816643.75, 7817704.6875, 7818945.3125, 7825326.188672803, 7879115.87720442, 7883618.953000282, 7893863.856210309, 7893867.1875, 7911819.883063709, 7953670.3125, 7955866.350607039, 7957807.80150395, 7958040.625, 7965495.279613888, 7966928.913770086, 7969322.5846999595, 7970529.942486488, 7970533.753997719, 7970803.566754834, 7971238.675783872, 7982435.9375, 8021488.203267423, 8022391.639283832, 8022900.0, 8023159.375, 8023285.093359421, 8023404.6190544255, 8023586.526855242, 8023685.530304328, 8024177.172063752, 8025479.6875, 8026029.6875, 8026289.464285008, 8027480.817484384, 8028157.888580409, 8028823.788763495, 8029734.375, 8029785.170598705, 8029811.652328297, 8030388.772926005, 8030698.4375, 8030824.022780811, 8031397.922354737, 8032438.30995158, 8032699.470098844, 8033404.080401273, 8034111.00102973, 8034259.150689852, 8034946.06797733, 8035036.576489801, 8036673.209939736, 8039917.553008488, 8040132.8125, 8056235.9375, 8056237.599968048, 8056396.875, 8058678.8506355975, 8060251.815988842, 8060678.125, 8060898.484793781, 8060938.525335184, 8061234.375, 8062214.973219852, 8063993.75, 8064087.251304194, 8067204.05328359, 8075186.525583609, 8120651.225909826, 8133264.326428939, 8135929.985563106, 8139045.758811901, 8189457.332432603, 8196908.679689175, 8196918.75, 8198014.515066432, 8203362.938976419, 8203442.13084651, 8216580.168334588, 8219663.229172113, 8220094.547756197, 8220116.995343285, 8221006.608016464, 8257250.338714804, 8262801.5625, 8263624.616429675, 8268959.3429323705, 8269431.511652474, 8271823.4375, 8272420.714351522, 8273080.059228648, 8282841.408209785, 8283568.585706409, 8283881.715184148, 8284893.24815555, 8288034.1430885745, 8290337.230161628, 8306332.09810478, 8307232.8125, 8309153.90018271, 8340547.205849162, 8341348.4375, 8399568.984107459, 8403208.053864663, 8426646.462703198, 8433809.328216488, 8433813.588332182, 8435191.88478725, 8437885.340376219, 8444815.13217219, 8448508.40631809, 8449889.573850036, 8451107.8125, 8451536.961809816, 8452718.75, 8456215.287888309, 8462976.771234112, 8492846.773870451, 8494503.125, 8496007.047345852, 8498251.399731202, 8505915.315048017, 8505966.557892831, 8508305.506097147, 8509550.380510243, 8515701.94549958, 8528523.28265888, 8541859.375, 8545043.209533647, 8545855.965010455, 8546231.25, 8547358.01030741, 8549512.5, 8550069.417905482, 8550193.153885307, 8550204.825036008, 8550443.26000287, 8550591.42468856, 8552415.454190057, 8552825.931125253, 8554049.89420516, 8554220.3125, 8554378.155072466, 8555541.080871211, 8562293.594145898, 8567653.125, 8568321.875, 8569989.621554606, 8575500.922631133, 8576328.125, 8576343.75, 8589668.671338467, 8589731.217951333, 8591583.23513863, 8591666.254086608, 8593441.620816676, 8593515.68059628, 8595602.758051183, 8598477.47637535, 8604240.625, 8607042.1875, 8616064.0625, 8630235.607359521, 8630829.49500028, 8631848.4375, 8632360.565711958, 8632415.441074789, 8633033.04491448, 8638521.408571098, 8639004.9622293, 8652146.875, 8653815.667816726, 8656705.839896603, 8656829.273476351, 8657649.994063213, 8659086.876605209, 8659105.196528103, 8659545.3125, 8659566.095779046, 8659875.576065963, 8660263.863255054, 8662366.686212566, 8662796.576845536, 8664457.417338997, 8665380.093274446, 8665852.478229763, 8665998.41022549, 8666526.251762474, 8667580.852679728, 8667726.5625, 8668624.226875028, 8693212.5, 8718868.54619806, 8727568.777408568, 8729337.475126086, 8731105.050140414, 8736754.462282935, 8738747.717061957, 8738764.0625, 8743978.305839552, 8743987.160945522, 8753414.492357852, 8756755.713364234, 8760431.012678925, 8774360.718554065, 8775205.387743777, 8775763.557962166, 8776038.113216866, 8781720.233039109, 8784108.428672232, 8829831.25, 8848106.25, 8855524.274627216, 8857956.108438391, 8917198.4375, 8923723.4375, 8939228.125, 8968032.49184102, 8993998.623811249, 8994798.4375, 8997629.232695887, 9021356.43230678, 9029073.974179894, 9079715.625, 9081253.868423961, 9084804.919827227, 9087259.142455827, 9087746.281824294, 9151750.478577929, 9176490.613185164, 9204851.005319161, 9209728.860312594, 9211658.394538416, 9254101.715199197, 9269326.5625, 9271180.001726074, 9271385.9375, 9275095.189178327, 9362087.5, 9381250.043560483, 9402120.319640407, 9402347.251256373, 10261156.25, 10263960.074816708, 10267975.216479521, 10283688.488067705, 10348991.852806043, 10355395.915645422, 10369242.330339117, 10369244.258485507, 10401533.455605334, 10410799.416673984, 10414021.38958228, 10417435.336415194, 10417471.135799907, 10419012.5, 10420997.031156858, 10421175.0, 10421272.232490703, 10421506.25, 10422743.027804261, 10423434.359300498, 10425872.346938878, 10427473.624325365, 10427543.75, 10428926.976780703, 10429354.6875, 10431457.021339264, 10432050.874699201, 10433126.700821247, 10434318.10680712, 10450815.45595366, 358290559.3898266], [16.94617639403435, 48.47169926158175, 38.18990690195111, 34.64603535954055, 42.9015459459598, 59.16804477490452, 18.412187544711685, 38.969830240499824, 44.39677892846152, 8.223204686575537, 5.071705971136317, 6.5514907396206565, 32.992773611432234, 8.660539652268385, 33.83589321132992, 34.96018662931216, 5.683033628369458, 51.5328337272081, 21.152231184710217, 13.921366224272353, 58.33911093878483, 27.930120798346195, 56.993499623696096, 68.76028630470205, 14.075381550402444, 58.2674806202753, 6.612114355335094, 13.073125220128194, 35.377760966243294, 10.329699850529991, 9.737783627001862, 5.588025552211271, 5.1771439412804705, 28.106107996577386, 23.785411801472698, 26.5755969577951, 15.294311278525385, 16.354910041778517, 23.04368353093749, 86.77690082155286, 6.613990650208919, 55.65072699569521, 58.416264485116855, 33.67224089395635, 30.105267236310915, 7.28282305686059, 103.56902674194343, 31.3168954646442, 6.381092650563234, 24.403221895021144, 17.743243335945614, 20.1525728576041, 73.09308318839622, 65.23177874710936, 9.19233690906564, 59.15038843314706, 9.534998993019343, 15.752766920765954, 13.450668081169143, 12.853514936275996, 98.89520933096338, 57.521515108452704, 28.86395219596976, 21.387122393580256, 9.065157810350133, 63.89118150618075, 10.518815807119461, 40.776320225574324, 19.075788406128556, 155.29879595749412, 49.094940247809674, 26.73810512668109, 31.044291316929844, 54.436213803885934, 38.8458608998048, 10.43662360612696, 19.397487212474683, 16.803677160724714, 31.160830996395166, 5.113217705727644, 7.303000072770163, 38.87058410583617, 163.28414846650418, 66.84875734618338, 43.50458994959223, 12.16830677138197, 10.371096342965997, 11.302484706585782, 80.46640493528398, 13.417490557705207, 65.05145544859619, 13.927384496074781, 78.31762064217637, 40.52049002328214, 14.690026095363653, 16.851147266608926, 15.580050594233272, 48.67394063571711, 105.49796627928941, 6.2032890199204225, 5.581012154344956, 48.03477813215794, 53.787291290912115, 98.90183148735932, 59.35662021746862, 26.6209493078805, 30.74852742724402, 109.61483636806716, 14.760520992640132, 10.959146612351212, 29.76543759851334, 30.953009977510895, 71.88850906176185, 48.857903598072866, 59.572790517780476, 21.439437088344214, 7.856906308592888, 47.95957146847728, 10.695308459865432, 9.097851437055304, 251.05422991986615, 41.73085026560864, 14.783865074056582, 107.3341202812519, 8.54922553216543, 70.182956219057, 41.05893594320422, 77.54911993252531, 342.9539457714429, 33.48459011803348, 93.01866222934997, 105.09259370509238, 10.633771239054235, 17.16134816423757, 26.33468836028614, 23.214674313975678, 11.369694816099228, 15.442779611329035, 7.611740936766289, 48.27842383482713, 9.836911479022774, 91.14833823606672, 50.25544941804038, 46.54623319709455, 46.2548456639227, 66.10913464900811, 60.6066264413465, 68.48428203988857, 5.490561887894404, 6.269234023599763, 16.011281622941972, 47.844110112301344, 24.0436858100293, 57.44730530357847, 16.951971218460464, 15.811131648666235, 72.1437994653259, 45.59021134737762, 51.7261321713182, 9.68656152818824, 48.25781078334943, 22.41452299273639, 10.030751145195877, 14.93249368043309, 18.966965379317838, 38.21448369076622, 88.88775749409552, 38.85842443590062, 13.68541767671755, 35.45966400487068, 52.09402748334933, 31.24508335501687, 33.3295404926442, 61.20727615432668, 62.0799359364911, 12.489260514921101, 5.532547106439369, 49.10090507830243, 22.37157414412283, 69.71698857601712, 10.013432024824406, 11.55111552253751, 82.60470721270352, 11.896347651569315, 42.41437788028593, 112.48322690448937, 14.740076197821558, 10.366815329629407, 28.90182157803231, 96.45449092843971, 17.058505130193502, 37.81175768446475, 144.5361795881605, 13.5876105796301, 23.514065577353144, 55.07943678414798, 80.48394735974999, 19.390716796272066, 13.51474954257768, 38.45010187147041, 16.473807366703863, 35.90242643012101, 10.108829621715962, 45.98102497290695, 9.097993531807171, 30.6286149006811, 17.76658840749702, 68.20199824764714, 58.472451666644176, 10.389472242689136, 15.598918621949627, 15.189313068403568, 16.159702866996184, 37.8000055473966, 30.76348891091525, 10.789717450687638, 8.489808625346829, 40.58895846499722, 51.83453218715001, 41.48350171281402, 33.64439110203594, 10.030890903479902, 11.54847458195187, 38.06664305474708, 75.98754354741743, 43.39702729907952, 47.44358275647099, 12.928728267448403, 33.523150130164304, 59.68136369032091, 20.776249650450175, 74.07138694242249, 23.294340450878103, 7.70156956341812, 161.9761223203772, 5.415814682901082, 74.7863998007804, 12.821176806887628, 95.59132931982575, 17.00155647558967, 16.92810779482423, 5.040590503582923, 63.934864483662466, 6.918368382780728, 76.79450234692395, 23.50899721833288, 266.74233957706707, 5.549748404972917, 50.94890789599654, 22.738883368612274, 27.90565662264086, 22.358996670896975, 66.19259659116467, 19.640724232875698, 18.755791425129384, 24.846338279963582, 35.860958476808804, 11.942001968041545, 40.206363004613564, 7.061795022794153, 29.28781485785425, 12.774869220488041, 76.95846036017431, 19.037226871115212, 50.64731834867763, 77.62699777605837, 15.915792929827104, 154.8016935777881, 81.68529574383432, 143.35637351185144, 123.41009272386358, 88.02740633818881, 20.57602700176501, 8.946777174225009, 17.397068039877645, 8.576858973349488, 41.09456831720343, 43.720264379929205, 112.09234239815822, 68.8004938646525, 73.4041360627958, 16.89579702233454, 66.57177849615569, 24.489098047454135, 25.67766351885448, 10.675491723886275, 28.064966544537754, 63.132723562261006, 20.035493771327346, 53.9048559376122, 14.382440139033957, 33.80259938365314, 45.32937298516778, 58.4136160361673, 79.18091803307247, 22.62723574957679, 65.42268750818003, 6.355439936967914, 20.585050825391022, 8.36067291854465, 5.509762808373612, 19.218927738955323, 6.245856302807697, 20.275569386126815, 169.2813586047208, 53.076245863874746, 49.709197193441874, 16.158364145443098, 87.7857351736132, 105.66664460274065, 86.46891238372326, 37.15049682852552, 18.51123783335037, 41.508866979743885, 28.93175614395938, 9.26576444150657, 5.068313974421133, 42.82597294379326, 12.277483522920141, 85.08380680322952, 6.49584189386638, 31.678622037061004, 10.245556434328059, 36.03174727943375, 35.3566590023147, 56.56233279774479, 48.43026791963797, 7.071752330150838, 56.29902633855228, 9.035649043430988, 16.4737003851812, 11.511516146750315, 8.05441824212704, 25.36825318836346, 45.0538604921817, 11.195298180534508, 9.007148112443614, 9.004251510963572, 8.283440346575794, 65.58997684589443, 8.57544447634005, 31.149218000376244, 26.84978479295325, 8.616666622824035, 16.46200251447364, 54.45671590887147, 23.774344484687095, 6.426880480573433, 16.75219714911695, 49.65252084144649, 36.48848109454463, 93.68699694406115, 7.4655886860562255, 65.92702409237008, 14.69470702900567, 44.915160148534746, 30.230187924236247, 37.913873349352514, 14.847541765739944, 11.746155167662433, 74.29193431999384, 116.30585976233814, 54.746630745648844, 6.107109019297703, 13.78956577239658, 7.239226602062396, 53.85033579993784, 14.108042579095914, 56.275358048695004, 12.43252408604688, 33.090504771387884, 17.93955236171341, 22.57310280033016, 17.958111229211454, 86.39993521724126, 64.62551968105736, 102.26040672909848, 14.428065793091152, 102.71463207364029, 47.171635559873486, 44.62838433748215, 17.338783515024428, 11.431970276690782, 58.533493951475826, 21.956120795862848, 74.89491370331807, 9.830542663795494, 36.87334707355329, 12.529593988424251, 40.89158994255435, 49.10805027672425, 47.29394047089133, 6.139322403889644, 14.89666721044509, 20.941045048302417, 24.203705644751288, 12.178192987070107, 26.98076408418831, 75.26048146470067, 9.612025975058447, 53.9894042033079, 26.304413988487905, 29.637566572037997, 35.79794560607858, 7.123329918743028, 35.352024711058796, 50.816813639616605, 18.505217083700387, 6.110904256764241, 33.37127686609671, 169.72391896374748, 20.834366868029818, 8.363585590029807, 16.61225076057379, 6.899068562975761, 12.480591487989896, 21.639810151354077, 7.992386525443285, 83.14159614318834, 80.4885332411204, 9.467027737620274, 60.062557091218494, 16.504976748931213, 47.44627104641105, 10.159758517394138, 14.88200601739068, 17.107750683794052, 22.917628656526176, 39.87191654714365, 11.843504939200926, 87.83738552531915, 12.593596633462976, 73.81710893760595, 5.295379111315015, 8.840947850729872, 87.16817026046773, 5.707702262336843])
Detected energies during the discharge + Energy spectrum
multiplot(icon_fig, T_int_first,E,xmean,count)
size_of_interactions_average(Etot, Ntot,size_interaction)
#energy_spectra_doublebreakdown(Etot, T_first, file_energy_spectra_doublebreakdown)