March 14, 1994
A new version of PAW (2.04/15) has been released on March 15th together with CERNLIB 94A. The source files the binaries and the libraries are available, via anonymous ftp, on the asis system.
New features and enhancements in this version are described below.
It is now possible to pass the workstation type to PAW without being prompted.
ex: paw default: you get the prompt "Give workstation type"
paw -w no prompt. Use default workstation type
paw -w 3 no prompt. Use workstation type 3.
pawX11 can be invoked from the paw++ module also with the option w:
/cern/new/bin/paw++ -w 2
Example of a macro and FCN.F file:
macro vfit
v/read x,y,ey vfit.dat
v/cre step(3)
v/cre pmin(3)
v/cre pmax(3)
v/cre err(3)
v/cre par(1) r 4.e-2
v/fit x(1:14) y(1:14) ey(1:14) fcn.f z 1 par step pmin pmax err
v/pri err(1)
return
Subroutine fcn(N,X,Y,EY,NPAR,IFLAG,NPFITS)
*
* User fitting model routine (chisquare technique is used)
* X(N),Y(N),EY(N) arrays given to the Vector/Fit command
* NPAR number of parameters
* IFLAG Minuit flag indicating the MINUIT action
*
* NPFITS output parameter containing the number of points used
* in the fit
*
DOUBLE PRECISION FITPAD(24),FITFUN
COMMON/HCFITD/FITPAD,FITFUN
*
dimension x(n),y(n),ey(n)
fitfun=0.
npfits=0
do 10 i=1,n
xu=x(i)
cu=y(i)
eu=ey(i)
if(eu.gt.0.)then
npfits=npfits+1
f=fitpad(1)
fitfun=fitfun+((cu-f)/eu)**2
endif
10 continue
end
By default, the symbols are not drawn if they are one the edges of the plot: the option '0' allows to turn off this symbols clipping. See the help for more details.
In order to define graphical cuts using a tracking cross cursor. This is useful on some black and white Xterminal on the crosshair cursor is not visible.
Draws a line taking care of log scales. The syntax is conform to BOX, ARROW etc ...
* GRAPHICS/PRIMITIVES/DLINE X1 X2 Y1 Y2
- X1 R 'X first coordinate'
- X2 R 'X second coordinate'
- Y1 R 'Y first coordinate'
- Y2 R 'Y second coordinate'
Draws a line connecting points (X1,Y1) and (X2,Y2) in the current
Normalization transformation taking care of logarithmic scales. Use
commands SLN, SLWSC and SPLCI (or IGSET) to change line attributes.
The user can now invoke a user COMIS routine in locator mode. When a mouse button is pressed, the user routine is called and the user has access in the common block QUEST all the information return by the HPLOT routine HPLCHA. Example:
+------------- File locate.f -----------+
| |
| Subroutine LOCATE |
| Common /Quest/Iquest(100) |
| Dimension Rquest(100) |
| Equivalence(Iquest(1),Rquest(1)) |
| IButton = Iquest(80) |
| Nt = Iquest(81) |
| Xwc = Rquest(82) |
| Ywc = Rquest(83) |
| Idh = Iquest(84) |
| Xloc = Rquest(85) |
| Yloc = Rquest(86) |
| Icx = Iquest(87) |
| Icy = Iquest(88) |
| XNdc = Rquest(11) |
| YNdc = Rquest(12) |
| Ntuple = Iquest(3) |
| End |
+----------------------------------------+
Where:
IButton = Mouse/Keybord button number
Nt = Normalisation transformation
Xwc = X world coordinate
Ywc = Y world coordinate
Idh = Histogram identifier
Xloc = X HPLOT coordinate (take care of OPTION LOGX)
Yloc = Y HPLOT coordinate (take care of OPTION LOGY)
Icx = X channel number
Icy = Y channel number
XNdc = X normalized coordinate
YNdc = Y normalized coordinate
Ntuple = 1 if the Idh is an Ntuple
The way to use this new possibility is:
PAW > LOCATE locate.f
PIAF connection can be opened automatically with the command HI/FILE:
PAW > hi/file 45 //piaf/test.hbook
**** Welcome to the Piaf server @ piaf2 ****
*** This is version 931013 of the Piaf server ***
Feb 15: The Piaf connection will close after 10 hours of inactivity.
**** Piaf slave server @ piaf1 started ****
**** Piaf slave server @ piaf2 started ****
**** Piaf slave server @ piaf3 started ****
**** Piaf slave server @ piaf4 started ****
**** Piaf slave server @ piaf5 started ****
Piaf server set to parallel mode (5 slaves)
PAW > ld //
//LUN45 //piaf/test.hbook
+------------- 0pamain.f ---------+
| PROGRAM PAMAIN |
| PARAMETER (NWPAW=2000000) |
| COMMON/PAWC/PAWCOM(NWPAW) |
| CALL PAW(NWPAW,IWTYP) |
| CALL KUWHAG |
| CALL PAEXIT |
| STOP |
+---------------------------------+
For PAW++, PAWPP should be called instead of PAW.
To access this facility, new rules for file extensions have been defined:
file.f77: The FORTRAN file, ``file.f'' is compiled
with the local fortran compiler and loaded in the
current PAW session.
file.c: The C file ``file.c'' is compiled with the local C
compiler and loaded in the current PAW session.
file.sl: The precompiled shared library ``file.sl'' is
loaded in the current PAW session.
MATHLIB: GAUSS, DGAUSS,
HBOOK: HKIND, HRENID.
ZEBRA: MZSTOR, MZDIV, MZLINK, MZWORK, MZBOOK, MZDROP, MZPUSH, MZLOGL
MZWIPE, MZGARB, MZFORM, LZFIND, LZFID, DZSHOW, DZVERI
FZIN, FZOUT, FZFILE, FZENDI, FZENDO
RZCDIR, RZLDIR, RZFILE, RZEND, RZIN, RZOUT, RZVIN, RZVOUT
RZOPEN, RZIODO, RZCLOS, RZQUOT
HELP CALL will produce the complete list.
SUBROUTINE HKIND(ID,KIND,CHOPT)
Returns the attributes of the histogram ID as follows:
if CHOPT=' ' only KIND(1) is filled
KIND(1) =
-1 - unknown kind of histogram
0 - ID does not exits
1 - one-dim plot
2 - two-dim plot
3 - table
4 - ntuple
8 - profile
if CHOPT='A' all the 32 status bits are returned in array KIND(32)
I1 HBOOK1 I17 HBIGBI
I2 HBOOK2 I18 HNORMA
I3 HTABLE I19 HSCALE
I4 NTUPLE I20 HMAXIM
I5 Automatic binning I21 HMINIM
I6 Variable bin size histogram I22 HINTEG
I7 HBSTAT I23 H2PAGE
I8 Profile histogram I24 H1EVLI
I9 HBARX I25 HPRSTA
I10 HBARY I26 HLOGAR
I11 HERROR I27 HBLACK
I12 HFUNC I28 HSTAR
I13 HROTAT I29 HPRCHA
I14 HPRFUN I30 HPRCON
I15 HPRLOW I31 HPRERR
I16 HPRHIS
PAW > HISTO/FILE 0 fname ! U
PAW > CALL HRENID(idold,idnew)
SUBROUTINE HF1E(ID,X,W,E)
- ID : Histogram identifier.
- X : Value of the abscissa
- W : Content is incremented by W
- E : Errors is incremented by E**2
SUBROUTINE HBOOKNC(ID,CHTITL,NVAR,BLOCK,TUPLE,TAGS)
- ID : Id of CWN. If it doesn't already exist, it is created.
- CHTITL : Name of ntuple. Not used if it already exists.
- NVAR : Number of variables per event. Maximum 200.
- BLOCK : Name of the block inside CWN. Default 'Block1'.
- TUPLE : Array of dimension nvar that will contain values at filling
time.
- TAGS : See HBOOKN.
SUBROUTINE HSTAF(CHOPT).
If CHOPT='YES' statistics are computed at filling time. All the histograms created (via HBOOK1 or HBOOK2) after a CALL HSTAF('YES'), will have the IDOPT option 'STAT' automatically activated. This is very useful when histograms are created in an indirect way like in the command NT/PLOT. The way to activate this option in PAW is: OPTION HSTA (HNST to turn it off). Example:
PAW > OPTION HSTA
PAW > NT/PLOT 10.x IDH=100
The following obsolete routines from HBOOK version 3 have been deleted:
HCORE, HDISKF, HFNEXT, HISTGO, HLCM, HLCM3, HLOK,
HSTORE, HUNLOK, HWRITE.
SUBROUTINE HPLFR3(X1I,X2I,Y1I,Y2I,Z1I,Z2I,THETA,PHI,CHOPT)
REAL X1I : Low range in X
REAL X2I : High range in X
REAL Y1I : Low range in Y
REAL Y2I : High range in Y
REAL Z1I : Low range in Z
REAL Z2I : High range in Z
REAL THETA, PHI : Viewing angles
CHARACTER CHOPT : Options
'B' Draw the back box
'F' Draw the front box
'W' Start a new window
In PAW, this routine is callable within a COMIS program.
Basic KUIP:
Application DATA vec.dat
1 2 3
4 5 6
7 8 9
vec.dat
vec/read x,y,z vec.dat
KUIP Motif interface:
Paw++*centerCommand: True
Basic KUIP:
KUIP Motif interface: