OPAL (Object Oriented Parallel Accelerator Library) 2022.1
OPAL
OpalBend.h
Go to the documentation of this file.
1#ifndef OPAL_OpalBend_HH
2#define OPAL_OpalBend_HH
3
4// ------------------------------------------------------------------------
5// $RCSfile: OpalBend.h,v $
6// ------------------------------------------------------------------------
7// $Revision: 1.1.1.1.4.1 $
8// ------------------------------------------------------------------------
9// Copyright: see Copyright.readme
10// ------------------------------------------------------------------------
11//
12// Class: OpalBend
13//
14// ------------------------------------------------------------------------
15//
16// $Date: 2004/11/12 20:10:11 $
17// $Author: adelmann $
18//
19// ------------------------------------------------------------------------
20
22
23
24// Class OpalBend
25// ------------------------------------------------------------------------
27// This class factors out the special behaviour for the DOOM interface
28// and the printing in OPAL format, as well as the bend attributes.
29
30class OpalBend: public OpalElement {
31
32public:
33
35 enum {
36 ANGLE = COMMON, // The bend angle.
37 K0, K0S, // The multipole coefficients; must be in this order.
41 E1, E2, // The edge angles.
42 H1, H2, // The pole face curvatures.
43 HGAP, FINT, // The fringing field parameters.
44 SLICES, STEPSIZE, // Parameters used to determine slicing.
45 FMAPFN, // File name containing on-axis field.
46 GAP, // Full gap of magnet.
47 HAPERT, // Horizontal aperture of magnet.
48 ROTATION, // Magnet rotation about z axis.
49 DESIGNENERGY, // the design energy of the particles
50 GREATERTHANPI, // Boolean flag set to true if bend angle is greater
51 // than 180 degrees.
52 NSLICES, // The number of slices / steps per element for map tracking
53 SIZE // Total number of attributes.
54 };
55
57 OpalBend(const char *name, const char *help);
58
59 virtual ~OpalBend();
60
62 // Handle printing in OPAL-8 format.
63 virtual void print(std::ostream &) const;
64
65protected:
66
68 OpalBend(const std::string &name, OpalBend *parent);
69
70private:
71
72 // Not implemented.
74 void operator=(const OpalBend &);
75};
76
77#endif // OPAL_OpalBend_HH
const std::string name
Base class for all bending magnets.
Definition: OpalBend.h:30
@ GREATERTHANPI
Definition: OpalBend.h:50
@ SLICES
Definition: OpalBend.h:44
@ NSLICES
Definition: OpalBend.h:52
@ ROTATION
Definition: OpalBend.h:48
@ STEPSIZE
Definition: OpalBend.h:44
@ HAPERT
Definition: OpalBend.h:47
@ FMAPFN
Definition: OpalBend.h:45
@ HGAP
Definition: OpalBend.h:43
@ SIZE
Definition: OpalBend.h:53
@ DESIGNENERGY
Definition: OpalBend.h:49
@ ANGLE
Definition: OpalBend.h:36
@ FINT
Definition: OpalBend.h:43
OpalBend(const OpalBend &)
OpalBend(const char *name, const char *help)
Exemplar constructor.
Definition: OpalBend.cpp:30
virtual ~OpalBend()
Definition: OpalBend.cpp:90
void operator=(const OpalBend &)
virtual void print(std::ostream &) const
Print the bend magnet.
Definition: OpalBend.cpp:94