Changeset 418


Ignore:
Timestamp:
07/12/00 11:19:10 (24 years ago)
Author:
harald
Message:
Changed in a way that SIMONE is able to read CER files and print
the content of the shower on screen.
Location:
trunk/MagicSoft/Simulation/Corsika/Simone
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Simulation/Corsika/Simone/Makefile

    r415 r418  
    1919#
    2020# $RCSfile: Makefile,v $
    21 # $Revision: 1.2 $
     21# $Revision: 1.3 $
    2222# $Author: harald $
    23 # $Date: 2000-07-06 10:24:00 $
     23# $Date: 2000-07-12 10:19:10 $
    2424#
    2525##################################################################
     
    168168../../Detector/include-CORSIKA/COREventHeader.o: ../../Detector/include-CORSIKA/COREventHeader.hxx
    169169../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/stdlib.h
    170 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/features.h
    171 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/sys/cdefs.h
    172 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/gnu/stubs.h
    173 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/stddef.h
     170../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/standards.h
     171../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/getopt.h
    174172../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/sys/types.h
    175 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/bits/types.h
    176 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/time.h
    177 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/endian.h
    178 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/bits/endian.h
     173../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/mach/machine/vm_types.h
    179174../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/sys/select.h
    180 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/bits/select.h
    181 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/bits/sigset.h
    182 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/sys/sysmacros.h
    183 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/alloca.h
    184175../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/math.h
    185 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/bits/huge_val.h
    186 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/bits/mathdef.h
    187 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/include/bits/mathcalls.h
    188 ../../Detector/include-CORSIKA/COREventHeader.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/float.h
    189176../../Detector/include-CORSIKA/CORParticle.o: ../../Detector/include-CORSIKA/CORParticle.hxx
    190177../../Detector/include-CORSIKA/CORParticle.o: /usr/include/stdlib.h
    191 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/features.h
    192 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/sys/cdefs.h
    193 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/gnu/stubs.h
    194 ../../Detector/include-CORSIKA/CORParticle.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/stddef.h
     178../../Detector/include-CORSIKA/CORParticle.o: /usr/include/standards.h
     179../../Detector/include-CORSIKA/CORParticle.o: /usr/include/getopt.h
    195180../../Detector/include-CORSIKA/CORParticle.o: /usr/include/sys/types.h
    196 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/bits/types.h
    197 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/time.h
    198 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/endian.h
    199 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/bits/endian.h
     181../../Detector/include-CORSIKA/CORParticle.o: /usr/include/mach/machine/vm_types.h
    200182../../Detector/include-CORSIKA/CORParticle.o: /usr/include/sys/select.h
    201 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/bits/select.h
    202 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/bits/sigset.h
    203 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/sys/sysmacros.h
    204 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/alloca.h
    205183../../Detector/include-CORSIKA/CORParticle.o: /usr/include/math.h
    206 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/bits/huge_val.h
    207 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/bits/mathdef.h
    208 ../../Detector/include-CORSIKA/CORParticle.o: /usr/include/bits/mathcalls.h
    209 ../../Detector/include-CORSIKA/CORParticle.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/float.h
    210184../../Detector/include-CORSIKA/CORStatfile.o: ../../Detector/include-CORSIKA/CORStatfile.hxx
    211185../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/stdlib.h
    212 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/features.h
    213 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/sys/cdefs.h
    214 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/gnu/stubs.h
    215 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/stddef.h
     186../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/standards.h
     187../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/getopt.h
    216188../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/sys/types.h
    217 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/bits/types.h
    218 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/time.h
    219 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/endian.h
    220 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/bits/endian.h
     189../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/mach/machine/vm_types.h
    221190../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/sys/select.h
    222 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/bits/select.h
    223 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/bits/sigset.h
    224 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/sys/sysmacros.h
    225 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/alloca.h
    226191../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/math.h
    227 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/bits/huge_val.h
    228 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/bits/mathdef.h
    229 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/include/bits/mathcalls.h
    230 ../../Detector/include-CORSIKA/CORStatfile.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/float.h
    231 MSimone.o: MSimone.hxx /usr/include/stdlib.h /usr/include/features.h
    232 MSimone.o: /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h
    233 MSimone.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/stddef.h
    234 MSimone.o: /usr/include/sys/types.h /usr/include/bits/types.h
    235 MSimone.o: /usr/include/time.h /usr/include/endian.h
    236 MSimone.o: /usr/include/bits/endian.h /usr/include/sys/select.h
    237 MSimone.o: /usr/include/bits/select.h /usr/include/bits/sigset.h
    238 MSimone.o: /usr/include/sys/sysmacros.h /usr/include/alloca.h
    239 MSimone.o: /usr/include/stdio.h
    240 MSimone.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/stdarg.h
    241 MSimone.o: /usr/include/libio.h /usr/include/_G_config.h
    242 MSimone.o: /usr/include/bits/stdio_lim.h /usr/include/string.h
    243 MSimone.o: /usr/include/unistd.h /usr/include/bits/posix_opt.h
    244 MSimone.o: /usr/include/bits/confname.h /usr/include/getopt.h
    245 MSimone.o: /usr/include/fcntl.h /usr/include/bits/fcntl.h
     192MSimone.o: MSimone.hxx /usr/include/stdlib.h /usr/include/standards.h
     193MSimone.o: /usr/include/getopt.h /usr/include/sys/types.h
     194MSimone.o: /usr/include/mach/machine/vm_types.h /usr/include/sys/select.h
     195MSimone.o: /usr/include/stdio.h /usr/include/sys/seek.h
     196MSimone.o: /usr/include/va_list.h /usr/include/sys/limits.h
     197MSimone.o: /usr/include/sys/machine/machlimits.h /usr/include/sys/syslimits.h
     198MSimone.o: /usr/include/sys/machine/machtime.h /usr/include/sys/rt_limits.h
     199MSimone.o: /usr/include/string.h /usr/include/strings.h /usr/include/unistd.h
     200MSimone.o: /usr/include/sys/access.h /usr/include/fcntl.h
     201MSimone.o: /usr/include/sys/fcntl.h /usr/include/sys/mode.h
    246202MSimone.o: ../../Detector/include-CORSIKA/COREventHeader.hxx
    247 MSimone.o: /usr/include/math.h /usr/include/bits/huge_val.h
    248 MSimone.o: /usr/include/bits/mathdef.h /usr/include/bits/mathcalls.h
    249 MSimone.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/float.h
    250 simone.o: /usr/include/stdlib.h /usr/include/features.h
    251 simone.o: /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h
    252 simone.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/stddef.h
    253 simone.o: /usr/include/sys/types.h /usr/include/bits/types.h
    254 simone.o: /usr/include/time.h /usr/include/endian.h
    255 simone.o: /usr/include/bits/endian.h /usr/include/sys/select.h
    256 simone.o: /usr/include/bits/select.h /usr/include/bits/sigset.h
    257 simone.o: /usr/include/sys/sysmacros.h /usr/include/alloca.h
     203MSimone.o: /usr/include/math.h
     204simone.o: /usr/include/stdlib.h /usr/include/standards.h
     205simone.o: /usr/include/getopt.h /usr/include/sys/types.h
     206simone.o: /usr/include/mach/machine/vm_types.h /usr/include/sys/select.h
    258207simone.o: ../../Detector/include-CORSIKA/COREventHeader.hxx
    259 simone.o: /usr/include/math.h /usr/include/bits/huge_val.h
    260 simone.o: /usr/include/bits/mathdef.h /usr/include/bits/mathcalls.h
    261 simone.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/float.h
    262 simone.o: ../../Detector/include-CORSIKA/CORParticle.hxx
     208simone.o: /usr/include/math.h ../../Detector/include-CORSIKA/CORParticle.hxx
    263209simone.o: ../../Detector/include-CORSIKA/CORStatfile.hxx MSimone.hxx
    264 simone.o: /usr/include/stdio.h
    265 simone.o: /usr/lib/gcc-lib/i486-linux/2.7.2.3/include/stdarg.h
    266 simone.o: /usr/include/libio.h /usr/include/_G_config.h
    267 simone.o: /usr/include/bits/stdio_lim.h /usr/include/string.h
    268 simone.o: /usr/include/unistd.h /usr/include/bits/posix_opt.h
    269 simone.o: /usr/include/bits/confname.h /usr/include/getopt.h
    270 simone.o: /usr/include/fcntl.h /usr/include/bits/fcntl.h
     210simone.o: /usr/include/stdio.h /usr/include/sys/seek.h /usr/include/va_list.h
     211simone.o: /usr/include/sys/limits.h /usr/include/sys/machine/machlimits.h
     212simone.o: /usr/include/sys/syslimits.h /usr/include/sys/machine/machtime.h
     213simone.o: /usr/include/sys/rt_limits.h /usr/include/string.h
     214simone.o: /usr/include/strings.h /usr/include/unistd.h
     215simone.o: /usr/include/sys/access.h /usr/include/fcntl.h
     216simone.o: /usr/include/sys/fcntl.h /usr/include/sys/mode.h
  • trunk/MagicSoft/Simulation/Corsika/Simone/simone.cxx

    r415 r418  
    66//
    77#include <stdlib.h>
    8 #include "TROOT.h"
    9 #include "TApplication.h"
    10 
    11 #include "TCanvas.h"
    12 #include "TView.h"
    13 
    14 #include "TSPHE.h"
    15 #include "TBRIK.h"
    16 
    17 #include "TNode.h"
    18 
    19 #include "TFile.h"
    20 #include "TNtuple.h"
    218
    229#include "COREventHeader.hxx"
     
    2411#include "CORStatfile.hxx"
    2512
    26 #include "MSimone.hxx"
    27 
    2813int main(int argc, char **argv)
    2914{
    30   // initialise ROOT
     15  char  path[100] = "" ;
    3116
    32   TROOT simple("simple", "SIMONE - statistic of MonteCarlo");
    33 
    34   TApplication theApp("App", &argc, argv);
    35  
    36   char  path[100] = "/dat1/Mmcs/Gamm/" ;
    37   //    char  path[100] = "/hd02/Maggi/Data/prot_15/" ;
    38   //    char  path[100] = "/data/mmcs/" ;
    3917  char  cername[120] ;
    4018  char  datname[120] ;
     
    4523  CORParticle    Photon ;
    4624 
    47   MSimone    Infos ;
    48    
    4925  Int_t iPhotonInShower ;
    5026 
    5127  Float_t lambda ;
    52  
     28
     29  cout << " ============================" << endl ;
     30  cout << " SIMONE" << endl ;
     31  cout << "                             " << endl ;
    5332  cout << " SImulated MONte carlo Events" << endl ;
     33  cout << "                             " << endl ;
    5434
    55   //
    56   //    now create a root-file for the ntuple output
    57   //
    58  
    59   TFile *outfile = new TFile("simone.root","RECREATE");
    60  
    61   TNtuple *Ntup = new TNtuple("simone",
    62                               "Simone info of mmcs",
    63                               "fPartId:fEnergy:fTheta:fPhi:fCoreX:fCoreY:fCoreD:fNumCerPhot");
    64  
    65  
     35
     36  if ( argc <= 1 ) {
     37    cout << endl ;
     38    cout << " INFO: You have to start the program with "<<endl <<endl ;
     39    cout << "        -> simone DIRECTORY_WITH_CER_FILES" <<endl <<endl ;
     40    cout << "        no SLASH at the end of the directory name"<<endl ;
     41    cout << "        (example: -> simone /hd123/Protons   "<<endl ;
     42    exit (-1) ;
     43  }
     44
     45  sprintf (path , "%s", argv[1] ) ;
     46   
    6647  for (int i_cer = 1; i_cer <= 100; i_cer++ ) {
    67     //
    68     //   info of progress
    69     //
    70     if (!( i_cer %10) )
    71       {
    72         cout << i_cer << endl ;
    73       }
    74 
    7548    //
    7649    //   create the file names
     
    9871   
    9972    Event.read( cerfile );
    100     Infos.Transfer ( &Event ) ;
    101    
     73 
     74    Event.Print() ;
     75
    10276    //
    10377    //   loop over the particles (cerenkov photons) in
     
    126100      iPhotonInShower++ ;
    127101     
    128       //Photon.print() ;
     102      Photon.print() ;
    129103    }
    130104   
    131     Infos.SetNumCerPhot( iPhotonInShower ) ;
    132    
    133105    //
    134     //   fill the ntuple
     106    //   close the file
    135107    //
    136    
    137     Infos.NtupFill ( Ntup ) ;
    138    
    139108   
    140109    cerfile.close();
     
    144113  }
    145114 
    146  
    147   //
    148   //   write all to file
    149   //
    150   outfile->Write() ;
    151 
    152  
    153   //
    154   //
    155   //
    156 
    157   Ntup->Draw("fEnergy") ;
    158 
    159 
    160   theApp.Run();
    161   return 0;                           
    162    
    163  
    164115}
    165116
Note: See TracChangeset for help on using the changeset viewer.