OPAL (Object Oriented Parallel Accelerator Library)  2.2.0
OPAL
NormalForm.h
Go to the documentation of this file.
1 #ifndef MAD_NormalForm_HH
2 #define MAD_NormalForm_HH
3 // ------------------------------------------------------------------------
4 // $RCSfile: NormalForm.h,v $
5 // ------------------------------------------------------------------------
6 // $Revision: 1.1.1.1 $
7 // ------------------------------------------------------------------------
8 // Copyright: see Copyright.readme
9 // ------------------------------------------------------------------------
10 //
11 // Class: NormalForm
12 //
13 // ------------------------------------------------------------------------
14 // Class category: Algebra
15 // ------------------------------------------------------------------------
16 //
17 // $Date: 2000/03/27 09:32:32 $
18 // $Author: fci $
19 //
20 // ------------------------------------------------------------------------
21 
22 #include "Algebra/Matrix.h"
23 #include "Algebra/Vector.h"
24 #include "Algebra/VpsInvMap.h"
25 #include <complex>
26 
27 using std::complex;
28 
29 
30 // Class NormalForm
31 // ------------------------------------------------------------------------
33 // Find normal form of a truncated Taylor series map. Compute from
34 // representation of a map which can be a nil-potent, static or dynamic
35 // symplectic map. Implementation of an algorithm described in
36 // {CENTER}
37 // M. Berz, E. Forest and J. Irwin,{BR}
38 // Particle Accelerators, 1989, Vol. 24, pp. 91-107.
39 // {/CENTER}
40 
41 class NormalForm {
42 
43 public:
44 
46  // Construct normal-form for [b]map[/b].
47  NormalForm(const VpsInvMap<double> &map);
48 
49  NormalForm();
50  NormalForm(const NormalForm &);
51  ~NormalForm();
52 
54  int degreesOfFreedom() const;
55 
57  // Return normal-form map as a Lie transform.
58  const Tps<double> &normalForm() const;
59 
61  // Return the normalising map as a Lie transform.
62  const Tps<double> &normalisingMap() const;
63 
65  // Return the eigenvalues of the linear part as a complex vector.
66  const Vector<complex<double> > &eigenValues() const;
67 
69  // Return the eigenvectors of the linear part in packed form.
70  const Matrix<double> &eigenVectors() const;
71 
73  // Return the anharmonicities as a symmetric matrix.
75 
77  // Return the invariant polynomial for the mode [b]i[/b].
78  Tps<double> invariant(int i) const;
79 
80 protected:
81 
82  // Order the modes of the map and associate them to the planes.
83  void orderModes(Vector<complex<double> >, Matrix<double>);
84 
85 private:
86 
87  // Not implemented.
88  void operator=(const NormalForm &);
89 
90  // Representation of the normal form analysis results.
91  // ----------------------------------------------------------------------
92  // The dimensions of the problem.
93  int dimension;
94 
95  // Number of degrees of freedom.
96  int freedom;
97 
98  // The factorised normalising map.
100 
101  // The factorised normal form map/
103 
104  // The vector of eigenvalues.
106 
107  // The matrix of eigenvectors.
109 };
110 
111 #endif // MAD_NormalForm_HH
const Tps< double > & normalForm() const
Get normal-form.
Definition: NormalForm.cpp:297
Tps< double > N_Lie
Definition: NormalForm.h:102
MMatrix< m_complex > complex(MMatrix< double > real)
Definition: MMatrix.cpp:407
int degreesOfFreedom() const
Get number of stable degrees of freedom.
Definition: NormalForm.cpp:239
const Matrix< double > & eigenVectors() const
Get eigenvectors.
Definition: NormalForm.cpp:312
int dimension
Definition: NormalForm.h:93
Matrix< double > anharmonicity() const
Get anharmonicities.
Definition: NormalForm.cpp:244
void orderModes(Vector< complex< double > >, Matrix< double >)
Definition: NormalForm.cpp:317
Tps< double > A_Lie
Definition: NormalForm.h:99
const Tps< double > & normalisingMap() const
Get normalising map.
Definition: NormalForm.cpp:302
Vector< complex< double > > lambda
Definition: NormalForm.h:105
int freedom
Definition: NormalForm.h:96
void operator=(const NormalForm &)
Matrix< double > V
Definition: NormalForm.h:108
Vector.
Resonance-free normal form.
Definition: NormalForm.h:41
Tps< double > invariant(int i) const
Get invariant polynomial.
Definition: NormalForm.cpp:278
const Vector< complex< double > > & eigenValues() const
Get eigenvalues.
Definition: NormalForm.cpp:307