Fork me on GitHub

source: git/external/Hector/H_BeamLine.h@ 0b8551f

Last change on this file since 0b8551f was 3c40083, checked in by pavel <pavel@…>, 11 years ago

switch to a more stable Hector version

  • Property mode set to 100644
File size: 1.8 KB
Line 
1#ifndef _H_BeamLine_
2#define _H_BeamLine_
3
4/*
5---- Hector the simulator ----
6 A fast simulator of particles through generic beamlines.
7 J. de Favereau, X. Rouby ~~~ hector_devel@cp3.phys.ucl.ac.be
8
9 http://www.fynu.ucl.ac.be/hector.html
10
11 Centre de Physique des Particules et de Phénoménologie (CP3)
12 Université Catholique de Louvain (UCL)
13*/
14
15/// \file H_BeamLine.h
16/// \brief Class aiming at retrieving features of the real beam optical elements.
17
18// local #includes
19#include "H_AbstractBeamLine.h"
20
21// C++ #includes
22#include <string>
23using namespace std;
24
25// Caution : mad conventions for vertically(horizontally) focusing quadrupoles
26// are opposite to Wille's. See fill() for more details.
27
28/// Reads external files and retrieves features of the real beam optical elements.
29class H_BeamLine : public H_AbstractBeamLine {
30
31 public:
32 /// Constructors and destructor
33 //@{
34 H_BeamLine():H_AbstractBeamLine() {direction=1; ips=0; };
35 H_BeamLine(const H_BeamLine& );
36 H_BeamLine(const int, const float);
37 H_BeamLine& operator=(const H_BeamLine& );
38 ~H_BeamLine() {return;};
39 //@
40 /// Finds the IP position (s) from the MAD table. Should be "IP5" or "IP1".
41 //@{
42 void findIP(const string);
43 void findIP(const string, const string);
44 //@}
45 /// Reader for the external MAD table
46 //@{
47 void fill(const string);
48 void fill(const string, const int, const string );
49 //@}
50 /// Returns the IP position (s)
51 double getIP() {return ips;};
52 /// Returns positions and angles of beam at IP
53 double* getIPProperties();
54
55 private:
56 int direction; // to or from the IP.
57 double ips; // s-position of the IP [m]
58 double ipx; // x-position of the IP [µm]
59 double ipy; // y-position of the IP [µm]
60 double iptx; // x-angle of momentum at IP [µrad]
61 double ipty; // y-angle of momentum at IP [µrad]
62};
63
64#endif
65
Note: See TracBrowser for help on using the repository browser.