Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:12:29

0001 // @(#)root/g3d:$Id$
0002 // Author: Nenad Buncic   19/09/95
0003 
0004 /*************************************************************************
0005  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers.               *
0006  * All rights reserved.                                                  *
0007  *                                                                       *
0008  * For the licensing terms see $ROOTSYS/LICENSE.                         *
0009  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
0010  *************************************************************************/
0011 
0012 #ifndef ROOT_TTRAP
0013 #define ROOT_TTRAP
0014 
0015 
0016 ////////////////////////////////////////////////////////////////////////////
0017 //                                                                        //
0018 // TTRAP                                                                  //
0019 //                                                                        //
0020 // TRAP is a general trapezoid, i.e. one for which the faces perpendicular//
0021 // to z are trapezia and their centres are not the same x, y. It has 11   //
0022 // parameters: the half length in z, the polar angles from the centre of  //
0023 // the face at low z to that at high z, H1 the half length in y at low z, //
0024 // LB1 the half length in x at low z and y low edge, LB2 the half length  //
0025 // in x at low z and y high edge, TH1 the angle w.r.t. the y axis from the//
0026 // centre of low y edge to the centre of the high y edge, and H2, LB2,    //
0027 // LH2, TH2, the corresponding quantities at high z.                      //
0028 //                                                                        //
0029 ////////////////////////////////////////////////////////////////////////////
0030 
0031 #include "TBRIK.h"
0032 
0033 class TTRAP : public TBRIK {
0034 protected:
0035    Float_t fH1;        // half length in y at low z
0036    Float_t fBl1;       // half length in x at low z and y low edge
0037    Float_t fTl1;       // half length in x at low z and y high edge
0038    Float_t fAlpha1;    // angle w.r.t. the y axis
0039    Float_t fH2;        // half length in y at high z
0040    Float_t fBl2;       // half length in x at high z and y low edge
0041    Float_t fTl2;       // half length in x at high z and y high edge
0042    Float_t fAlpha2;    // angle w.r.t. the y axis
0043 
0044    void     SetPoints(Double_t *points) const override;
0045 
0046 public:
0047    TTRAP();
0048    TTRAP(const char *name, const char *title, const char *material, Float_t dz, Float_t theta, Float_t phi, Float_t h1,
0049          Float_t bl1, Float_t tl1, Float_t alpha1, Float_t h2, Float_t bl2, Float_t tl2,
0050          Float_t alpha2);
0051    ~TTRAP() override;
0052 
0053    virtual Float_t  GetH1() const     {return fH1;}
0054    virtual Float_t  GetBl1() const    {return fBl1;}
0055    virtual Float_t  GetTl1() const    {return fTl1;}
0056    virtual Float_t  GetAlpha1() const {return fAlpha1;}
0057    virtual Float_t  GetH2() const     {return fH2;}
0058    virtual Float_t  GetBl2() const    {return fBl2;}
0059    virtual Float_t  GetTl2() const    {return fTl2;}
0060    virtual Float_t  GetAlpha2() const {return fAlpha2;}
0061 
0062    ClassDefOverride(TTRAP,1)  //TRAP shape
0063 };
0064 
0065 #endif