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 = 45041
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);
([4881649.343243063, 5053871.4403611, 5107035.436535794, 5162669.16725497, 5177963.305834031, 5188773.437494305, 5202281.25, 5203907.8125, 5217171.349422473, 5219173.515354244, 5221822.463994174, 5225107.020795091, 5258441.593076684, 5258506.04170324, 5258968.385892125, 5260596.299944217, 5261518.75, 5261543.733106498, 5264791.917093218, 5264891.144049264, 5266434.784005188, 5267208.030745455, 5267930.032843101, 5268049.851193583, 5271960.814355197, 5272550.0, 5273443.75, 5274176.0848837895, 5276300.580509068, 5286538.190111452, 5287835.232609589, 5298830.008545245, 5314760.755289578, 5317570.36321357, 5318867.825526128, 5319457.423394685, 5420700.222751743, 5543201.900010485, 5559193.75, 5720670.110167018, 5724463.437554189, 5726974.980291154, 5729706.95530208, 5743024.769412295, 5783290.625, 5846665.625, 5877668.130460224, 5897984.361997194, 6275985.9375, 6287768.257067054, 6289675.0, 6289744.038736158, 6330238.846526845, 6364591.730056233, 6375361.182564197, 6376451.522013201, 6398262.908037604, 6401617.972103576, 6404851.232719399, 6412313.606884116, 6420009.627211083, 6429731.375488167, 6432300.966456673, 6432857.86548686, 6434771.635874247, 6435782.8125, 6447087.780187569, 6450520.37126369, 6450564.1122842645, 6454484.375, 6454964.804060014, 6454974.816541876, 6455036.578897461, 6456833.5297495155, 6464394.193829272, 6466947.323031784, 6467970.390872096, 6469107.219899125, 6469186.326085357, 6469420.598748317, 6471383.446668989, 6474289.010789075, 6474298.070945025, 6475106.25, 6475209.288886982, 6483559.570142792, 6486299.552544634, 6491319.186304534, 6498792.452222546, 6500947.755445765, 6500948.4375, 6504646.18105772, 6506049.31716288, 6509689.054586425, 6509883.546082975, 6510458.514258573, 6512075.0, 6512843.027925683, 6513926.9723296445, 6516882.8125, 6522089.941001628, 6522445.581906915, 6522703.412853687, 6531178.125, 6531576.74986213, 6534533.463127606, 6537653.243382115, 6537664.453222744, 6538359.375, 6539235.407318998, 6539959.121241704, 6541746.875, 6541760.756737421, 6544116.077535441, 6549233.979058479, 6550709.063694835, 6550835.858631522, 6550967.1875, 6551476.051364888, 6552207.483867106, 6555749.679973987, 6558685.524640246, 6558782.280802004, 6561161.193801563, 6562845.65866989, 6562958.295656848, 6565049.33652119, 6567570.3125, 6569663.219246257, 6569815.349194306, 6571273.4375, 6572617.637963682, 6573006.595003382, 6577065.041969872, 6580523.525415445, 6581237.5, 6581700.156574135, 6583185.848486071, 6583530.197091435, 6583988.654515303, 6585631.489107454, 6586723.267219069, 6587195.599530872, 6588757.493683096, 6593866.651065565, 6594251.047909875, 6599647.575773, 6609448.4375, 6617059.375, 6617153.125, 6618178.725315134, 6620875.0, 6621381.466725463, 6621913.075493945, 6624077.405067886, 6625384.993024902, 6625473.157351252, 6625857.31127104, 6626240.194242625, 6626473.929290472, 6627990.232701303, 6628270.070298454, 6632760.830432477, 6639539.0625, 6646502.336572198, 6648090.287693897, 6652422.882367563, 6652621.2999873115, 6653082.79362064, 6658161.02741062, 6658294.291559934, 6659302.940563913, 6661311.211757207, 6661334.85437883, 6663534.027864763, 6665950.259049204, 6669416.280541368, 6669894.334133039, 6684087.965748717, 6685402.84505669, 6692732.602297646, 6694513.756584367, 6697800.847890002, 6698687.5, 6698749.731699008, 6701667.176449026, 6705033.933264081, 6705079.881322159, 6706333.598390128, 6706853.935851662, 6708722.513815513, 6710209.375, 6719212.181081483, 6719468.613288634, 6719977.318708333, 6720115.787752059, 6720914.558999339, 6721064.0625, 6723629.03772335, 6724601.3089395445, 6728469.505042061, 6728961.808350096, 6731275.155087954, 6732898.4375, 6736460.9375, 6741398.704556145, 6746462.812074188, 6749147.840121914, 6749157.965390318, 6749402.83088367, 6749945.3125, 6751115.200999348, 6754501.5625, 6756375.377640786, 6759026.1816690825, 6760692.9928873945, 6760705.8136429945, 6761222.067415024, 6762541.228793949, 6767118.721001046, 6768827.96528704, 6772949.151309938, 6774692.624088595, 6775475.5009714635, 6777259.630375184, 6779404.6875, 6780448.324908295, 6781402.557262627, 6781776.322560421, 6781868.129787377, 6784057.366509688, 6789046.875, 6793864.590614537, 6794645.3125, 6799279.938272896, 6799969.250091762, 6801166.763734603, 6804301.054960216, 6804410.359564144, 6813871.403730688, 6814644.491099875, 6817592.182199236, 6823537.441993702, 6828229.3954047905, 6828623.040390318, 6831138.175016324, 6831639.0625, 6831856.026609033, 6833900.254529537, 6835038.611426537, 6835187.5, 6836481.3141978895, 6838058.791904682, 6838967.00281934, 6839628.125, 6841362.5, 6841794.581787404, 6843151.5625, 6844785.9375, 6845470.03627634, 6848067.1875, 6849557.369756944, 6854066.561707438, 6854101.371426939, 6855008.298499223, 6858670.2613957785, 6861117.888243452, 6861473.689079379, 6863818.693892796, 6864796.150107135, 6866666.388841736, 6868557.8125, 6869968.75, 6870023.434533733, 6884927.875552824, 6885768.727832706, 6888776.5625, 6898165.6712573245, 6907446.554317365, 6914313.219704918, 6916917.925300098, 6921106.681182243, 6925352.696466071, 6927869.898663969, 6928668.255989978, 6930655.4050871115, 6940519.189841322, 6945842.1875, 6955690.625, 6956628.741702721, 6958390.180668435, 6961524.47555385, 6966918.09605031, 6967493.748073027, 6970317.663374395, 6972946.06505769, 6972947.9085950265, 6973379.615929671, 6975380.86155148, 6977921.321902175, 6983408.388397671, 6984234.375, 6985319.887341579, 6989010.45693814, 7001118.422705798, 7004172.531885268, 7005174.812063578, 7005856.240025113, 7008238.837904925, 7019726.112282395, 7028242.816354029, 7028243.931858632, 7030556.518105478, 7031795.3125, 7031981.519084913, 7034213.877409893, 7034494.577781384, 7038346.875, 7038641.978563074, 7041482.308980701, 7041502.643770505, 7044942.1875, 7052396.5736308945, 7054178.125, 7060573.890140984, 7060643.549507857, 7061027.950942567, 7062217.371594764, 7062381.286107646, 7062396.426335311, 7068019.584640605, 7077470.3125, 7079972.484418764, 7084337.832069618, 7084577.471538811, 7085098.161939983, 7085529.013767679, 7097567.1875, 7099376.5625, 7108757.120130836, 7115362.689314417, 7116230.251032372, 7121810.9375, 7124906.178207761, 7131577.527069694, 7151710.979186693, 7156949.6494439775, 7156959.13024582, 7163490.935939505, 7177665.385953536, 7185820.701194632, 7186529.972691717, 7186664.5185581045, 7189395.3125, 7189864.095160314, 7193870.3125, 7195706.621257125, 7198330.782341336, 7200894.455837157, 7202381.25, 7205668.625838078, 7207654.507213329, 7207990.07396582, 7213101.5625, 7215374.488682377, 7217998.167330728, 7219101.094680832, 7225279.341086531, 7227951.5625, 7230629.263617537, 7230874.687538368, 7230899.35086396, 7232093.552619054, 7232391.484846328, 7245108.711319372, 7247861.442557699, 7251872.754812502, 7255644.133735711, 7255900.0, 7261469.8507584175, 7261470.809190702, 7265062.262720123, 7291228.766738191, 7309795.914770963, 7339513.131747899, 7348167.569198976, 7366837.5, 7367868.850909375, 7368220.197298744, 7368645.658440577, 7382026.5625, 7434510.194195079, 7441379.52036574, 7464524.288070812, 7467670.71217188, 7475922.794914317, 7483934.411717307, 7497904.593336954, 7503112.907224192, 7507395.099257491, 7514363.773728212, 7519353.807713266, 7537515.625, 7591136.228176911, 7682320.71240632, 7702022.981887472, 7741482.10852827, 7770370.3125, 7773518.75, 7824102.863886314, 7833107.251481257, 7847868.266282218, 7849818.902280691, 7865845.167206755, 7914536.59044879, 7916483.07387754, 7991595.347915781, 8026099.297865809, 8052393.75, 8087670.5716077695, 8097850.385716441, 8125306.700985716, 8126099.9259408405, 8130735.9375, 8131623.738374101, 8172803.919397924, 8213339.817450502, 8214704.591081034, 8217505.854354308, 8224406.25, 8228581.683523215, 8326600.611587316, 8327324.686112045, 8332902.169964398, 8338855.00767743, 8349257.476523206, 8386606.25, 8387660.9375, 8427980.624325983, 8433359.929640347, 8435330.199759835, 8438617.1875, 8469229.806486553, 8476329.374803443, 8500304.325850366, 8503318.053305008, 8511908.366765777, 8533634.845429057, 8543291.740086786, 8544399.059510551, 8592783.75183982, 8603027.087979129, 8603043.542361606, 8615650.86408669, 8625874.952723235, 8651462.673507411, 8651676.322336784, 8653596.258967292, 8667936.172060711, 8670551.5625, 8670889.042176373, 8676930.143031027, 8677170.3125, 8678913.664433649, 8694407.8125, 8694427.517860075, 8695595.980770558, 8700597.837422999, 8711767.1875, 8716408.124016589, 8717875.0, 8736845.581473047, 8743045.3125, 8748004.6875, 8748606.25, 8756021.875, 8775237.5, 8782052.88372687, 8787708.59860103, 8795734.218067693, 8816867.1875, 8816922.798682874, 8825347.64803209, 8833081.25, 8853554.6875, 8859444.705556225, 8859578.6363653, 8859579.6875, 8871585.717284122, 8876250.740633415, 8887835.51796513, 8890605.03782204, 8935534.375, 8937950.929659447, 8948017.625131402, 8959326.807014374, 8960588.09953296, 8960637.41914913, 8966548.4375, 8991165.584580181, 8995068.533252964, 8995111.93153116, 9001693.229279501, 9012786.959819162, 9020817.77172501, 9024360.863919005, 9035916.138989814, 9035937.408599406, 9043095.797697764, 9046624.398766547, 9062585.612088056, 9062678.175913513, 9063899.061951827, 9064356.25, 9085422.385608248, 9102796.564227685, 9105887.346503984, 9111441.407913553, 9111708.645886386, 9115581.119344415, 9115587.084474368, 9120254.860051604, 9133696.76914021, 9148915.961961595, 9151940.625, 9152484.375, 9153064.844444005, 9155206.25, 9157926.5625, 9162995.510953344, 9180154.535012972, 9188666.77034986, 9189584.512773568, 9189826.5625, 9191035.208334118, 9199445.753187139, 9221125.63886786, 9245615.80814999, 9246947.045589464, 9307811.68126225, 9310464.234727066, 9310850.128099142, 9317574.924833443, 9323507.037196372, 9324846.070135035, 9325353.757252859, 9330455.895613158, 9360756.25, 9375289.089428872, 9377036.09796976, 9392421.808915967, 9395128.125, 9395326.039032504, 9421254.6875, 9432795.998156127, 9446415.625, 9447111.444627598, 9463242.1875, 9559314.894869652, 9559336.478117174, 9594834.289633863, 9758995.12640041, 9763370.966231855, 9763470.663915101, 10728269.7823301], [30.320860990405826, 22.170869528891718, 7.431568777862844, 80.66400817174606, 12.674078988611665, 11.127697901473386, 50.83698740531698, 69.17202139037546, 56.37242203815777, 15.62736003562284, 12.19271572785449, 110.87488559597325, 5.504910406740398, 14.202875903819152, 22.964994816741147, 68.00423390303746, 55.83286309458055, 14.877507894416231, 6.710696563236267, 30.99562904909903, 11.83344263861785, 5.830306992868887, 38.6335716361438, 25.89537234988986, 58.91965459516548, 50.239438196700156, 73.72604624841131, 78.51981885857649, 48.212157116181785, 5.366138797384379, 18.037461812533788, 6.308630503312677, 25.381741645796236, 97.61856691961567, 18.096935277470596, 60.544939290580814, 109.39518641089563, 16.40553126792265, 72.07004393682053, 30.8357359246843, 22.157702524211537, 58.32066455064134, 38.45220119474472, 9.143752963819932, 67.2984568177086, 39.469390880536025, 13.010158909521179, 128.5086091717205, 72.9034603542684, 72.22445286307553, 69.28105507472637, 47.39325185329389, 113.77485323641736, 16.86060017547379, 120.30101182429384, 35.19056790274855, 7.757800282854381, 24.212579770103254, 96.84189343835244, 41.155979083527086, 15.998644839039295, 181.4945354839325, 56.26695064406965, 12.739121305609638, 50.89621365759987, 67.36625994659198, 16.129038163100766, 11.22081753506387, 25.642220645465528, 56.232477552596954, 18.795029075517153, 25.36303030020147, 6.157439141417907, 21.307811488629117, 45.50348974283371, 5.639320688177246, 7.631831636361211, 13.079392507002554, 11.794747654470582, 40.01117289494016, 22.562809964537358, 27.541562905567787, 28.85030394883032, 31.279420043000925, 9.259635923123467, 15.74140305037161, 55.107820833777325, 16.913767398767384, 13.710191272049775, 76.80071909166789, 31.41422190705474, 5.881168343328856, 25.99007848344864, 84.03776719473746, 50.61485480584374, 67.37666755410702, 91.1189247634949, 6.379559153745186, 37.48568959463694, 62.38753705584746, 12.848866758816714, 87.54483680318998, 7.199232883563065, 56.920671345515146, 11.433763804555314, 7.856825201846895, 21.20102810623149, 9.685180665075293, 76.83809553021206, 36.58923955571897, 51.1187937563058, 83.20813439552784, 25.40349622849145, 6.560449772935106, 131.14061820237143, 17.603754067430078, 23.188792844273223, 43.12045701455649, 56.67321263404382, 23.39175895183602, 5.23627583954049, 13.571211272416965, 150.55361763829433, 80.3551748878013, 11.71563460601171, 36.62900346805152, 20.003867173791793, 69.96874092388468, 10.023877944505092, 13.985074666738562, 32.84210650954339, 71.3463972941583, 18.56300222506302, 13.104256389313937, 8.33362216738357, 40.15562211554754, 5.0717546389377155, 9.257254170937685, 12.030064452340794, 22.46288648571479, 37.387436183752904, 41.024401343161976, 6.118465328305402, 43.68525834072128, 7.420095354797652, 8.931153788575475, 18.917329296695996, 77.84282476705475, 28.628372158884932, 55.8181855765688, 12.216467823253561, 60.76660437386949, 15.837343816461818, 37.99632714178994, 27.308294717082408, 55.05986170937929, 48.85471499912214, 31.76333689223409, 104.73024444097705, 55.93198046476955, 16.6170727220057, 34.95767844373004, 6.253765270444262, 66.4163145238133, 26.54024333480787, 55.1106926111359, 6.4034535056167385, 19.01235671208711, 42.852343430668775, 31.214168972156642, 115.87263036916036, 14.28222738058571, 16.101154869465198, 20.312414294787086, 22.87598665548086, 11.55828944159045, 85.86748091903213, 59.412612404096116, 17.073624901321118, 16.02038017166472, 112.93304065997921, 10.680993335935499, 93.48629012776495, 48.75258183777105, 19.646175183816492, 5.706055054827769, 13.65826851187669, 6.517909929022802, 19.11606930384472, 20.66944407856117, 7.851870950939608, 48.92551151568912, 6.055550728464483, 30.569955533408674, 10.064688413364724, 5.717194868731654, 5.557672402972741, 63.50902169283923, 28.848417809797674, 9.125827360215236, 5.495134674634258, 16.79837382751727, 11.379092305913113, 124.58366571153394, 41.22767715405615, 134.77824828205806, 16.281257374158436, 73.17127914971226, 9.46411532169086, 20.736512090358215, 37.498186134330844, 8.996895869161367, 43.7979506327564, 9.672526761816032, 53.93611193478273, 18.847196622878275, 28.850430367825375, 15.729391207735182, 14.54149051163617, 6.263541497910122, 25.724935065764743, 18.60106484044793, 17.530748653444988, 7.25967773870215, 11.36436023294251, 112.75967211361215, 9.237981110951699, 51.92599815958417, 24.54949430247812, 43.311407819392215, 5.9014847802940595, 39.820705720217376, 9.821794357012417, 139.39180803751088, 11.543690227918452, 27.352653788704078, 6.681754691218765, 80.09425772319143, 19.286816747242394, 30.545833161946604, 15.572064571091076, 15.47190063010051, 11.038233740275947, 65.49794718125355, 13.616957374543361, 84.82535169641486, 73.23808028671147, 6.065172568286356, 9.556312880173431, 28.50115266303763, 42.39768234391521, 18.80752488107479, 83.23919584853782, 12.926180065246374, 55.1549862410321, 114.87118780569354, 28.25180565343351, 69.31512418817064, 48.9460777374221, 64.33797951088222, 49.73015732654528, 13.48564329299835, 8.852945224336462, 6.725950568453193, 33.29685386767252, 21.458770433493946, 21.326583968324165, 23.77366278750536, 27.461611898208496, 19.509103012523447, 128.28876212667257, 71.77913394235574, 49.647527070581965, 5.2450622804869615, 24.418700994264565, 6.483621918735957, 49.26108689060513, 7.620054290396512, 49.87754257397735, 8.707748096232587, 12.516819802290668, 5.734760335561683, 22.236920311536952, 22.39796441425002, 21.553062295908106, 12.471234534429287, 16.431049683200655, 29.06102125904074, 47.097142844312174, 12.251105559663818, 38.52904663824508, 21.252654518325123, 25.028074730021842, 14.93416978319961, 26.104707862456294, 120.20071209633453, 22.04308442406861, 27.184722921418878, 7.022951738904809, 20.979284150259492, 6.884197210450611, 36.51488485057313, 22.273651027623302, 8.955629931850591, 23.40824661094376, 48.166603259527285, 88.02366289947084, 71.15003085522451, 26.946820964275812, 26.690929532365335, 18.038327595059915, 20.70148278897794, 28.318034565771665, 37.567965552176645, 20.723591700079258, 21.44490694500047, 27.651831587401514, 64.90240053586224, 22.571639753860875, 13.31641782551532, 28.318520034751632, 37.61291307281162, 38.3976994778113, 39.89091647643953, 29.57946220516455, 5.335098170057195, 88.1125684568447, 52.09911636080996, 29.726857393905743, 14.764213484777276, 6.942418960263164, 69.81626025334263, 29.142035250981635, 33.11689313599014, 20.087648468801547, 72.08037194739737, 7.959772032436042, 166.62387185508737, 244.224035961809, 8.807383256173118, 15.715768236218134, 27.46786146164481, 41.81636553732665, 27.180797571413116, 16.72368033606405, 15.102816333681893, 13.75486151119392, 14.08404833517663, 9.608927796200444, 8.164085471073918, 43.226697058984996, 16.152669623185954, 6.561040451065071, 34.0053647803958, 15.067473844915753, 29.078430121862365, 37.25868700881359, 29.894283850848996, 29.494629028571868, 42.07352250469074, 8.221991944322042, 34.88306874755972, 20.998678108049308, 46.788534471219975, 10.412636011518767, 14.555154008184974, 21.820242385726125, 8.111506934001183, 90.37011001645917, 22.287574690596273, 5.518105556536292, 18.332029748796693, 10.83259418751868, 12.803299628469297, 5.665782568102469, 30.613369344971368, 19.84568521079315, 36.03280463216235, 78.72526930203986, 36.337403085648226, 6.141319951580628, 14.108175896515796, 5.311330413609051, 75.45680385602367, 12.283175103382892, 16.62768388857285, 49.43857439033305, 18.092620034460076, 5.699465309637223, 11.034133827999305, 60.95163152734765, 28.780344757946914, 25.61049437038513, 54.1015343925531, 9.69387160178769, 137.24807092296462, 15.083330117279358, 7.569531900898601, 11.830051728514743, 32.689335254954386, 23.895233961657713, 66.07686732683047, 97.49391799746518, 8.446515851348133, 11.81615106767644, 58.286723918124395, 19.674100440163734, 90.54204882210476, 84.773266129959, 5.794909445416539, 40.30647466444362, 59.8781590019465, 23.443823447428972, 72.76613692598633, 18.19336671979977, 96.68124724189114, 15.07823815567386, 67.37811519125843, 35.8785582566412, 14.655830856301879, 40.016520588341635, 16.99296931819862, 27.14077523093824, 39.044803768958346, 16.22734508200644, 74.97493538137962, 12.55590074914741, 14.586314209467574, 22.601332482077645, 50.41811819979592, 11.880437376339609, 117.15112932982223, 79.0803608197437, 16.136813337997904, 16.32056861530457, 50.44999674727427, 59.82500070965811, 143.14748883461894, 13.271945925415782, 17.581868525611377, 12.035421055466326, 79.81752720248865, 8.350517901514133, 18.494948852420826, 52.577417537262576, 59.539003071731884, 105.42879467092916, 9.763594686008775, 10.493661844576865, 12.26238987259997, 20.346611524277503, 12.062068136136697, 7.5298260236806955, 62.69036581383866, 9.291745383222617, 15.646821190831332, 25.25465939776423, 20.408767248074604, 51.137873839922264, 77.35253422494884, 104.26707942798478, 28.695962647268793, 65.42988741141842, 9.016064571147826, 117.2878910427985, 31.705727650286846, 17.83967611120586, 5.228655124505753, 37.16037008303525, 8.458481422718094, 41.205346173458835, 5.2527361772807835, 60.040141950922525, 73.47969130614378, 36.893949345618154, 40.098349060347196, 94.45746577038673, 10.770421596657005, 80.65075447599274, 39.98010715914974, 82.90857483629739, 5.667273403419574, 10.083458405114746, 123.2805518923589, 33.269738569993905, 36.65262044762933, 17.329470707638503, 30.313947102859306, 14.16370981676113, 17.61961346968932, 36.69346135525015, 7.216689732700151, 51.472843246709374, 93.15550066157763, 60.65332114808953, 15.305055785563102, 12.214822153796893, 9.263962226443946, 62.44029162929186, 8.265317686809707, 24.875809689827214, 5.229508774168729, 21.288862785489176, 21.101425475589732, 5.562122949423395, 9.269951715364732, 12.03889783735723, 77.30163816873092, 108.86313141279619, 20.53937929380444, 10.654507506849482, 48.79948880921664, 20.38687791546983, 45.604934765582506, 34.57387644748004, 19.245991152550697, 14.387042850744567, 19.094066998925495, 19.476244901178468, 61.77669144606806, 6.216089350538471, 6.289247976179715, 26.593764320605818, 29.36183920688189, 56.50204046283983, 39.46794792852487, 36.72382921649656, 46.01743845158465, 57.47771675170285, 29.428805718745558, 9.205711267827054, 22.361399373550086, 29.588262007123895, 66.4250276689874, 19.475838887847058, 9.734067550549343, 64.82133504555995, 15.688780471775148, 6.106020509572202, 5.314628041869088, 9.481404089875856, 15.647665066810656, 27.1212751331605, 49.86309504670136, 12.372721429706703, 13.067822954761631, 11.298455005046634, 75.58367617303264, 24.939961175718786, 7.662326634047457, 43.78475666750924, 34.55415022527537, 77.62861981304478, 39.94566888697686, 12.400248465706607, 95.83628954338043, 21.75230232882866, 57.254544765117316, 12.737066992309554, 8.594769491018035, 37.46847591656328, 25.323526740366013, 18.19846428525153, 6.312642096878611, 113.26699067458321])
caption, xmean,count, xle, Etot = energy_spectrum(E_tot)
hist_file(E_hist, xmean, count, caption);
([4881649.343243063, 5053871.4403611, 5107035.436535794, 5162669.16725497, 5177963.305834031, 5188773.437494305, 5202281.25, 5203907.8125, 5217171.349422473, 5219173.515354244, 5221822.463994174, 5225107.020795091, 5258441.593076684, 5258506.04170324, 5258968.385892125, 5260596.299944217, 5261518.75, 5261543.733106498, 5264791.917093218, 5264891.144049264, 5266434.784005188, 5267208.030745455, 5267930.032843101, 5268049.851193583, 5271960.814355197, 5272550.0, 5273443.75, 5274176.0848837895, 5276300.580509068, 5286538.190111452, 5287835.232609589, 5298830.008545245, 5314760.755289578, 5317570.36321357, 5318867.825526128, 5319457.423394685, 5420700.222751743, 5543201.900010485, 5559193.75, 5720670.110167018, 5724463.437554189, 5726974.980291154, 5729706.95530208, 5743024.769412295, 5783290.625, 5846665.625, 5877668.130460224, 5897984.361997194, 6275985.9375, 6287768.257067054, 6289675.0, 6289744.038736158, 6330238.846526845, 6364591.730056233, 6375361.182564197, 6376451.522013201, 6398262.908037604, 6401617.972103576, 6404851.232719399, 6412313.606884116, 6420009.627211083, 6429731.375488167, 6432300.966456673, 6432857.86548686, 6434771.635874247, 6435782.8125, 6447087.780187569, 6450520.37126369, 6450564.1122842645, 6454484.375, 6454964.804060014, 6454974.816541876, 6455036.578897461, 6456833.5297495155, 6464394.193829272, 6466947.323031784, 6467970.390872096, 6469107.219899125, 6469186.326085357, 6469420.598748317, 6471383.446668989, 6474289.010789075, 6474298.070945025, 6475106.25, 6475209.288886982, 6483559.570142792, 6486299.552544634, 6491319.186304534, 6498792.452222546, 6500947.755445765, 6500948.4375, 6504646.18105772, 6506049.31716288, 6509689.054586425, 6509883.546082975, 6510458.514258573, 6512075.0, 6512843.027925683, 6513926.9723296445, 6516882.8125, 6522089.941001628, 6522445.581906915, 6522703.412853687, 6531178.125, 6531576.74986213, 6534533.463127606, 6537653.243382115, 6537664.453222744, 6538359.375, 6539235.407318998, 6539959.121241704, 6541746.875, 6541760.756737421, 6544116.077535441, 6549233.979058479, 6550709.063694835, 6550835.858631522, 6550967.1875, 6551476.051364888, 6552207.483867106, 6555749.679973987, 6558685.524640246, 6558782.280802004, 6561161.193801563, 6562845.65866989, 6562958.295656848, 6565049.33652119, 6567570.3125, 6569663.219246257, 6569815.349194306, 6571273.4375, 6572617.637963682, 6573006.595003382, 6577065.041969872, 6580523.525415445, 6581237.5, 6581700.156574135, 6583185.848486071, 6583530.197091435, 6583988.654515303, 6585631.489107454, 6586723.267219069, 6587195.599530872, 6588757.493683096, 6593866.651065565, 6594251.047909875, 6599647.575773, 6609448.4375, 6617059.375, 6617153.125, 6618178.725315134, 6620875.0, 6621381.466725463, 6621913.075493945, 6624077.405067886, 6625384.993024902, 6625473.157351252, 6625857.31127104, 6626240.194242625, 6626473.929290472, 6627990.232701303, 6628270.070298454, 6632760.830432477, 6639539.0625, 6646502.336572198, 6648090.287693897, 6652422.882367563, 6652621.2999873115, 6653082.79362064, 6658161.02741062, 6658294.291559934, 6659302.940563913, 6661311.211757207, 6661334.85437883, 6663534.027864763, 6665950.259049204, 6669416.280541368, 6669894.334133039, 6684087.965748717, 6685402.84505669, 6692732.602297646, 6694513.756584367, 6697800.847890002, 6698687.5, 6698749.731699008, 6701667.176449026, 6705033.933264081, 6705079.881322159, 6706333.598390128, 6706853.935851662, 6708722.513815513, 6710209.375, 6719212.181081483, 6719468.613288634, 6719977.318708333, 6720115.787752059, 6720914.558999339, 6721064.0625, 6723629.03772335, 6724601.3089395445, 6728469.505042061, 6728961.808350096, 6731275.155087954, 6732898.4375, 6736460.9375, 6741398.704556145, 6746462.812074188, 6749147.840121914, 6749157.965390318, 6749402.83088367, 6749945.3125, 6751115.200999348, 6754501.5625, 6756375.377640786, 6759026.1816690825, 6760692.9928873945, 6760705.8136429945, 6761222.067415024, 6762541.228793949, 6767118.721001046, 6768827.96528704, 6772949.151309938, 6774692.624088595, 6775475.5009714635, 6777259.630375184, 6779404.6875, 6780448.324908295, 6781402.557262627, 6781776.322560421, 6781868.129787377, 6784057.366509688, 6789046.875, 6793864.590614537, 6794645.3125, 6799279.938272896, 6799969.250091762, 6801166.763734603, 6804301.054960216, 6804410.359564144, 6813871.403730688, 6814644.491099875, 6817592.182199236, 6823537.441993702, 6828229.3954047905, 6828623.040390318, 6831138.175016324, 6831639.0625, 6831856.026609033, 6833900.254529537, 6835038.611426537, 6835187.5, 6836481.3141978895, 6838058.791904682, 6838967.00281934, 6839628.125, 6841362.5, 6841794.581787404, 6843151.5625, 6844785.9375, 6845470.03627634, 6848067.1875, 6849557.369756944, 6854066.561707438, 6854101.371426939, 6855008.298499223, 6858670.2613957785, 6861117.888243452, 6861473.689079379, 6863818.693892796, 6864796.150107135, 6866666.388841736, 6868557.8125, 6869968.75, 6870023.434533733, 6884927.875552824, 6885768.727832706, 6888776.5625, 6898165.6712573245, 6907446.554317365, 6914313.219704918, 6916917.925300098, 6921106.681182243, 6925352.696466071, 6927869.898663969, 6928668.255989978, 6930655.4050871115, 6940519.189841322, 6945842.1875, 6955690.625, 6956628.741702721, 6958390.180668435, 6961524.47555385, 6966918.09605031, 6967493.748073027, 6970317.663374395, 6972946.06505769, 6972947.9085950265, 6973379.615929671, 6975380.86155148, 6977921.321902175, 6983408.388397671, 6984234.375, 6985319.887341579, 6989010.45693814, 7001118.422705798, 7004172.531885268, 7005174.812063578, 7005856.240025113, 7008238.837904925, 7019726.112282395, 7028242.816354029, 7028243.931858632, 7030556.518105478, 7031795.3125, 7031981.519084913, 7034213.877409893, 7034494.577781384, 7038346.875, 7038641.978563074, 7041482.308980701, 7041502.643770505, 7044942.1875, 7052396.5736308945, 7054178.125, 7060573.890140984, 7060643.549507857, 7061027.950942567, 7062217.371594764, 7062381.286107646, 7062396.426335311, 7068019.584640605, 7077470.3125, 7079972.484418764, 7084337.832069618, 7084577.471538811, 7085098.161939983, 7085529.013767679, 7097567.1875, 7099376.5625, 7108757.120130836, 7115362.689314417, 7116230.251032372, 7121810.9375, 7124906.178207761, 7131577.527069694, 7151710.979186693, 7156949.6494439775, 7156959.13024582, 7163490.935939505, 7177665.385953536, 7185820.701194632, 7186529.972691717, 7186664.5185581045, 7189395.3125, 7189864.095160314, 7193870.3125, 7195706.621257125, 7198330.782341336, 7200894.455837157, 7202381.25, 7205668.625838078, 7207654.507213329, 7207990.07396582, 7213101.5625, 7215374.488682377, 7217998.167330728, 7219101.094680832, 7225279.341086531, 7227951.5625, 7230629.263617537, 7230874.687538368, 7230899.35086396, 7232093.552619054, 7232391.484846328, 7245108.711319372, 7247861.442557699, 7251872.754812502, 7255644.133735711, 7255900.0, 7261469.8507584175, 7261470.809190702, 7265062.262720123, 7291228.766738191, 7309795.914770963, 7339513.131747899, 7348167.569198976, 7366837.5, 7367868.850909375, 7368220.197298744, 7368645.658440577, 7382026.5625, 7434510.194195079, 7441379.52036574, 7464524.288070812, 7467670.71217188, 7475922.794914317, 7483934.411717307, 7497904.593336954, 7503112.907224192, 7507395.099257491, 7514363.773728212, 7519353.807713266, 7537515.625, 7591136.228176911, 7682320.71240632, 7702022.981887472, 7741482.10852827, 7770370.3125, 7773518.75, 7824102.863886314, 7833107.251481257, 7847868.266282218, 7849818.902280691, 7865845.167206755, 7914536.59044879, 7916483.07387754, 7991595.347915781, 8026099.297865809, 8052393.75, 8087670.5716077695, 8097850.385716441, 8125306.700985716, 8126099.9259408405, 8130735.9375, 8131623.738374101, 8172803.919397924, 8213339.817450502, 8214704.591081034, 8217505.854354308, 8224406.25, 8228581.683523215, 8326600.611587316, 8327324.686112045, 8332902.169964398, 8338855.00767743, 8349257.476523206, 8386606.25, 8387660.9375, 8427980.624325983, 8433359.929640347, 8435330.199759835, 8438617.1875, 8469229.806486553, 8476329.374803443, 8500304.325850366, 8503318.053305008, 8511908.366765777, 8533634.845429057, 8543291.740086786, 8544399.059510551, 8592783.75183982, 8603027.087979129, 8603043.542361606, 8615650.86408669, 8625874.952723235, 8651462.673507411, 8651676.322336784, 8653596.258967292, 8667936.172060711, 8670551.5625, 8670889.042176373, 8676930.143031027, 8677170.3125, 8678913.664433649, 8694407.8125, 8694427.517860075, 8695595.980770558, 8700597.837422999, 8711767.1875, 8716408.124016589, 8717875.0, 8736845.581473047, 8743045.3125, 8748004.6875, 8748606.25, 8756021.875, 8775237.5, 8782052.88372687, 8787708.59860103, 8795734.218067693, 8816867.1875, 8816922.798682874, 8825347.64803209, 8833081.25, 8853554.6875, 8859444.705556225, 8859578.6363653, 8859579.6875, 8871585.717284122, 8876250.740633415, 8887835.51796513, 8890605.03782204, 8935534.375, 8937950.929659447, 8948017.625131402, 8959326.807014374, 8960588.09953296, 8960637.41914913, 8966548.4375, 8991165.584580181, 8995068.533252964, 8995111.93153116, 9001693.229279501, 9012786.959819162, 9020817.77172501, 9024360.863919005, 9035916.138989814, 9035937.408599406, 9043095.797697764, 9046624.398766547, 9062585.612088056, 9062678.175913513, 9063899.061951827, 9064356.25, 9085422.385608248, 9102796.564227685, 9105887.346503984, 9111441.407913553, 9111708.645886386, 9115581.119344415, 9115587.084474368, 9120254.860051604, 9133696.76914021, 9148915.961961595, 9151940.625, 9152484.375, 9153064.844444005, 9155206.25, 9157926.5625, 9162995.510953344, 9180154.535012972, 9188666.77034986, 9189584.512773568, 9189826.5625, 9191035.208334118, 9199445.753187139, 9221125.63886786, 9245615.80814999, 9246947.045589464, 9307811.68126225, 9310464.234727066, 9310850.128099142, 9317574.924833443, 9323507.037196372, 9324846.070135035, 9325353.757252859, 9330455.895613158, 9360756.25, 9375289.089428872, 9377036.09796976, 9392421.808915967, 9395128.125, 9395326.039032504, 9421254.6875, 9432795.998156127, 9446415.625, 9447111.444627598, 9463242.1875, 9559314.894869652, 9559336.478117174, 9594834.289633863, 9758995.12640041, 9763370.966231855, 9763470.663915101, 10728269.7823301], [30.320860990405826, 22.170869528891718, 7.431568777862844, 80.66400817174606, 12.674078988611665, 11.127697901473386, 50.83698740531698, 69.17202139037546, 56.37242203815777, 15.62736003562284, 12.19271572785449, 110.87488559597325, 5.504910406740398, 14.202875903819152, 22.964994816741147, 68.00423390303746, 55.83286309458055, 14.877507894416231, 6.710696563236267, 30.99562904909903, 11.83344263861785, 5.830306992868887, 38.6335716361438, 25.89537234988986, 58.91965459516548, 50.239438196700156, 73.72604624841131, 78.51981885857649, 48.212157116181785, 5.366138797384379, 18.037461812533788, 6.308630503312677, 25.381741645796236, 97.61856691961567, 18.096935277470596, 60.544939290580814, 109.39518641089563, 16.40553126792265, 72.07004393682053, 30.8357359246843, 22.157702524211537, 58.32066455064134, 38.45220119474472, 9.143752963819932, 67.2984568177086, 39.469390880536025, 13.010158909521179, 128.5086091717205, 72.9034603542684, 72.22445286307553, 69.28105507472637, 47.39325185329389, 113.77485323641736, 16.86060017547379, 120.30101182429384, 35.19056790274855, 7.757800282854381, 24.212579770103254, 96.84189343835244, 41.155979083527086, 15.998644839039295, 181.4945354839325, 56.26695064406965, 12.739121305609638, 50.89621365759987, 67.36625994659198, 16.129038163100766, 11.22081753506387, 25.642220645465528, 56.232477552596954, 18.795029075517153, 25.36303030020147, 6.157439141417907, 21.307811488629117, 45.50348974283371, 5.639320688177246, 7.631831636361211, 13.079392507002554, 11.794747654470582, 40.01117289494016, 22.562809964537358, 27.541562905567787, 28.85030394883032, 31.279420043000925, 9.259635923123467, 15.74140305037161, 55.107820833777325, 16.913767398767384, 13.710191272049775, 76.80071909166789, 31.41422190705474, 5.881168343328856, 25.99007848344864, 84.03776719473746, 50.61485480584374, 67.37666755410702, 91.1189247634949, 6.379559153745186, 37.48568959463694, 62.38753705584746, 12.848866758816714, 87.54483680318998, 7.199232883563065, 56.920671345515146, 11.433763804555314, 7.856825201846895, 21.20102810623149, 9.685180665075293, 76.83809553021206, 36.58923955571897, 51.1187937563058, 83.20813439552784, 25.40349622849145, 6.560449772935106, 131.14061820237143, 17.603754067430078, 23.188792844273223, 43.12045701455649, 56.67321263404382, 23.39175895183602, 5.23627583954049, 13.571211272416965, 150.55361763829433, 80.3551748878013, 11.71563460601171, 36.62900346805152, 20.003867173791793, 69.96874092388468, 10.023877944505092, 13.985074666738562, 32.84210650954339, 71.3463972941583, 18.56300222506302, 13.104256389313937, 8.33362216738357, 40.15562211554754, 5.0717546389377155, 9.257254170937685, 12.030064452340794, 22.46288648571479, 37.387436183752904, 41.024401343161976, 6.118465328305402, 43.68525834072128, 7.420095354797652, 8.931153788575475, 18.917329296695996, 77.84282476705475, 28.628372158884932, 55.8181855765688, 12.216467823253561, 60.76660437386949, 15.837343816461818, 37.99632714178994, 27.308294717082408, 55.05986170937929, 48.85471499912214, 31.76333689223409, 104.73024444097705, 55.93198046476955, 16.6170727220057, 34.95767844373004, 6.253765270444262, 66.4163145238133, 26.54024333480787, 55.1106926111359, 6.4034535056167385, 19.01235671208711, 42.852343430668775, 31.214168972156642, 115.87263036916036, 14.28222738058571, 16.101154869465198, 20.312414294787086, 22.87598665548086, 11.55828944159045, 85.86748091903213, 59.412612404096116, 17.073624901321118, 16.02038017166472, 112.93304065997921, 10.680993335935499, 93.48629012776495, 48.75258183777105, 19.646175183816492, 5.706055054827769, 13.65826851187669, 6.517909929022802, 19.11606930384472, 20.66944407856117, 7.851870950939608, 48.92551151568912, 6.055550728464483, 30.569955533408674, 10.064688413364724, 5.717194868731654, 5.557672402972741, 63.50902169283923, 28.848417809797674, 9.125827360215236, 5.495134674634258, 16.79837382751727, 11.379092305913113, 124.58366571153394, 41.22767715405615, 134.77824828205806, 16.281257374158436, 73.17127914971226, 9.46411532169086, 20.736512090358215, 37.498186134330844, 8.996895869161367, 43.7979506327564, 9.672526761816032, 53.93611193478273, 18.847196622878275, 28.850430367825375, 15.729391207735182, 14.54149051163617, 6.263541497910122, 25.724935065764743, 18.60106484044793, 17.530748653444988, 7.25967773870215, 11.36436023294251, 112.75967211361215, 9.237981110951699, 51.92599815958417, 24.54949430247812, 43.311407819392215, 5.9014847802940595, 39.820705720217376, 9.821794357012417, 139.39180803751088, 11.543690227918452, 27.352653788704078, 6.681754691218765, 80.09425772319143, 19.286816747242394, 30.545833161946604, 15.572064571091076, 15.47190063010051, 11.038233740275947, 65.49794718125355, 13.616957374543361, 84.82535169641486, 73.23808028671147, 6.065172568286356, 9.556312880173431, 28.50115266303763, 42.39768234391521, 18.80752488107479, 83.23919584853782, 12.926180065246374, 55.1549862410321, 114.87118780569354, 28.25180565343351, 69.31512418817064, 48.9460777374221, 64.33797951088222, 49.73015732654528, 13.48564329299835, 8.852945224336462, 6.725950568453193, 33.29685386767252, 21.458770433493946, 21.326583968324165, 23.77366278750536, 27.461611898208496, 19.509103012523447, 128.28876212667257, 71.77913394235574, 49.647527070581965, 5.2450622804869615, 24.418700994264565, 6.483621918735957, 49.26108689060513, 7.620054290396512, 49.87754257397735, 8.707748096232587, 12.516819802290668, 5.734760335561683, 22.236920311536952, 22.39796441425002, 21.553062295908106, 12.471234534429287, 16.431049683200655, 29.06102125904074, 47.097142844312174, 12.251105559663818, 38.52904663824508, 21.252654518325123, 25.028074730021842, 14.93416978319961, 26.104707862456294, 120.20071209633453, 22.04308442406861, 27.184722921418878, 7.022951738904809, 20.979284150259492, 6.884197210450611, 36.51488485057313, 22.273651027623302, 8.955629931850591, 23.40824661094376, 48.166603259527285, 88.02366289947084, 71.15003085522451, 26.946820964275812, 26.690929532365335, 18.038327595059915, 20.70148278897794, 28.318034565771665, 37.567965552176645, 20.723591700079258, 21.44490694500047, 27.651831587401514, 64.90240053586224, 22.571639753860875, 13.31641782551532, 28.318520034751632, 37.61291307281162, 38.3976994778113, 39.89091647643953, 29.57946220516455, 5.335098170057195, 88.1125684568447, 52.09911636080996, 29.726857393905743, 14.764213484777276, 6.942418960263164, 69.81626025334263, 29.142035250981635, 33.11689313599014, 20.087648468801547, 72.08037194739737, 7.959772032436042, 166.62387185508737, 244.224035961809, 8.807383256173118, 15.715768236218134, 27.46786146164481, 41.81636553732665, 27.180797571413116, 16.72368033606405, 15.102816333681893, 13.75486151119392, 14.08404833517663, 9.608927796200444, 8.164085471073918, 43.226697058984996, 16.152669623185954, 6.561040451065071, 34.0053647803958, 15.067473844915753, 29.078430121862365, 37.25868700881359, 29.894283850848996, 29.494629028571868, 42.07352250469074, 8.221991944322042, 34.88306874755972, 20.998678108049308, 46.788534471219975, 10.412636011518767, 14.555154008184974, 21.820242385726125, 8.111506934001183, 90.37011001645917, 22.287574690596273, 5.518105556536292, 18.332029748796693, 10.83259418751868, 12.803299628469297, 5.665782568102469, 30.613369344971368, 19.84568521079315, 36.03280463216235, 78.72526930203986, 36.337403085648226, 6.141319951580628, 14.108175896515796, 5.311330413609051, 75.45680385602367, 12.283175103382892, 16.62768388857285, 49.43857439033305, 18.092620034460076, 5.699465309637223, 11.034133827999305, 60.95163152734765, 28.780344757946914, 25.61049437038513, 54.1015343925531, 9.69387160178769, 137.24807092296462, 15.083330117279358, 7.569531900898601, 11.830051728514743, 32.689335254954386, 23.895233961657713, 66.07686732683047, 97.49391799746518, 8.446515851348133, 11.81615106767644, 58.286723918124395, 19.674100440163734, 90.54204882210476, 84.773266129959, 5.794909445416539, 40.30647466444362, 59.8781590019465, 23.443823447428972, 72.76613692598633, 18.19336671979977, 96.68124724189114, 15.07823815567386, 67.37811519125843, 35.8785582566412, 14.655830856301879, 40.016520588341635, 16.99296931819862, 27.14077523093824, 39.044803768958346, 16.22734508200644, 74.97493538137962, 12.55590074914741, 14.586314209467574, 22.601332482077645, 50.41811819979592, 11.880437376339609, 117.15112932982223, 79.0803608197437, 16.136813337997904, 16.32056861530457, 50.44999674727427, 59.82500070965811, 143.14748883461894, 13.271945925415782, 17.581868525611377, 12.035421055466326, 79.81752720248865, 8.350517901514133, 18.494948852420826, 52.577417537262576, 59.539003071731884, 105.42879467092916, 9.763594686008775, 10.493661844576865, 12.26238987259997, 20.346611524277503, 12.062068136136697, 7.5298260236806955, 62.69036581383866, 9.291745383222617, 15.646821190831332, 25.25465939776423, 20.408767248074604, 51.137873839922264, 77.35253422494884, 104.26707942798478, 28.695962647268793, 65.42988741141842, 9.016064571147826, 117.2878910427985, 31.705727650286846, 17.83967611120586, 5.228655124505753, 37.16037008303525, 8.458481422718094, 41.205346173458835, 5.2527361772807835, 60.040141950922525, 73.47969130614378, 36.893949345618154, 40.098349060347196, 94.45746577038673, 10.770421596657005, 80.65075447599274, 39.98010715914974, 82.90857483629739, 5.667273403419574, 10.083458405114746, 123.2805518923589, 33.269738569993905, 36.65262044762933, 17.329470707638503, 30.313947102859306, 14.16370981676113, 17.61961346968932, 36.69346135525015, 7.216689732700151, 51.472843246709374, 93.15550066157763, 60.65332114808953, 15.305055785563102, 12.214822153796893, 9.263962226443946, 62.44029162929186, 8.265317686809707, 24.875809689827214, 5.229508774168729, 21.288862785489176, 21.101425475589732, 5.562122949423395, 9.269951715364732, 12.03889783735723, 77.30163816873092, 108.86313141279619, 20.53937929380444, 10.654507506849482, 48.79948880921664, 20.38687791546983, 45.604934765582506, 34.57387644748004, 19.245991152550697, 14.387042850744567, 19.094066998925495, 19.476244901178468, 61.77669144606806, 6.216089350538471, 6.289247976179715, 26.593764320605818, 29.36183920688189, 56.50204046283983, 39.46794792852487, 36.72382921649656, 46.01743845158465, 57.47771675170285, 29.428805718745558, 9.205711267827054, 22.361399373550086, 29.588262007123895, 66.4250276689874, 19.475838887847058, 9.734067550549343, 64.82133504555995, 15.688780471775148, 6.106020509572202, 5.314628041869088, 9.481404089875856, 15.647665066810656, 27.1212751331605, 49.86309504670136, 12.372721429706703, 13.067822954761631, 11.298455005046634, 75.58367617303264, 24.939961175718786, 7.662326634047457, 43.78475666750924, 34.55415022527537, 77.62861981304478, 39.94566888697686, 12.400248465706607, 95.83628954338043, 21.75230232882866, 57.254544765117316, 12.737066992309554, 8.594769491018035, 37.46847591656328, 25.323526740366013, 18.19846428525153, 6.312642096878611, 113.26699067458321])
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);
([4881649.343243063, 5053871.4403611, 5107035.436535794, 5162669.16725497, 5177963.305834031, 5188773.437494305, 5202281.25, 5203907.8125, 5217171.349422473, 5219173.515354244, 5221822.463994174, 5225107.020795091, 5258441.593076684, 5258506.04170324, 5258968.385892125, 5260596.299944217, 5261518.75, 5261543.733106498, 5264791.917093218, 5264891.144049264, 5266434.784005188, 5267208.030745455, 5267930.032843101, 5268049.851193583, 5271960.814355197, 5272550.0, 5273443.75, 5274176.0848837895, 5276300.580509068, 5286538.190111452, 5287835.232609589, 5298830.008545245, 5314760.755289578, 5317570.36321357, 5318867.825526128, 5319457.423394685, 5420700.222751743, 5543201.900010485, 5559193.75, 5720670.110167018, 5724463.437554189, 5726974.980291154, 5729706.95530208, 5743024.769412295, 5783290.625, 5846665.625, 5877668.130460224, 5897984.361997194, 6275985.9375, 6287768.257067054, 6289675.0, 6289744.038736158, 6330238.846526845, 6364591.730056233, 6375361.182564197, 6376451.522013201, 6398262.908037604, 6401617.972103576, 6404851.232719399, 6412313.606884116, 6420009.627211083, 6429731.375488167, 6432300.966456673, 6432857.86548686, 6434771.635874247, 6435782.8125, 6447087.780187569, 6450520.37126369, 6450564.1122842645, 6454484.375, 6454964.804060014, 6454974.816541876, 6455036.578897461, 6456833.5297495155, 6464394.193829272, 6466947.323031784, 6467970.390872096, 6469107.219899125, 6469186.326085357, 6469420.598748317, 6471383.446668989, 6474289.010789075, 6474298.070945025, 6475106.25, 6475209.288886982, 6483559.570142792, 6486299.552544634, 6491319.186304534, 6498792.452222546, 6500947.755445765, 6500948.4375, 6504646.18105772, 6506049.31716288, 6509689.054586425, 6509883.546082975, 6510458.514258573, 6512075.0, 6512843.027925683, 6513926.9723296445, 6516882.8125, 6522089.941001628, 6522445.581906915, 6522703.412853687, 6531178.125, 6531576.74986213, 6534533.463127606, 6537653.243382115, 6537664.453222744, 6538359.375, 6539235.407318998, 6539959.121241704, 6541746.875, 6541760.756737421, 6544116.077535441, 6549233.979058479, 6550709.063694835, 6550835.858631522, 6550967.1875, 6551476.051364888, 6552207.483867106, 6555749.679973987, 6558685.524640246, 6558782.280802004, 6561161.193801563, 6562845.65866989, 6562958.295656848, 6565049.33652119, 6567570.3125, 6569663.219246257, 6569815.349194306, 6571273.4375, 6572617.637963682, 6573006.595003382, 6577065.041969872, 6580523.525415445, 6581237.5, 6581700.156574135, 6583185.848486071, 6583530.197091435, 6583988.654515303, 6585631.489107454, 6586723.267219069, 6587195.599530872, 6588757.493683096, 6593866.651065565, 6594251.047909875, 6599647.575773, 6609448.4375, 6617059.375, 6617153.125, 6618178.725315134, 6620875.0, 6621381.466725463, 6621913.075493945, 6624077.405067886, 6625384.993024902, 6625473.157351252, 6625857.31127104, 6626240.194242625, 6626473.929290472, 6627990.232701303, 6628270.070298454, 6632760.830432477, 6639539.0625, 6646502.336572198, 6648090.287693897, 6652422.882367563, 6652621.2999873115, 6653082.79362064, 6658161.02741062, 6658294.291559934, 6659302.940563913, 6661311.211757207, 6661334.85437883, 6663534.027864763, 6665950.259049204, 6669416.280541368, 6669894.334133039, 6684087.965748717, 6685402.84505669, 6692732.602297646, 6694513.756584367, 6697800.847890002, 6698687.5, 6698749.731699008, 6701667.176449026, 6705033.933264081, 6705079.881322159, 6706333.598390128, 6706853.935851662, 6708722.513815513, 6710209.375, 6719212.181081483, 6719468.613288634, 6719977.318708333, 6720115.787752059, 6720914.558999339, 6721064.0625, 6723629.03772335, 6724601.3089395445, 6728469.505042061, 6728961.808350096, 6731275.155087954, 6732898.4375, 6736460.9375, 6741398.704556145, 6746462.812074188, 6749147.840121914, 6749157.965390318, 6749402.83088367, 6749945.3125, 6751115.200999348, 6754501.5625, 6756375.377640786, 6759026.1816690825, 6760692.9928873945, 6760705.8136429945, 6761222.067415024, 6762541.228793949, 6767118.721001046, 6768827.96528704, 6772949.151309938, 6774692.624088595, 6775475.5009714635, 6777259.630375184, 6779404.6875, 6780448.324908295, 6781402.557262627, 6781776.322560421, 6781868.129787377, 6784057.366509688, 6789046.875, 6793864.590614537, 6794645.3125, 6799279.938272896, 6799969.250091762, 6801166.763734603, 6804301.054960216, 6804410.359564144, 6813871.403730688, 6814644.491099875, 6817592.182199236, 6823537.441993702, 6828229.3954047905, 6828623.040390318, 6831138.175016324, 6831639.0625, 6831856.026609033, 6833900.254529537, 6835038.611426537, 6835187.5, 6836481.3141978895, 6838058.791904682, 6838967.00281934, 6839628.125, 6841362.5, 6841794.581787404, 6843151.5625, 6844785.9375, 6845470.03627634, 6848067.1875, 6849557.369756944, 6854066.561707438, 6854101.371426939, 6855008.298499223, 6858670.2613957785, 6861117.888243452, 6861473.689079379, 6863818.693892796, 6864796.150107135, 6866666.388841736, 6868557.8125, 6869968.75, 6870023.434533733, 6884927.875552824, 6885768.727832706, 6888776.5625, 6898165.6712573245, 6907446.554317365, 6914313.219704918, 6916917.925300098, 6921106.681182243, 6925352.696466071, 6927869.898663969, 6928668.255989978, 6930655.4050871115, 6940519.189841322, 6945842.1875, 6955690.625, 6956628.741702721, 6958390.180668435, 6961524.47555385, 6966918.09605031, 6967493.748073027, 6970317.663374395, 6972946.06505769, 6972947.9085950265, 6973379.615929671, 6975380.86155148, 6977921.321902175, 6983408.388397671, 6984234.375, 6985319.887341579, 6989010.45693814, 7001118.422705798, 7004172.531885268, 7005174.812063578, 7005856.240025113, 7008238.837904925, 7019726.112282395, 7028242.816354029, 7028243.931858632, 7030556.518105478, 7031795.3125, 7031981.519084913, 7034213.877409893, 7034494.577781384, 7038346.875, 7038641.978563074, 7041482.308980701, 7041502.643770505, 7044942.1875, 7052396.5736308945, 7054178.125, 7060573.890140984, 7060643.549507857, 7061027.950942567, 7062217.371594764, 7062381.286107646, 7062396.426335311, 7068019.584640605, 7077470.3125, 7079972.484418764, 7084337.832069618, 7084577.471538811, 7085098.161939983, 7085529.013767679, 7097567.1875, 7099376.5625, 7108757.120130836, 7115362.689314417, 7116230.251032372, 7121810.9375, 7124906.178207761, 7131577.527069694, 7151710.979186693, 7156949.6494439775, 7156959.13024582, 7163490.935939505, 7177665.385953536, 7185820.701194632, 7186529.972691717, 7186664.5185581045, 7189395.3125, 7189864.095160314, 7193870.3125, 7195706.621257125, 7198330.782341336, 7200894.455837157, 7202381.25, 7205668.625838078, 7207654.507213329, 7207990.07396582, 7213101.5625, 7215374.488682377, 7217998.167330728, 7219101.094680832, 7225279.341086531, 7227951.5625, 7230629.263617537, 7230874.687538368, 7230899.35086396, 7232093.552619054, 7232391.484846328, 7245108.711319372, 7247861.442557699, 7251872.754812502, 7255644.133735711, 7255900.0, 7261469.8507584175, 7261470.809190702, 7265062.262720123, 7291228.766738191, 7309795.914770963, 7339513.131747899, 7348167.569198976, 7366837.5, 7367868.850909375, 7368220.197298744, 7368645.658440577, 7382026.5625, 7434510.194195079, 7441379.52036574, 7464524.288070812, 7467670.71217188, 7475922.794914317, 7483934.411717307, 7497904.593336954, 7503112.907224192, 7507395.099257491, 7514363.773728212, 7519353.807713266, 7537515.625, 7591136.228176911, 7682320.71240632, 7702022.981887472, 7741482.10852827, 7770370.3125, 7773518.75, 7824102.863886314, 7833107.251481257, 7847868.266282218, 7849818.902280691, 7865845.167206755, 7914536.59044879, 7916483.07387754, 7991595.347915781, 8026099.297865809, 8052393.75, 8087670.5716077695, 8097850.385716441, 8125306.700985716, 8126099.9259408405, 8130735.9375, 8131623.738374101, 8172803.919397924, 8213339.817450502, 8214704.591081034, 8217505.854354308, 8224406.25, 8228581.683523215, 8326600.611587316, 8327324.686112045, 8332902.169964398, 8338855.00767743, 8349257.476523206, 8386606.25, 8387660.9375, 8427980.624325983, 8433359.929640347, 8435330.199759835, 8438617.1875, 8469229.806486553, 8476329.374803443, 8500304.325850366, 8503318.053305008, 8511908.366765777, 8533634.845429057, 8543291.740086786, 8544399.059510551, 8592783.75183982, 8603027.087979129, 8603043.542361606, 8615650.86408669, 8625874.952723235, 8651462.673507411, 8651676.322336784, 8653596.258967292, 8667936.172060711, 8670551.5625, 8670889.042176373, 8676930.143031027, 8677170.3125, 8678913.664433649, 8694407.8125, 8694427.517860075, 8695595.980770558, 8700597.837422999, 8711767.1875, 8716408.124016589, 8717875.0, 8736845.581473047, 8743045.3125, 8748004.6875, 8748606.25, 8756021.875, 8775237.5, 8782052.88372687, 8787708.59860103, 8795734.218067693, 8816867.1875, 8816922.798682874, 8825347.64803209, 8833081.25, 8853554.6875, 8859444.705556225, 8859578.6363653, 8859579.6875, 8871585.717284122, 8876250.740633415, 8887835.51796513, 8890605.03782204, 8935534.375, 8937950.929659447, 8948017.625131402, 8959326.807014374, 8960588.09953296, 8960637.41914913, 8966548.4375, 8991165.584580181, 8995068.533252964, 8995111.93153116, 9001693.229279501, 9012786.959819162, 9020817.77172501, 9024360.863919005, 9035916.138989814, 9035937.408599406, 9043095.797697764, 9046624.398766547, 9062585.612088056, 9062678.175913513, 9063899.061951827, 9064356.25, 9085422.385608248, 9102796.564227685, 9105887.346503984, 9111441.407913553, 9111708.645886386, 9115581.119344415, 9115587.084474368, 9120254.860051604, 9133696.76914021, 9148915.961961595, 9151940.625, 9152484.375, 9153064.844444005, 9155206.25, 9157926.5625, 9162995.510953344, 9180154.535012972, 9188666.77034986, 9189584.512773568, 9189826.5625, 9191035.208334118, 9199445.753187139, 9221125.63886786, 9245615.80814999, 9246947.045589464, 9307811.68126225, 9310464.234727066, 9310850.128099142, 9317574.924833443, 9323507.037196372, 9324846.070135035, 9325353.757252859, 9330455.895613158, 9360756.25, 9375289.089428872, 9377036.09796976, 9392421.808915967, 9395128.125, 9395326.039032504, 9421254.6875, 9432795.998156127, 9446415.625, 9447111.444627598, 9463242.1875, 9559314.894869652, 9559336.478117174, 9594834.289633863, 9758995.12640041, 9763370.966231855, 9763470.663915101, 10728269.7823301], [30.320860990405826, 22.170869528891718, 7.431568777862844, 80.66400817174606, 12.674078988611665, 11.127697901473386, 50.83698740531698, 69.17202139037546, 56.37242203815777, 15.62736003562284, 12.19271572785449, 110.87488559597325, 5.504910406740398, 14.202875903819152, 22.964994816741147, 68.00423390303746, 55.83286309458055, 14.877507894416231, 6.710696563236267, 30.99562904909903, 11.83344263861785, 5.830306992868887, 38.6335716361438, 25.89537234988986, 58.91965459516548, 50.239438196700156, 73.72604624841131, 78.51981885857649, 48.212157116181785, 5.366138797384379, 18.037461812533788, 6.308630503312677, 25.381741645796236, 97.61856691961567, 18.096935277470596, 60.544939290580814, 109.39518641089563, 16.40553126792265, 72.07004393682053, 30.8357359246843, 22.157702524211537, 58.32066455064134, 38.45220119474472, 9.143752963819932, 67.2984568177086, 39.469390880536025, 13.010158909521179, 128.5086091717205, 72.9034603542684, 72.22445286307553, 69.28105507472637, 47.39325185329389, 113.77485323641736, 16.86060017547379, 120.30101182429384, 35.19056790274855, 7.757800282854381, 24.212579770103254, 96.84189343835244, 41.155979083527086, 15.998644839039295, 181.4945354839325, 56.26695064406965, 12.739121305609638, 50.89621365759987, 67.36625994659198, 16.129038163100766, 11.22081753506387, 25.642220645465528, 56.232477552596954, 18.795029075517153, 25.36303030020147, 6.157439141417907, 21.307811488629117, 45.50348974283371, 5.639320688177246, 7.631831636361211, 13.079392507002554, 11.794747654470582, 40.01117289494016, 22.562809964537358, 27.541562905567787, 28.85030394883032, 31.279420043000925, 9.259635923123467, 15.74140305037161, 55.107820833777325, 16.913767398767384, 13.710191272049775, 76.80071909166789, 31.41422190705474, 5.881168343328856, 25.99007848344864, 84.03776719473746, 50.61485480584374, 67.37666755410702, 91.1189247634949, 6.379559153745186, 37.48568959463694, 62.38753705584746, 12.848866758816714, 87.54483680318998, 7.199232883563065, 56.920671345515146, 11.433763804555314, 7.856825201846895, 21.20102810623149, 9.685180665075293, 76.83809553021206, 36.58923955571897, 51.1187937563058, 83.20813439552784, 25.40349622849145, 6.560449772935106, 131.14061820237143, 17.603754067430078, 23.188792844273223, 43.12045701455649, 56.67321263404382, 23.39175895183602, 5.23627583954049, 13.571211272416965, 150.55361763829433, 80.3551748878013, 11.71563460601171, 36.62900346805152, 20.003867173791793, 69.96874092388468, 10.023877944505092, 13.985074666738562, 32.84210650954339, 71.3463972941583, 18.56300222506302, 13.104256389313937, 8.33362216738357, 40.15562211554754, 5.0717546389377155, 9.257254170937685, 12.030064452340794, 22.46288648571479, 37.387436183752904, 41.024401343161976, 6.118465328305402, 43.68525834072128, 7.420095354797652, 8.931153788575475, 18.917329296695996, 77.84282476705475, 28.628372158884932, 55.8181855765688, 12.216467823253561, 60.76660437386949, 15.837343816461818, 37.99632714178994, 27.308294717082408, 55.05986170937929, 48.85471499912214, 31.76333689223409, 104.73024444097705, 55.93198046476955, 16.6170727220057, 34.95767844373004, 6.253765270444262, 66.4163145238133, 26.54024333480787, 55.1106926111359, 6.4034535056167385, 19.01235671208711, 42.852343430668775, 31.214168972156642, 115.87263036916036, 14.28222738058571, 16.101154869465198, 20.312414294787086, 22.87598665548086, 11.55828944159045, 85.86748091903213, 59.412612404096116, 17.073624901321118, 16.02038017166472, 112.93304065997921, 10.680993335935499, 93.48629012776495, 48.75258183777105, 19.646175183816492, 5.706055054827769, 13.65826851187669, 6.517909929022802, 19.11606930384472, 20.66944407856117, 7.851870950939608, 48.92551151568912, 6.055550728464483, 30.569955533408674, 10.064688413364724, 5.717194868731654, 5.557672402972741, 63.50902169283923, 28.848417809797674, 9.125827360215236, 5.495134674634258, 16.79837382751727, 11.379092305913113, 124.58366571153394, 41.22767715405615, 134.77824828205806, 16.281257374158436, 73.17127914971226, 9.46411532169086, 20.736512090358215, 37.498186134330844, 8.996895869161367, 43.7979506327564, 9.672526761816032, 53.93611193478273, 18.847196622878275, 28.850430367825375, 15.729391207735182, 14.54149051163617, 6.263541497910122, 25.724935065764743, 18.60106484044793, 17.530748653444988, 7.25967773870215, 11.36436023294251, 112.75967211361215, 9.237981110951699, 51.92599815958417, 24.54949430247812, 43.311407819392215, 5.9014847802940595, 39.820705720217376, 9.821794357012417, 139.39180803751088, 11.543690227918452, 27.352653788704078, 6.681754691218765, 80.09425772319143, 19.286816747242394, 30.545833161946604, 15.572064571091076, 15.47190063010051, 11.038233740275947, 65.49794718125355, 13.616957374543361, 84.82535169641486, 73.23808028671147, 6.065172568286356, 9.556312880173431, 28.50115266303763, 42.39768234391521, 18.80752488107479, 83.23919584853782, 12.926180065246374, 55.1549862410321, 114.87118780569354, 28.25180565343351, 69.31512418817064, 48.9460777374221, 64.33797951088222, 49.73015732654528, 13.48564329299835, 8.852945224336462, 6.725950568453193, 33.29685386767252, 21.458770433493946, 21.326583968324165, 23.77366278750536, 27.461611898208496, 19.509103012523447, 128.28876212667257, 71.77913394235574, 49.647527070581965, 5.2450622804869615, 24.418700994264565, 6.483621918735957, 49.26108689060513, 7.620054290396512, 49.87754257397735, 8.707748096232587, 12.516819802290668, 5.734760335561683, 22.236920311536952, 22.39796441425002, 21.553062295908106, 12.471234534429287, 16.431049683200655, 29.06102125904074, 47.097142844312174, 12.251105559663818, 38.52904663824508, 21.252654518325123, 25.028074730021842, 14.93416978319961, 26.104707862456294, 120.20071209633453, 22.04308442406861, 27.184722921418878, 7.022951738904809, 20.979284150259492, 6.884197210450611, 36.51488485057313, 22.273651027623302, 8.955629931850591, 23.40824661094376, 48.166603259527285, 88.02366289947084, 71.15003085522451, 26.946820964275812, 26.690929532365335, 18.038327595059915, 20.70148278897794, 28.318034565771665, 37.567965552176645, 20.723591700079258, 21.44490694500047, 27.651831587401514, 64.90240053586224, 22.571639753860875, 13.31641782551532, 28.318520034751632, 37.61291307281162, 38.3976994778113, 39.89091647643953, 29.57946220516455, 5.335098170057195, 88.1125684568447, 52.09911636080996, 29.726857393905743, 14.764213484777276, 6.942418960263164, 69.81626025334263, 29.142035250981635, 33.11689313599014, 20.087648468801547, 72.08037194739737, 7.959772032436042, 166.62387185508737, 244.224035961809, 8.807383256173118, 15.715768236218134, 27.46786146164481, 41.81636553732665, 27.180797571413116, 16.72368033606405, 15.102816333681893, 13.75486151119392, 14.08404833517663, 9.608927796200444, 8.164085471073918, 43.226697058984996, 16.152669623185954, 6.561040451065071, 34.0053647803958, 15.067473844915753, 29.078430121862365, 37.25868700881359, 29.894283850848996, 29.494629028571868, 42.07352250469074, 8.221991944322042, 34.88306874755972, 20.998678108049308, 46.788534471219975, 10.412636011518767, 14.555154008184974, 21.820242385726125, 8.111506934001183, 90.37011001645917, 22.287574690596273, 5.518105556536292, 18.332029748796693, 10.83259418751868, 12.803299628469297, 5.665782568102469, 30.613369344971368, 19.84568521079315, 36.03280463216235, 78.72526930203986, 36.337403085648226, 6.141319951580628, 14.108175896515796, 5.311330413609051, 75.45680385602367, 12.283175103382892, 16.62768388857285, 49.43857439033305, 18.092620034460076, 5.699465309637223, 11.034133827999305, 60.95163152734765, 28.780344757946914, 25.61049437038513, 54.1015343925531, 9.69387160178769, 137.24807092296462, 15.083330117279358, 7.569531900898601, 11.830051728514743, 32.689335254954386, 23.895233961657713, 66.07686732683047, 97.49391799746518, 8.446515851348133, 11.81615106767644, 58.286723918124395, 19.674100440163734, 90.54204882210476, 84.773266129959, 5.794909445416539, 40.30647466444362, 59.8781590019465, 23.443823447428972, 72.76613692598633, 18.19336671979977, 96.68124724189114, 15.07823815567386, 67.37811519125843, 35.8785582566412, 14.655830856301879, 40.016520588341635, 16.99296931819862, 27.14077523093824, 39.044803768958346, 16.22734508200644, 74.97493538137962, 12.55590074914741, 14.586314209467574, 22.601332482077645, 50.41811819979592, 11.880437376339609, 117.15112932982223, 79.0803608197437, 16.136813337997904, 16.32056861530457, 50.44999674727427, 59.82500070965811, 143.14748883461894, 13.271945925415782, 17.581868525611377, 12.035421055466326, 79.81752720248865, 8.350517901514133, 18.494948852420826, 52.577417537262576, 59.539003071731884, 105.42879467092916, 9.763594686008775, 10.493661844576865, 12.26238987259997, 20.346611524277503, 12.062068136136697, 7.5298260236806955, 62.69036581383866, 9.291745383222617, 15.646821190831332, 25.25465939776423, 20.408767248074604, 51.137873839922264, 77.35253422494884, 104.26707942798478, 28.695962647268793, 65.42988741141842, 9.016064571147826, 117.2878910427985, 31.705727650286846, 17.83967611120586, 5.228655124505753, 37.16037008303525, 8.458481422718094, 41.205346173458835, 5.2527361772807835, 60.040141950922525, 73.47969130614378, 36.893949345618154, 40.098349060347196, 94.45746577038673, 10.770421596657005, 80.65075447599274, 39.98010715914974, 82.90857483629739, 5.667273403419574, 10.083458405114746, 123.2805518923589, 33.269738569993905, 36.65262044762933, 17.329470707638503, 30.313947102859306, 14.16370981676113, 17.61961346968932, 36.69346135525015, 7.216689732700151, 51.472843246709374, 93.15550066157763, 60.65332114808953, 15.305055785563102, 12.214822153796893, 9.263962226443946, 62.44029162929186, 8.265317686809707, 24.875809689827214, 5.229508774168729, 21.288862785489176, 21.101425475589732, 5.562122949423395, 9.269951715364732, 12.03889783735723, 77.30163816873092, 108.86313141279619, 20.53937929380444, 10.654507506849482, 48.79948880921664, 20.38687791546983, 45.604934765582506, 34.57387644748004, 19.245991152550697, 14.387042850744567, 19.094066998925495, 19.476244901178468, 61.77669144606806, 6.216089350538471, 6.289247976179715, 26.593764320605818, 29.36183920688189, 56.50204046283983, 39.46794792852487, 36.72382921649656, 46.01743845158465, 57.47771675170285, 29.428805718745558, 9.205711267827054, 22.361399373550086, 29.588262007123895, 66.4250276689874, 19.475838887847058, 9.734067550549343, 64.82133504555995, 15.688780471775148, 6.106020509572202, 5.314628041869088, 9.481404089875856, 15.647665066810656, 27.1212751331605, 49.86309504670136, 12.372721429706703, 13.067822954761631, 11.298455005046634, 75.58367617303264, 24.939961175718786, 7.662326634047457, 43.78475666750924, 34.55415022527537, 77.62861981304478, 39.94566888697686, 12.400248465706607, 95.83628954338043, 21.75230232882866, 57.254544765117316, 12.737066992309554, 8.594769491018035, 37.46847591656328, 25.323526740366013, 18.19846428525153, 6.312642096878611, 113.26699067458321])
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)