Beispiel #1
0
ms.mystyle_arial(fontsz=16)
dpiset = 200

ob = mlo.myloadmat_to_obj('./Pyecltest.mat')

#################################
# Variables saved per time step #
#################################

fig = pl.figure()
pl.plot(ob.t, ob.Nel_timep, linewidth=2)
pl.plot(ob.t, ob.Nelectrons, 'r--', linewidth=2)

pl.xlabel('Time [s]')
pl.ylabel('Number of $e^-$ per unit length [$m^{-1}$]')
ms.scix()
pl.grid('on')
pl.suptitle(
    'Var. name: Nel_timep\nNumber of electrons in the chamber at each time step'
)
pl.subplots_adjust(top=.82, bottom=.14)

fig = pl.figure()
sp1 = pl.subplot(4, 1, 1)
sp1.plot(ob.t, ob.y_first_ele, '.-')
sp1.set_ylabel('y [m]')
sp3 = pl.subplot(4, 1, 2, sharex=sp1)
sp3.plot(ob.t, ob.relative_charge_first_ele, '.-')
sp3.set_ylabel('Nel/nel_ref')
sp4 = pl.subplot(4, 1, 3, sharex=sp1)
sp4.plot(ob.t, ob.ref_size, '.-')
dpiset = 200

ob=mlo.myloadmat_to_obj('../../testing/tests_buildup/LHC_ArcDipReal_450GeV_sey1.60_2.5e11ppb_bl_1.00ns/Pyecltest_ref.mat')

ifig = 0

#################################
# Variables saved per time step #
#################################

#8.
ifig+=1; pl.figure(ifig)
pl.plot(ob.t, ob.lam_t_array, linewidth=2)
pl.xlabel('Time [s]')
pl.ylabel('Beam profile [p/m]') 
ms.scix(); pl.grid('on')
pl.suptitle('Var. name: lam_t_array\nBeam density at each time step')
pl.subplots_adjust(top=.82, bottom=.14)
pl.savefig('fig%02d.png'%ifig, dpi=dpiset)

#6.
ifig+=1; pl.figure(ifig)
pl.plot(ob.t, ob.Nel_timep, linewidth=2)
pl.xlabel('Time [s]')
pl.ylabel('Number of $e^-$ per unit length [$m^{-1}$]') 
ms.scix(); pl.grid('on')
pl.suptitle('Var. name: Nel_timep\nNumber of electrons in the chamber at each time step')
pl.subplots_adjust(top=.82, bottom=.14)
pl.savefig('fig%02d.png'%ifig, dpi=dpiset)

#5.
Beispiel #3
0
ob = mlo.myloadmat_to_obj('Pyecltest.mat')

ifig = 0


#################################
# Variables saved per time step #
#################################

#8.
ifig += 1; pl.figure(ifig)
pl.plot(ob.t, ob.lam_t_array, linewidth=2)
pl.xlabel('Time [s]')
pl.ylabel('Beam profile [p/m]')
ms.scix(); pl.grid('on')
pl.suptitle('Var. name: lam_t_array\nBeam density at each time step')
pl.subplots_adjust(top=.82, bottom=.14)

#6.
ifig += 1; pl.figure(ifig)
pl.plot(ob.t, ob.Nel_timep, linewidth=2)
pl.xlabel('Time [s]')
pl.ylabel('Number of $e^-$ per unit length [$m^{-1}$]')
ms.scix(); pl.grid('on')
pl.suptitle('Var. name: Nel_timep\nNumber of electrons in the chamber at each time step')
pl.subplots_adjust(top=.82, bottom=.14)

#5.
ifig += 1; pl.figure(ifig)
pl.plot(ob.t, ob.Nel_imp_time, linewidth=2)