Fork me on GitHub

source: svn/trunk/Utilities/Hector/src/H_VerticalKicker.cc@ 1080

Last change on this file since 1080 was 281, checked in by Xavier Rouby, 16 years ago

new Hector version

File size: 1.8 KB
Line 
1 /* * * * * * * * * * * * * * * * * * * * * * * * * * * *
2 * *
3* --<--<-- A fast simulator --<--<-- *
4* / --<--<-- of particle --<--<-- *
5* ----HECTOR----< *
6* \ -->-->-- transport through -->-->-- *
7* -->-->-- generic beamlines -->-->-- *
8* *
9* JINST 2:P09005 (2007) *
10* X Rouby, J de Favereau, K Piotrzkowski (CP3) *
11* http://www.fynu.ucl.ac.be/hector.html *
12* *
13* Center for Cosmology, Particle Physics and Phenomenology *
14* Universite catholique de Louvain *
15* Louvain-la-Neuve, Belgium *
16 * *
17 * * * * * * * * * * * * * * * * * * * * * * * * * * * */
18
19/// \file H_VerticalKicker.cc
20/// \brief Classes aiming at simulating vertical kickers in the beamline
21
22// fk [rad] for kickers !!!!
23
24// local #includes
25#include "H_VerticalKicker.h"
26#include "H_TransportMatrices.h"
27
28void H_VerticalKicker::setMatrix(const float eloss, const float p_mass, const float p_charge) {
29 extern int kickers_on;
30 if(kickers_on) {
31 element_mat = vkickmat(element_length,fk,eloss,p_mass,p_charge);
32 } else{
33 element_mat = driftmat(element_length);
34 }
35 return ;
36}
37
38H_VerticalKicker* H_VerticalKicker::clone() const {
39 H_VerticalKicker* temp_kick = new H_VerticalKicker(name,fs,fk,element_length);
40 temp_kick->setAperture(element_aperture);
41 temp_kick->setX(xpos);
42 temp_kick->setY(ypos);
43 temp_kick->setTX(txpos);
44 temp_kick->setTY(typos);
45 temp_kick->setBetaX(betax);
46 temp_kick->setBetaY(betay);
47 return temp_kick;
48}
49
50
Note: See TracBrowser for help on using the repository browser.