Changeset 32 in TRACY3 for trunk/tracy/tracy/src/soleilcommon.cc
- Timestamp:
- Apr 9, 2014, 3:50:11 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tracy/tracy/src/soleilcommon.cc
r11 r32 153 153 /*check whether the RF cavity hormonic number is defined or not*/ 154 154 if(Cell[Elem_GetPos(globval.cav, 1)].Elem.C->Ph == 0){ 155 printf("soleilcommon(): Error!!! Please define RF harmonic number in the lattice! \n" 156 "Because this parameter will be used to calculate stable phase for positive / negative momentum compaction factor\n"); 155 printf("soleilcommon(): Error!!! Please define the RF harmonic number in the lattice! \n" 156 "Because this parameter will be used to calculate the stable phase for the lattice with the " 157 "positive / negative momentum compaction factor\n"); 157 158 exit_(1); 158 159 } … … 169 170 globval.emittance = false; /* emittance on/off */ 170 171 globval.pathlength = false; /* Path lengthening computation */ 171 globval.CODimax = 40L; /* maximum number of iterations for COD algo */172 globval.CODimax = 40L; /* maximum number of iterations for COD algorithm */ 172 173 globval.dPcommon = 1e-10; /* Common energy step for energy differentiation */ 173 174 globval.delta_RF = RFacceptance;/* energy acceptance for SOLEIL */ 174 175 175 /* define x/y physical aperture , use the default values: +- 1 meter */176 /* define x/y physical aperture (vacuum chamber), use the default values: +- 1 meter */ 176 177 globval.Aperture_on = false; 177 178 … … 183 184 else 184 185 { // for transfer lines 185 /* Initial settings : */ 186 beta[0] = 8.1; 187 alpha[0] = 0.0; 188 beta[1] = 8.1; 189 alpha[1] = 0.0; 190 eta[0] = 0.0; 191 etap[0] = 0.0; 192 eta[1] = 0.0; 193 etap[1] = 0.0; 194 186 /* Initial optical parameters of the transfer line: */ 187 beta[0] = 34.46; // beta_x 188 beta[1] = 33.94; // beta_y 189 alpha[0] = -4.24; // alpha_x 190 alpha[1] = -4.34; // alpha_y 191 eta[0] = 0.0; // eta_x 192 etap[0] = 0.0; // etap_x 193 eta[1] = 0.0; // eta_y 194 etap[1] = 0.0; // etap_y 195 196 // set the initial orbit of the transfer line is zero 195 197 for (i = 0; i < ss_dim; i++) { 196 198 { … … 200 202 dP = codvect[4]; 201 203 204 codvect[0]=1e-4; 205 202 206 /* Defines global variables for Tracy code */ 203 207 globval.MatMeth = false; /* matrix method */ … … 214 218 globval.Aperture_on = false; 215 219 216 220 // transfer the optical functions and the orbit 217 221 TransTwiss(alpha, beta, eta, etap, codvect); 222 223 // print location, twiss parameters and close orbit/orbit at all elements position to a file 224 prt_cod("cod.out", globval.bpm, true); 218 225 } 219 226 }//finish read the transfer line
Note: See TracChangeset
for help on using the changeset viewer.