Files
2016-06-09 15:58:43 +02:00

76 lines
1.4 KiB
Plaintext

macro tramu.kumac
*
set * ; opt *
*
filecase keep
set *fon -40
set mscf 1.5
set ygti 0.5 ; set gsiz 0.35 ; set ymgu 1.5
set vsiz 0.25 ; set yval 0.3 ; set ylab 0.55
set asiz 0.25 ; set yhti 0.9 ; set xlab 1.2
title '1 TeV muon in 3 m iron'
h/file 1 tramu.hbook
set dmod 1 ; set hcol 4 ; set plci 4
h/pl //lun1/10
key 960 0.07 1 'G4-9.1' ! l
exec data
set dmod 2 ; set hcol 2 ; set plci 2
h/pl 1 s
key 960 0.065 2 'Mars14' ! l
atitle Ekine(GeV) 1/GeV
exec Redraw-Axis
close 1 ; close 2
return
macro data
*
* muon 1 TeV/c in 3 m Iron
* Particle Data Group. Physics Letters B 592 (2004) page 251
* distribution of the muon kinetic energy
* (from 950 GeV to 1000 GeV by bin of 0.5 GeV --> 100 bins)
*
* *** read data
nbin=100
vector/create vect(2,[nbin])
vector/read vect mars14.ascii
**vector/write vect ! (1x,f6.1,3x,e12.6)
*
* *** create and fill histogram
Emin= 950.
Emax= 1000.
create/1dhisto 1 '3m iron. muon 1TeV/c' [nbin] [Emin] [Emax]
put/contents 1 vect(2)
**h/pl 1
* *** save histo
*
**h/file 111 mars14.hbook ! n
**hrout 0
return
Macro Redraw-Axis
set plci 1
X1 = $GRAFINFO('WNXMIN')
X2 = $GRAFINFO('WNXMAX')
Y1 = $GRAFINFO('WNYMIN')
Y2 = $GRAFINFO('WNYMAX')
IS = $GRAFINFO('?FAIS')
IC = $GRAFINFO('?FACI')
Set FAIS 0 ; Set FACI 1
Box [X1] [X2] [Y1] [Y2]
Set FAIS [IS] ; Set FACI [IC]
Tick XL [X1] !
* Tick YB ! [Y1]
Return