source: trunk/MagicSoft/Mars/mgeom/MGeomMirror.cc@ 1685

Last change on this file since 1685 was 1685, checked in by blanch, 22 years ago
*** empty log message ***
File size: 4.3 KB
Line 
1/* ======================================================================== *\
2!
3! *
4! * This file is part of MARS, the MAGIC Analysis and Reconstruction
5! * Software. It is distributed to you in the hope that it can be a useful
6! * and timesaving tool in analysing Data of imaging Cerenkov telescopes.
7! * It is distributed WITHOUT ANY WARRANTY.
8! *
9! * Permission to use, copy, modify and distribute this software and its
10! * documentation for any purpose is hereby granted without fee,
11! * provided that the above copyright notice appear in all copies and
12! * that both that copyright notice and this permission notice appear
13! * in supporting documentation. It is provided "as is" without express
14! * or implied warranty.
15! *
16!
17!
18! Author(s): Oscar Blanch 11/2002 <mailto:blanch@ifae.es>
19!
20! Copyright: MAGIC Software Development, 2000-2002
21!
22!
23\* ======================================================================== */
24
25/////////////////////////////////////////////////////////////////////////////
26//
27// MGeomMirror
28//
29// This is the base class of the Mirror geometry.
30//
31/////////////////////////////////////////////////////////////////////////////
32
33#include "MGeomMirror.h"
34
35ClassImp(MGeomMirror);
36
37// --------------------------------------------------------------------------
38//
39// Initializes a Mirror geometry with 0 values, except for fMirrorID.
40//
41MGeomMirror::MGeomMirror(Int_t mir, const char *name, const char *title)
42{
43 fName = name ? name : "MGeomMirror";
44 fTitle = title ? title : "Storage container for a mirror geometry";
45
46 fMirrorId=mir; // the Mirror Id
47
48 fFocalDist=0.; // focal distance of that mirror [cm]
49 fSX=0.; // curvilinear coordinate of mirror's center in X[cm]
50 fSY=0.; // curvilinear coordinate of mirror's center in X[cm]
51 fX=0.; // x coordinate of the center of the mirror [cm]
52 fY=0.; // y coordinate of the center of the mirror [cm]
53 fZ=0.; // z coordinate of the center of the mirror [cm]
54 fThetaN=0.; // polar theta angle of the direction
55 // where the mirror points to
56 fPhiN=0.; // polar phi angle of the direction
57 // where the mirror points to
58 fXN=0.; // xn coordinate of the normal vector
59 // in the center
60 fYN=0.; // yn coordinate of the normal vector
61 // in the center
62 fZN=0.; // zn coordinate of the normal vector
63 // in the center
64 // Note: fXN^2*fYN^2*fZN^2 = 1
65 fDeviationX=0.; // deviation in x [cm]
66 fDeviationY=0.; // deviation in y [cm]
67 // of the spot of a single mirror on the camera plane
68
69}
70
71// --------------------------------------------------------------------------
72//
73// DESCRIPTION MISSING: Please contact Oscar
74//
75void MGeomMirror::SetMirrorContent(Int_t mir, Float_t focal, Float_t curv_x,
76 Float_t curv_y, Float_t lin_x, Float_t lin_y,
77 Float_t lin_z, Float_t theta, Float_t phi,
78 Float_t x_n, Float_t y_n, Float_t z_n){
79 fMirrorId=mir; // the Mirror Id
80
81 fFocalDist=focal; // focal distance of that mirror [cm]
82 fSX=curv_x; // curvilinear coordinate of mirror's center in X[cm]
83 fSY=curv_y; // curvilinear coordinate of mirror's center in X[cm]
84 fX=lin_x; // x coordinate of the center of the mirror [cm]
85 fY=lin_y; // y coordinate of the center of the mirror [cm]
86 fZ=lin_z; // z coordinate of the center of the mirror [cm]
87 fThetaN=theta; // polar theta angle of the direction
88 // where the mirror points to
89 fPhiN=phi; // polar phi angle of the direction
90 // where the mirror points to
91 fXN=x_n; // xn coordinate of the normal vector
92 // in the center
93 fYN=y_n; // yn coordinate of the normal vector
94 // in the center
95 fZN=z_n; // zn coordinate of the normal vector
96 // in the center
97 // Note: fXN^2*fYN^2*fZN^2 = 1
98}
99
100void MGeomMirror::SetMirrorDeviations(Float_t dev_x, Float_t dev_y){
101 fDeviationX=dev_x; // deviation in x [cm]
102 fDeviationY=dev_x; // deviation in y [cm]
103 // of the spot of a single mirror on the camera plane
104}
105
106
107
108
109
110
111
112
113
Note: See TracBrowser for help on using the repository browser.