Ignore:
Timestamp:
11/19/99 08:40:44 (25 years ago)
Author:
harald
Message:
Now it is possible to compile the camera programm under osf1.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Simulation/Detector/Camera/camera.cxx

    r308 r327  
    2121//
    2222// $RCSfile: camera.cxx,v $
    23 // $Revision: 1.1.1.1 $
     23// $Revision: 1.2 $
    2424// $Author: harald $
    25 // $Date: 1999-11-05 11:59:31 $
     25// $Date: 1999-11-19 08:40:42 $
    2626//
    2727////////////////////////////////////////////////////////////////////////
     
    517517  MTrigger  Trigger ;         //@< A instance of the Class MTrigger
    518518
    519 #endif __DETAIL_TRIGGER__
     519#endif // __DETAIL_TRIGGER__
    520520
    521521  //!@' @#### Definition of variables for |getopt()|.
     
    728728  unsigned short ulli = 0 ;
    729729
    730 #endif __ROOT__
     730#endif // __ROOT__
    731731
    732732  // for safety and for dimensioning image_data: count the elements in the
     
    857857  fnslicesum = new float [ (2 * SLICES) ] ;
    858858 
    859   float slices   [ct_NPixels][ (2 * SLICES) ] ;
    860   float slices2  [ct_NPixels][ SLICES ] ;
     859  float slices   [CAMERA_PIXELS][ (2 * SLICES) ] ;
     860  float slices2  [CAMERA_PIXELS][ SLICES ] ;
    861861
    862862  float trans    [ SLICES ] ;
    863 #endif __ROOT__
     863#endif // __ROOT__
    864864
    865865 
     
    10341034            slices [i][ii] = 0 ;
    10351035          }
    1036 #endif __ROOT__
     1036#endif // __ROOT__
    10371037        }
    10381038
     
    10461046     
    10471047        Trigger.Reset() ;
    1048 #endif __DETAIL_TRIGGER__
     1048#endif // __DETAIL_TRIGGER__
    10491049       
    10501050        //- - - - - - - - - - - - - - - - - - - - - - - - -
     
    13001300          fnslicesum[t_chan]  += 1.0 ;
    13011301          slices[nPMT][t_chan] += 1.0 ;
    1302 #endif __ROOT__           
     1302#endif // __ROOT__       
    13031303
    13041304#ifdef __DETAIL_TRIGGER__
     
    13091309
    13101310          Trigger.Fill( nPMT, ( t - t_ini  ) ) ;
    1311 #endif __DETAIL_TRIGGER__
     1311#endif // __DETAIL_TRIGGER__
    13121312         
    13131313          // read next CPhoton
     
    14081408      //   Trigger.Print() ;
    14091409      cout << Trigger.Diskriminate() << endl << endl ;
    1410 #endif __DETAIL_TRIGGER__
     1410#endif // __DETAIL_TRIGGER__
    14111411
    14121412#ifdef __ROOT__
     
    14811481      McEvt->Clear() ;
    14821482
    1483 #endif __ROOT__
     1483#endif // __ROOT__
    14841484       
    14851485        //++++++++++++++++++++++++++++++++++++++++++++++++++
     
    21322132      outfile.Close() ;
    21332133
    2134 #endif __ROOT__
     2134#endif // __ROOT__
    21352135             
    21362136  // close input file
     
    21592159
    21602160  Trigger.PrintStat() ;
    2161 #endif __DETAIL_TRIGGER__
     2161#endif // __DETAIL_TRIGGER__
    21622162
    21632163  // program finished
     
    31113111//
    31123112// $Log: not supported by cvs2svn $
     3113// Revision 1.1.1.1  1999/11/05 11:59:31  harald
     3114// This the starting point for CVS controlled further developments of the
     3115// camera program. The program was originally written by Jose Carlos.
     3116// But here you can find a "rootified" version to the program. This means
     3117// that there is no hbook stuff in it now. Also the output of the
     3118// program changed to the MagicRawDataFormat.
     3119//
     3120// The "rootification" was done by Dirk Petry and Harald Kornmayer.
     3121//
     3122// In the following you can see the README file of that version:
     3123//
     3124// ==================================================
     3125//
     3126// Fri Oct 22  1999   D.P.
     3127//
     3128// The MAGIC Monte Carlo System
     3129//
     3130// Camera Simulation Programme
     3131// ---------------------------
     3132//
     3133// 1) Description
     3134//
     3135// This version is the result of the fusion of H.K.'s
     3136// root_camera which is described below (section 2)
     3137// and another version by D.P. which had a few additional
     3138// useful features.
     3139//
     3140// The version compiles under Linux with ROOT 2.22 installed
     3141// (variable ROOTSYS has to be set).
     3142//
     3143// Compile as before simply using "make" in the root_camera
     3144// directory.
     3145//
     3146// All features of H.K.'s root_camera were retained.
     3147//
     3148// Additional features of this version are:
     3149//
     3150//   a) HBOOK is no longer used and all references are removed.
     3151//
     3152//   b) Instead of HBOOK, the user is given now the possibility of
     3153//      having Diagnostic data in ROOT format as a complement
     3154//      to the ROOT Raw data.
     3155//
     3156//      This data is written to the file which is determined by
     3157//      the new input parameter "diag_file" in the camera parameter
     3158//      file.
     3159//
     3160//      All source code file belonging to this part have filenames
     3161//      starting with "MDiag".
     3162//
     3163//      The user can read the output file using the following commands
     3164//      in an interactive ROOT session:
     3165//
     3166//              root [0] .L MDiag.so
     3167//      root [1] new TFile("diag.root");
     3168//      root [2] new TTreeViewer("T");
     3169//     
     3170//      This brings up a viewer from which all variables of the
     3171//      TTree can be accessed and histogrammed. This example
     3172//      assumes that you have named the file "diag.root", that
     3173//      you are using ROOT version 2.22 or later and that you have
     3174//      the shared object library "MDiag.so" which is produced
     3175//      by the Makefile along with the executable "camera".
     3176//       
     3177//  !   The contents of the so-called diag file is not yet fixed.
     3178//  !   At the moment it is what J.C.G. used to put into the HBOOK
     3179//  !   ntuple. In future versions the moments calculation can be
     3180//  !   removed and the parameter list be modified correspondingly.
     3181//
     3182//   c) Now concatenated reflector files can be read. This is useful
     3183//      if you have run the reflector with different parameters but
     3184//      you want to continue the analysis with all reflector data
     3185//      going into ONE ROOT outputfile.
     3186//
     3187//      The previous camera version contained a bug which made reading
     3188//      of two or more concatenated reflector files impossible.
     3189//
     3190//   d) The reflector output format was changed. It is now version
     3191//      0.4 .
     3192//      The change solely consists in a shortening of the flag
     3193//      definition in the file
     3194//
     3195//            include-MC/MCCphoton.hxx 
     3196//
     3197//  !   IF YOU WANT TO READ REFLECTOR FORMAT 0.3, you can easily
     3198//  !   do so by recompiling camera with the previous version of
     3199//  !   include-MC/MCCphoton.hxx.
     3200//
     3201//      The change was necessary for saving space and better
     3202//      debugging. From now on, this format can be frozen.
     3203//
     3204//  !   For producing reflector output in the new format, you
     3205//  !   of course have to recompile your reflector with the
     3206//  !   new include-MC/MCCphoton.hxx .
     3207//
     3208//   e) A first version of the pixelization with the larger
     3209//      outer pixels is implemented. THIS IS NOT YET FULLY
     3210//      TESTED, but first rough tests show that it works
     3211//      at least to a good approximation.
     3212//
     3213//      The present version implements the camera outline
     3214//      with 18 "gap-pixels" and 595 pixels in total as
     3215//      shown in
     3216//
     3217//         http://sarastro.ifae.es/internal/home/hardware/camera/numbering.ps
     3218//
     3219//      This change involved
     3220//
     3221//      (i) The file pixels.dat is no longer needed. Instead
     3222//           the coordinates are generated by the program itself
     3223//           (takes maybe 1 second). In the file
     3224//
     3225//              pixel-coords.txt
     3226//
     3227//        in the same directory as this README, you find a list
     3228//           of the coordinates generated by this new routine. It
     3229//           has the format
     3230//
     3231//               number   i   j   x  y  size-factor
     3232//
     3233//           where i and j are J.C.G.'s so called biaxis hexagonal
     3234//           coordinates (for internal use) and x and y are the
     3235//           coordinates of the pixel centers in the standard camera
     3236//           coordinate system in units of centimeters. The value
     3237//           of "size-factor" determines the linear size of the pixel
     3238//           relative to the central pixels.
     3239//
     3240//         (ii) The magic.def file has two additional parameters
     3241//           which give the number of central pixels and the
     3242//           number of gap pixels
     3243//
     3244//         (iii) In camera.h and camera.cxx several changes were
     3245//           necessary, among them the introduction of several
     3246//           new functions
     3247//
     3248//      The newly suggested outline with asymmetric Winston cones
     3249//      will be implemented in a later version.
     3250//
     3251//   f) phe files can no longer be read since this contradicts
     3252//      our philosophy that the analysis should be done with other
     3253//      programs like e.g. EVITA and not with "camera" itself.
     3254//      This possibility was removed.
     3255//
     3256//   g) ROOT is no longer invoked with an interactive interface.
     3257//      In this way, camera can better be run as a batch program and
     3258//      it uses less memory.
     3259//
     3260//   h) small changes concerning the variable "t_chan" were necessary in
     3261//      order to avoid segmentation faults: The variable is used as an
     3262//      index and it went sometimes outside the limits when camera
     3263//      was reading proton data. This is because the reflector files
     3264//      don't contain the photons in a chronological order and also
     3265//      the timespread can be considerably longer that the foreseen
     3266//      digitisation timespan. Please see the source code of camera.cxx
     3267//      round about line 1090.
     3268//
     3269//   j) several unused variables were removed, a few warning messages
     3270//      occur when you compile camera.cxx but these can be ignored at
     3271//      the moment.
     3272//
     3273// In general the program is of course not finished. It still needs
     3274// debugging, proper trigger simulation, simulation of the asymmetric
     3275// version of the outer pixels, proper NSB simulation, adaption of
     3276// the diag "ntuple" contents to our need and others small improvements.
     3277//
     3278// In the directory rfl-files there is now a file in reflector format 0.4
     3279// containing a single event produced by the starfiled adder. It has
     3280// a duration of 30 ns and represents the region around the Crab Nebula.
     3281// Using the enclosed input parameter file, camera should process this
     3282// file without problems.
     3283//
     3284// 2) The README for the previous version of root_camera
     3285//
     3286// README for a preliminary version of the
     3287// root_camera program.
     3288//
     3289// root_camera is based on the program "camera"of Jose Carlos
     3290// Gonzalez. It was changed in the way that only the pixelisation
     3291// and the distibution of the phe to the FADCs works in a
     3292// first version.
     3293//
     3294// Using the #undef command most possibilities of the orignal
     3295// program are switched of.
     3296//
     3297// The new parts are signed by
     3298//
     3299// - ROOT or __ROOT__
     3300//   nearly all  important codelines for ROOT output are enclosed
     3301//   in structures like
     3302//   #ifdef __ROOT__
     3303//   
     3304//     code
     3305//
     3306//   #endif __ROOT__
     3307//
     3308//   In same case the new lines are signed by a comment with the word
     3309//   ROOT in it.
     3310//
     3311//   For timing of the pulse some variable names are changed.
     3312//   (t0, t1, t  -->  t_ini, t_fin, t_1st, t_chan,...)
     3313//   Look also for this changes.
     3314//
     3315//   For the new root-file is also a change in readparm-files
     3316//
     3317//
     3318// - __DETAIL_TRIGGER__
     3319//
     3320//   This is for the implementation of the current work on trigger
     3321//   studies. Because the class MTrigger is not well documented it
     3322//   isn´t a part of this tar file. Only a dummy File exists.
     3323//
     3324//
     3325//
     3326// With all files in the archive, the root_camera program should run.
     3327//
     3328// A reflector file is in the directory rfl-files
     3329//
     3330// ==================================================
     3331//
     3332// From now on, use CVS for development!!!!
     3333//
     3334//
     3335//
    31133336// Revision 1.3  1999/10/22 15:01:28  petry
    31143337// version sent to H.K. and N.M. on Fri Oct 22 1999
Note: See TracChangeset for help on using the changeset viewer.