-
Notifications
You must be signed in to change notification settings - Fork 0
/
RR2020V0922_TEMPLATE_fixed
7539 lines (7539 loc) · 456 KB
/
RR2020V0922_TEMPLATE_fixed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
! DATE AND TIME: 10/11/20 15.13.59
!
! FILE: RR2020V0922.MAD
!
! Set values for the variables to adjust multipole moments
!VALUEFOR_K0L_EVEN := 0.0
!VALUEFOR_K0L_ODD := 0.0
!VALUEFOR_K1L_EVEN := 0.0
!VALUEFOR_K1L_ODD := 0.0
!VALUEFOR_K2L_EVEN := 0.0
!VALUEFOR_K2L_ODD := 0.0
!VALUEFOR_K3L_EVEN := 0.0
!VALUEFOR_K3L_ODD := 0.0
!VALUEFOR_K4L_EVEN := 0.0
!VALUEFOR_K4L_ODD := 0.0
!VALUEFOR_K5L_EVEN := 0.0
!VALUEFOR_K5L_ODD := 0.0
KE := 7.94633
E0 := 0.93826
P0 := SQRT(KE*(2.0*E0+KE))
BRHO := P0/0.2997925
DIR := -1.0
LBPM := 0.0
L8BPM := 0.0
LRKA50_MAG := 0.58
LRKA50_C2UF := 0.578054
LRKA50_C2DF := 0.587706
QT601_I := 0.0
QT602_I := 0.0
QT603_I := 0.0
QT604_I := 0.0
QT605_I := 0.0
QT606_I := 0.0
QT607_I := 0.0
QT608_I := 0.0
QT609_I := 0.0
QT301_I := 0.0
QT302_I := 0.0
QT303_I := 0.0
QT304_I := 0.0
QT305_I := 0.0
QT306_I := 0.0
QT307_I := 0.0
QT308_I := 0.0
QT309_I := 0.0
LMARKER := 1.0E-6
LMARKERA := 1.0E-6
LMARKERB := 1.0E-6
LMARKERC := 1.0E-6
QBPT4K1 := 0.0
QBPT3K1 := 0.0
QBPT2K1 := 0.0
QBPT1K1 := 0.0
QBPT0K1 := 0.0
QT301B_I := 0.0
QT302A_I := 0.0
QT302B_I := 0.0
QT302C_I := 0.0
QT303B_I := 0.0
QT304A_I := 0.0
QT305A_I := 0.0
QT305B_I := 0.0
QT305C_I := 0.0
QT307C_I := 0.0
QT307B_I := 0.0
QT307A_I := 0.0
QT308A_I := 0.0
QT309A_I := 0.0
KS_ECOOL := 0.0
K180_ANG := 0.0
V180C_I := 0.0
V301_I := 0.0
K90_ANG := 0.0
H90C_I := 0.0
H308_I := 0.0
KS_SPB01 := 0.0
KS_SPB02 := 0.0
KS_SPQ01 := 0.0
SQ404_I := 0.0
SQ408_I := 4.0
SQ410_I := 4.0
SQ504_I := -4.0
SQ506_I := -4.0
SF_I := 0.0
SD_I := 0.0
H100_I := 0.0
H102_I := 0.0
H104_I := 0.0
H106_I := 0.0
H108_I := 0.0
H110_I := 0.0
H112_I := 0.0
H114_I := 0.0
H116_I := 0.0
H118_I := 0.0
H120_I := 0.0
H122_I := 0.0
H124_I := 0.0
H126_I := 0.0
H128_I := 0.0
H130_I := 0.0
H202_I := 0.0
H204_I := 0.0
H206_I := 0.0
H208_I := 0.0
H210_I := 0.0
H212_I := 0.0
H214_I := 0.0
H216_I := 0.0
H218_I := 0.0
H220_I := 0.0
H222_I := 0.0
H224_I := 0.0
H226_I := 0.0
H228_I := 0.0
H230_I := 0.0
H232_I := 0.0
H302_I := 0.0
H305_I := 0.0
H307_I := 0.0
H310_I := 0.0
H312_I := 0.0
H314_I := 0.0
H316_I := 0.0
H318_I := 0.0
H320_I := 0.0
H322_I := 0.0
H324_I := 0.0
H326_I := 0.0
H328_I := 0.0
H330_I := 0.0
H332_I := 0.0
H334_I := 0.0
H336_I := 0.0
H338_I := 0.0
H340_I := 0.0
H400_I := 0.0
H402_I := 0.0
H404_I := 0.0
H406_I := 0.0
H408_I := 0.0
H410_I := 0.0
H412_I := 0.0
H414_I := 0.0
H416_I := 0.0
H418_I := 0.0
H420_I := 0.0
H422_I := 0.0
H424_I := 0.0
H426_I := 0.0
H428_I := 0.0
H430_I := 0.0
H502_I := 0.0
H504_I := 0.0
H506_I := 0.0
H508_I := 0.0
H510_I := 0.0
H512_I := 0.0
H514_I := 0.0
H516_I := 0.0
H518_I := 0.0
H520_I := 0.0
H522_I := 0.0
H524_I := 0.0
H526_I := 0.0
H528_I := 0.0
H530_I := 0.0
H532_I := 0.0
H602_I := 0.0
H604_I := 0.0
H606_I := 0.0
H608_I := 0.0
H610_I := 0.0
H612_I := 0.0
H614_I := 0.0
H616_I := 0.0
H618_I := 0.0
H620_I := 0.0
H622_I := 0.0
H624_I := 0.0
H626_I := 0.0
H628_I := 0.0
H630_I := 0.0
H632_I := 0.0
H634_I := 0.0
H636_I := 0.0
H638_I := 0.0
H640_I := 0.0
H100_G := 0.0
H102_G := 0.0
H104_G := 0.0
H106_G := 0.0
H108_G := 0.0
H110_G := 0.0
H112_G := 0.0
H114_G := 0.0
H116_G := 0.0
H118_G := 0.0
H120_G := 0.0
H122_G := 0.0
H124_G := 0.0
H126_G := 0.0
H128_G := 0.0
H130_G := 0.0
H202_G := 0.0
H204_G := 0.0
H206_G := 0.0
H208_G := 0.0
H210_G := 0.0
H212_G := 0.0
H214_G := 0.0
H216_G := 0.0
H218_G := 0.0
H220_G := 0.0
H222_G := 0.0
H224_G := 0.0
H226_G := 0.0
H228_G := 0.0
H230_G := 0.0
H232_G := 0.0
H302_G := 0.0
H305_G := 0.0
H307_G := 0.0
H308_G := 0.0
H310_G := 0.0
H312_G := 0.0
H314_G := 0.0
H316_G := 0.0
H318_G := 0.0
H320_G := 0.0
H322_G := 0.0
H324_G := 0.0
H326_G := 0.0
H328_G := 0.0
H330_G := 0.0
H332_G := 0.0
H334_G := 0.0
H336_G := 0.0
H338_G := 0.0
H340_G := 0.0
H400_G := 0.0
H402_G := 0.0
H404_G := 0.0
H406_G := 0.0
H408_G := 0.0
H410_G := 0.0
H412_G := 0.0
H414_G := 0.0
H416_G := 0.0
H418_G := 0.0
H420_G := 0.0
H422_G := 0.0
H424_G := 0.0
H426_G := 0.0
H428_G := 0.0
H430_G := 0.0
H502_G := 0.0
H504_G := 0.0
H506_G := 0.0
H508_G := 0.0
H510_G := 0.0
H512_G := 0.0
H514_G := 0.0
H516_G := 0.0
H518_G := 0.0
H520_G := 0.0
H522_G := 0.0
H524_G := 0.0
H526_G := 0.0
H528_G := 0.0
H530_G := 0.0
H532_G := 0.0
H602_G := 0.0
H604_G := 0.0
H606_G := 0.0
H608_G := 0.0
H610_G := 0.0
H612_G := 0.0
H614_G := 0.0
H616_G := 0.0
H618_G := 0.0
H620_G := 0.0
H622_G := 0.0
H624_G := 0.0
H626_G := 0.0
H628_G := 0.0
H630_G := 0.0
H632_G := 0.0
H634_G := 0.0
H636_G := 0.0
H638_G := 0.0
H640_G := 0.0
H100_T := 0.0
H102_T := 0.0
H104_T := 0.0
H106_T := 0.0
H108_T := 0.0
H110_T := 0.0
H112_T := 0.0
H114_T := 0.0
H116_T := 0.0
H118_T := 0.0
H120_T := 0.0
H122_T := 0.0
H124_T := 0.0
H126_T := 0.0
H128_T := 0.0
H130_T := 0.0
H202_T := 0.0
H204_T := 0.0
H206_T := 0.0
H208_T := 0.0
H210_T := 0.0
H212_T := 0.0
H214_T := 0.0
H216_T := 0.0
H218_T := 0.0
H220_T := 0.0
H222_T := 0.0
H224_T := 0.0
H226_T := 0.0
H228_T := 0.0
H230_T := 0.0
H232_T := 0.0
H302_T := 0.0
H305_T := 0.0
H307_T := 0.0
H308_T := 0.0
H310_T := 0.0
H312_T := 0.0
H314_T := 0.0
H316_T := 0.0
H318_T := 0.0
H320_T := 0.0
H322_T := 0.0
H324_T := 0.0
H326_T := 0.0
H328_T := 0.0
H330_T := 0.0
H332_T := 0.0
H334_T := 0.0
H336_T := 0.0
H338_T := 0.0
H340_T := 0.0
H400_T := 0.0
H402_T := 0.0
H404_T := 0.0
H406_T := 0.0
H408_T := 0.0
H410_T := 0.0
H412_T := 0.0
H414_T := 0.0
H416_T := 0.0
H418_T := 0.0
H420_T := 0.0
H422_T := 0.0
H424_T := 0.0
H426_T := 0.0
H428_T := 0.0
H430_T := 0.0
H502_T := 0.0
H504_T := 0.0
H506_T := 0.0
H508_T := 0.0
H510_T := 0.0
H512_T := 0.0
H514_T := 0.0
H516_T := 0.0
H518_T := 0.0
H520_T := 0.0
H522_T := 0.0
H524_T := 0.0
H526_T := 0.0
H528_T := 0.0
H530_T := 0.0
H532_T := 0.0
H602_T := 0.0
H604_T := 0.0
H606_T := 0.0
H608_T := 0.0
H610_T := 0.0
H612_T := 0.0
H614_T := 0.0
H616_T := 0.0
H618_T := 0.0
H620_T := 0.0
H622_T := 0.0
H624_T := 0.0
H626_T := 0.0
H628_T := 0.0
H630_T := 0.0
H632_T := 0.0
H634_T := 0.0
H636_T := 0.0
H638_T := 0.0
H640_T := 0.0
V101_I := 0.0
V103_I := 0.0
V105_I := 0.0
V107_I := 0.0
V109_I := 0.0
V111_I := 0.0
V113_I := 0.0
V115_I := 0.0
V117_I := 0.0
V119_I := 0.0
V121_I := 0.0
V123_I := 0.0
V125_I := 0.0
V127_I := 0.0
V129_I := 0.0
V201_I := 0.0
V203_I := 0.0
V205_I := 0.0
V207_I := 0.0
V209_I := 0.0
V211_I := 0.0
V213_I := 0.0
V215_I := 0.0
V217_I := 0.0
V219_I := 0.0
V221_I := 0.0
V223_I := 0.0
V225_I := 0.0
V227_I := 0.0
V229_I := 0.0
V231_I := 0.0
V303_I := 0.0
V305_I := 0.0
V307_I := 0.0
V309_I := 0.0
V311_I := 0.0
V313_I := 0.0
V315_I := 0.0
V317_I := 0.0
V319_I := 0.0
V321_I := 0.0
V323_I := 0.0
V325_I := 0.0
V327_I := 0.0
V329_I := 0.0
V331_I := 0.0
V333_I := 0.0
V335_I := 0.0
V337_I := 0.0
V339_I := 0.0
V341_I := 0.0
V401_I := 0.0
V403_I := 0.0
V405_I := 0.0
V407_I := 0.0
V409_I := 0.0
V411_I := 0.0
V413_I := 0.0
V415_I := 0.0
V417_I := 0.0
V419_I := 0.0
V421_I := 0.0
V423_I := 0.0
V425_I := 0.0
V427_I := 0.0
V429_I := 0.0
V501_I := 0.0
V503_I := 0.0
V505_I := 0.0
V507_I := 0.0
V509_I := 0.0
V511_I := 0.0
V513_I := 0.0
V515_I := 0.0
V517_I := 0.0
V519_I := 0.0
V521_I := 0.0
V523_I := 0.0
V525_I := 0.0
V527_I := 0.0
V529_I := 0.0
V531_I := 0.0
V601_I := 0.0
V603_I := 0.0
V605_I := 0.0
V607_I := 0.0
V609_I := 0.0
V611_I := 0.0
V613_I := 0.0
V615_I := 0.0
V617_I := 0.0
V619_I := 0.0
V621_I := 0.0
V623_I := 0.0
V625_I := 0.0
V627_I := 0.0
V629_I := 0.0
V631_I := 0.0
V633_I := 0.0
V635_I := 0.0
V637_I := 0.0
V639_I := 0.0
V641_I := 0.0
LARCCELL := 17.288177764
LSSCELL := 17.288639
LDISCELL := 12.96643319
NDIPOLES := 3.013333E2
THETA := TWOPI/NDIPOLES
LARCMAG := 4.4958
LARCEND := 0.0889
LARCPHY := LARCMAG+2.0*LARCEND
DWELD: DRIFT, L=0.0762
LARCSLOT := LARCPHY+2.0*DWELD[L]
LDISMAG := 3.0988
LDISEND := LARCEND
LDISPHY := LDISMAG+2.0*LDISEND
LDISSLOT := LDISPHY+2.0*DWELD[L]
B0ARC := DIR*THETA*BRHO/LARCMAG
B0DIS := DIR*0.666666666667*THETA*BRHO/LDISMAG
ARCANG := B0ARC*LARCMAG/BRHO
DISANG := B0DIS*LDISMAG/BRHO
ARCK1F := 0.01131616
ARCK1D := -0.01092083
DISK1F := 0.022534721
DISK1D := -0.023013743
ARCK2F := 0.01250234
ARCK2D := -0.02164293
DISK2F := 0.0
DISK2D := 0.0
K130_ANG := 0.0
K400_ANG := 0.0
LAM214_ANG := 0.0
LAM328_ANG := 0.0
LPM402_ANG := 0.0
LAM402_ANG := 0.0
SSQK1F := 0.0886011
SSQK1D := -0.085391
Q1K1 := 0.0
Q2K1 := 0.0
QBP4K1 := -0.02418635
QBP3K1 := 0.03587045
QBP2K1 := -0.02163952
QBP1K1 := -0.02949152
QFCELL60 := 0.0555785
QDCELL60 := -0.05574825
LCS := 0.4318
BELLEND: DRIFT, L=0.09525
BELLSLOT := 2.0*BELLEND[L]
PUMPEND: DRIFT, L=0.127
TSPSLOT := 2.0*PUMPEND[L]
VACTEE: DRIFT, L=0.2667
BPM8END: DRIFT, L=0.1016
LHBBPMSLOT := 2.0*L8BPM+4.0*BPM8END[L]+VACTEE[L]+BELLSLOT
CS2: DRIFT, L=0.1619
L60BPMSLOT := L8BPM+2.0*BPM8END[L]+TSPSLOT+BELLSLOT+CS2[L]
CS: DRIFT, L=LCS
BPMEND: DRIFT, L=0.20955
LBMSLOT := LBPM+2.0*BPMEND[L]+TSPSLOT+BELLSLOT+CS[L]
LBMSLOT1 := LBPM+2.0*BPMEND[L]
LBMSLOT2 := LBPM+2.0*BPMEND[L]+BELLSLOT+CS[L]
LBMSLOT3 := LBPM+2.0*BPMEND[L]+BELLSLOT
LTORR := 0.2794
LSCHTKY := 1.0922
LDCCT := 0.4572
LSCRPR := 0.29845
LSCHTKYGZ := 1.651
LFW := 0.5334
LMWIRE := 0.4064
LPMLAM := 4.064
LLAM := 2.286
LAM102_TILT := 1.570596
LAM232_TILT := 1.570596
LPM402_TILT := 1.46
LAM402_TILT := 1.46
LAM522_TILT := 1.570596
LRKD25_MAG := 0.624841
LRKD25_C2UF := 0.577343
LRKD25_C2DF := 0.588011
RKD25_DEND: DRIFT, L=LRKD25_C2DF-LRKD25_MAG/2.0
RKD25_UEND: DRIFT, L=LRKD25_C2UF-LRKD25_MAG/2.0
LRKD25_SLOT := LRKD25_MAG+RKD25_UEND[L]+RKD25_DEND[L]
LRKB25_MAG := 1.183642
LRKB25_C2UF := 0.866142
LRKB25_C2DF := 0.855474
RKB25_UEND: DRIFT, L=LRKB25_C2UF-LRKB25_MAG/2.0
RKB25_DEND: DRIFT, L=LRKB25_C2DF-LRKB25_MAG/2.0
RKA50_UEND: DRIFT, L=LRKA50_C2UF-LRKA50_MAG/2.0
RKA50_DEND: DRIFT, L=LRKA50_C2DF-LRKA50_MAG/2.0
LRKB25_SLOT := LRKB25_MAG+RKB25_UEND[L]+RKB25_DEND[L]
LRKA50_SLOT := LRKA50_MAG+RKA50_UEND[L]+RKA50_DEND[L]
K230_ANG := 0.0
K308_ANG := 0.0
K104_ANG := 0.0
LK104IN_SLOT := 7.0*LRKA50_SLOT
RGK400_ANG := 0.0
RAK400_ANG := 0.0
LSEX := 0.1524
B2LPERAMP := 9.328
BRHO_KG := BRHO*10.0
K2PERAMP := DIR*B2LPERAMP/(LSEX*BRHO_KG)
S112_I := SF_I
S128_I := SF_I
S330_I := SF_I
S412_I := SF_I
S428_I := SF_I
S630_I := SF_I
SC220_I := SF_I
SC222_I := SF_I
S111_I := SD_I
S113_I := SD_I
S119_I := SD_I
S207_I := SD_I
S411_I := SD_I
S413_I := SD_I
S419_I := SD_I
S507_I := SD_I
S633_I := SD_I
SC319_I := SD_I
SC321_I := SD_I
S331_I := 0.0
LSQUAD := 0.1524
LSQUADEND := 0.0254
LSQUADSLOT := LSQUAD+2.0*LSQUADEND
DSQK1 := 0.07506/(LSQUAD*2.96501E2)
LSQUAD2 := 0.1016
LSQUADEND2 := 0.0
LSQUADSLOT2 := LSQUAD2+2.0*LSQUADEND2
DSQEK1 := 0.21/(LSQUAD2*2.96501E2)
LQUAD := 0.508
LQEND := 0.0635
LQUADPHY := LQUAD+2.0*LQEND
LQUADSLOT := LQUADPHY+2.0*DWELD[L]
LQC := 0.2032
DQTK1 := 0.0882546/BRHO
LBPQUAD := 0.3048
LBPQUADEND := 0.02223
LBPQUADSLOT := LBPQUAD+2.0*LBPQUADEND
DBPDSINC := 2.0
DBPSSDEC := 1.995995
D6IN: DRIFT, L=0.1524
QBPEND: DRIFT, L=0.0508
L60QUADSLOT := 2.0*DWELD[L]+4.0*QBPEND[L]+2.0*LQUAD+D6IN[L]
K1DISEND := 0.0
K1Q529C := -0.029492
K1Q530C := -0.02164
K1Q531C := 0.03587
K1Q532C := -0.024186
HTSTEEL := 0.2032
HTEND := 0.066675
HTSLOT := HTSTEEL+2.0*HTEND
VTSTEEL := 0.1524
VTEND := 0.0936625
VTSLOT := VTSTEEL+2.0*VTEND
LHSTEEL := 0.4064
LHTEND := 0.0635
LHSLOT := LHSTEEL+2.0*LHTEND
LVSTEEL := 0.4064
LVTEND := 0.0381
LVSLOT := LVSTEEL+2.0*LVTEND
HT_ANGPERAMP := 0.1171E-3
VT_ANGPERAMP := 0.7355E-4
LH_ANGPERAMP := 0.14313E-3
LV_ANGPERAMP := 0.11614E-3
HD_ANGPERAMP := 0.19897E-3
LAM102_ANG := 0.0
LAM232_ANG := 0.0
LAM522_ANG := 0.0
RBK400_ANG := 0.0
K2F := 0.0
K2D := 0.0
Q2K2 := 0.0
HK2301 := 0.0
HK232 := 0.0
HK302 := 0.0
H304_I := 0.0
H304_G := 0.0
H304_T := 0.0
H306_I := 0.0
H306_G := 0.0
H306_T := 0.0
HK520 := 0.0
HK522 := 0.0
HK524 := 0.0
DISK1LSF_FF := 0.0
DISK1LSD_FF := 0.0
DISK1LSF_DD := 0.0
DISK1LSD_DD := 0.0
DISK1LSF_FFU := DISK1LSF_FF
DISK1LSF_FFD := DISK1LSF_FF
DISK1LSD_FFU := DISK1LSD_FF
DISK1LSD_FFD := DISK1LSD_FF
DISK1LSF_DDU := DISK1LSF_DD
DISK1LSF_DDD := DISK1LSF_DD
DISK1LSD_DDU := DISK1LSD_DD
DISK1LSD_DDD := DISK1LSD_DD
SSQK1D30 := -0.090741685451
SSQK1F30 := 0.095412043759
K1Q301B := SSQK1D30
K1Q302 := SSQK1F30
K1Q303 := SSQK1D30
K1Q304 := SSQK1F30
K1Q305 := SSQK1D30
K1Q306 := SSQK1F30
K1Q307 := SSQK1D30
K1Q308 := SSQK1F30
K1Q309A := SSQK1D30
K520_ANG := 0.0
LMIVC := 0.3048
LMIVC_END := 0.0635
LMIVC_SLOT := 2.0*LMIVC_END+LMIVC
TAPERED_PORT: DRIFT, L=0.3556
PARALLEL_PORT: DRIFT, L=0.98425
SECCOLSLOT := PARALLEL_PORT[L]+2.0*TAPERED_PORT[L]
DISK1LSDU := 0.0
DISK1LSDD := 0.0
DISK1LSF_U := 0.0
DISK1LSF_D := 0.0
HK304 := 0.0
HK306 := 0.0
HK308 := 0.0
HK310 := 0.0
VK301 := 0.0
VK303 := 0.0
VK305 := 0.0
VK307 := 0.0
VK309 := 0.0
LLAM522 := 0.0
CIR_VC611 := 0.0
CIR_VC613 := 0.0
CIR_VC615 := 0.0
CIR_VC617 := 0.0
CIR_VC619 := 0.0
DELLSLOT := 0.0
FFAC0 := 0.935
DFAC0 := 4.869
FFAC := FFAC0/8.695669113
DFAC := -DFAC0/15.05316267995
K2LFEND := FFAC*LARCMAG*DIR*ARCK2F
K2LDEND := DFAC*LARCMAG*DIR*ARCK2D
DX := -0.78E-2
K1LFROMK2LFENDU := K2LFEND*DX/DIR
K1LFROMK2LDENDU := K2LDEND*DX/DIR
K1FACCU := 12.35
K1DACCU := -2.55
K1LENDSFU := K1FACCU*LARCMAG*B0ARC*1.0E-4/BRHO/(DIR*0.0254)
K1LENDSDU := K1DACCU*LARCMAG*B0ARC*1.0E-4/BRHO/(DIR*0.0254)
BELLOW: MARKER
MTSPIP: MARKER
MTSP: MARKER
BPEND: DRIFT, L=0.20955
HP: HMONITOR, TYPE=KHKD, L=LBPM
VP: VMONITOR, TYPE=KVKD, L=LBPM
RWCM: INSTRUMENT, L=0.9652
D9IN: DRIFT, L=0.2286
QEND: DRIFT, L=LQEND
DQQ: DRIFT, L=1.85-QEND[L]-DWELD[L]
DEMPTY: DRIFT, L=LSSCELL-2.0*LQUADSLOT-2.0*DQQ[L]-2.0*LBMSLOT-2.0*LMARKERC
DQQBP: DRIFT, L=DQQ[L]-LBPQUADSLOT-0.3683
DEMPTY60: DRIFT, L=(LSSCELL-DBPSSDEC-2.0*L60QUADSLOT-2.0*DQQBP[L]-2.0*L60BPMSLOT-2.0*LBPQUADSLOT-2.0*LMARKERC)/2.0
D602A: DRIFT, L=DEMPTY60[L]-2.0*D6IN[L]-RWCM[L]
WBPU: INSTRUMENT, L=1.59004
D602B: DRIFT, L=DEMPTY60[L]-2.0*D6IN[L]-2.0*WBPU[L]
TOR214: INSTRUMENT, L=0.2794
TOR104: INSTRUMENT, L=LTORR
RRHS: INSTRUMENT, L=LSCHTKY
RRVS: INSTRUMENT, L=LSCHTKY
DCCT: INSTRUMENT, L=LDCCT
SCRPRH: INSTRUMENT, L=LSCRPR
SCRPRV: INSTRUMENT, L=LSCRPR
RRHSGZ: INSTRUMENT, L=LSCHTKYGZ
RRVSGZ: INSTRUMENT, L=LSCHTKYGZ
FWH: INSTRUMENT, L=LFW
FWV: INSTRUMENT, L=LFW
MW102: INSTRUMENT, L=LMWIRE
MW103: INSTRUMENT, L=LMWIRE
MW104: INSTRUMENT, L=LMWIRE
MW105: INSTRUMENT, L=LMWIRE
MW102U: MARKER
MW102D: MARKER
MW103U: MARKER
MW103D: MARKER
MW104U: MARKER
MW104D: MARKER
LPMEND: DRIFT, L=0.1016
LPMSLOT: DRIFT, L=LPMLAM+2.0*LPMEND[L]+2.0*DWELD[L]
LAMEND: DRIFT, L=0.2234
LAMSLOTHALF: DRIFT, L=LLAM/2.0+LAMEND[L]
LAMSLOT: DRIFT, L=LLAM+2.0*LAMEND[L]
LAM102: KICKER, L=LLAM, HKICK=LAM102_ANG*COS(LAM102_TILT), VKICK=LAM102_ANG*SIN(LAM102_TILT)
LAM232: KICKER, L=LLAM, HKICK=LAM232_ANG*COS(LAM232_TILT), VKICK=LAM232_ANG*SIN(LAM232_TILT)
LPM402: KICKER, L=LPMLAM, HKICK=LPM402_ANG*COS(LPM402_TILT), VKICK=LPM402_ANG*SIN(LPM402_TILT)
LAM402: KICKER, L=LLAM, HKICK=LAM402_ANG*COS(LAM402_TILT), VKICK=LAM402_ANG*SIN(LAM402_TILT)
LAM522: KICKER, L=LLAM, HKICK=LAM522_ANG*COS(LAM522_TILT), VKICK=LAM522_ANG*SIN(LAM522_TILT)
LAM102_US: MARKER
LAM102_DS: MARKER
LAM102U: MULTIPOLE, K0L=0.0
LAM102D: MULTIPOLE, K0L=0.0
MLAM102U: MARKER
MLAM102D: MARKER
MRKRRLAM: MARKER
LAM232_US: MARKER
LAM232_DS: MARKER
LAM232U: MULTIPOLE, K0L=0.0
LAM232D: MULTIPOLE, K0L=0.0
MLAM232U: MARKER
MLAM232D: MARKER
LAM402_US: MARKER
LAM402_DS: MARKER
LAM402U: MULTIPOLE, K1L=-0.78E-3, T1=0.785398163397, K2L=0.036*DIR, T2=0.523598775598, K3L=-4.65, T3=0.392699081699
LAM402D: MULTIPOLE, K1L=-0.78E-3, T1=0.785398163397, K2L=0.036*DIR, T2=0.523598775598, K3L=-4.65, T3=0.392699081699
MLAM402U: MARKER
MLAM402D: MARKER
DIFF_PM2MLAWU: DRIFT, L=0.5*(LPMSLOT[L]-LAMSLOT[L])
DIFF_PM2MLAWD: DRIFT, L=0.5*(LPMSLOT[L]-LAMSLOT[L])
DDIFU: DRIFT, L=DIFF_PM2MLAWU[L]
DDIFD: DRIFT, L=DIFF_PM2MLAWD[L]
LAM522_US: MARKER
LAM522_DS: MARKER
LAM522U: MULTIPOLE, K0L=0.0
LAM522D: MULTIPOLE, K0L=0.0
MLAM522U: MARKER
MLAM522D: MARKER
MRKRRKICK: MARKER
K2301U: MULTIPOLE, K0L=0.0
K2301D: MULTIPOLE, K0L=0.0
K2302U: MULTIPOLE, K0L=0.0
K2302D: MULTIPOLE, K0L=0.0
DKK1: DRIFT, L=RKB25_UEND[L]
HRRK2301: HKICKER, L=LRKB25_MAG, KICK=0.5*K230_ANG
HRRK2302: HKICKER, L=LRKB25_MAG, KICK=0.5*K230_ANG
DKK2: DRIFT, L=RKB25_DEND[L]
K104BU: MULTIPOLE, K0L=0.0
K104BD: MULTIPOLE, K0L=0.0
K1041U: MULTIPOLE, K0L=0.0
K1041D: MULTIPOLE, K0L=0.0
K1042U: MULTIPOLE, K0L=0.0
K1042D: MULTIPOLE, K0L=0.0
K1043U: MULTIPOLE, K0L=0.0
K1043D: MULTIPOLE, K0L=0.0
K1044U: MULTIPOLE, K0L=0.0
K1044D: MULTIPOLE, K0L=0.0
K1045U: MULTIPOLE, K0L=0.0
K1045D: MULTIPOLE, K0L=0.0
K1046U: MULTIPOLE, K0L=0.0
K1046D: MULTIPOLE, K0L=0.0
K104B: HKICKER, L=LRKA50_MAG, KICK=0.0
K1041: HKICKER, L=LRKA50_MAG, KICK=K104_ANG
K1042: HKICKER, L=LRKA50_MAG, KICK=K104_ANG
K1043: HKICKER, L=LRKA50_MAG, KICK=K104_ANG
K1044: HKICKER, L=LRKA50_MAG, KICK=K104_ANG
K1045: HKICKER, L=LRKA50_MAG, KICK=K104_ANG
K1046: HKICKER, L=LRKA50_MAG, KICK=K104_ANG
KG4001U: MULTIPOLE, K0L=0.0
KG4001D: MULTIPOLE, K0L=0.0
KG4002U: MULTIPOLE, K0L=0.0
KG4002D: MULTIPOLE, K0L=0.0
KG4003U: MULTIPOLE, K0L=0.0
KG4003D: MULTIPOLE, K0L=0.0
KG4004U: MULTIPOLE, K0L=0.0
KG4004D: MULTIPOLE, K0L=0.0
KG4005U: MULTIPOLE, K0L=0.0
KG4005D: MULTIPOLE, K0L=0.0
KG400BU: MULTIPOLE, K0L=0.0
KG400BD: MULTIPOLE, K0L=0.0
RGK4001: HKICKER, L=LRKA50_MAG, KICK=RGK400_ANG
RGK4002: HKICKER, L=LRKA50_MAG, KICK=RGK400_ANG
RGK4003: HKICKER, L=LRKA50_MAG, KICK=RGK400_ANG
RGK4004: HKICKER, L=LRKA50_MAG, KICK=RGK400_ANG
RGK4005: HKICKER, L=LRKA50_MAG, KICK=RGK400_ANG
RBK4001: HKICKER, L=LRKA50_MAG, KICK=RBK400_ANG
RGK400_SLOT: DRIFT, L=RKA50_UEND[L]+LRKA50_MAG+RKA50_DEND[L]
KA4001U: MULTIPOLE, K0L=0.0
KA4001D: MULTIPOLE, K0L=0.0
KA4002U: MULTIPOLE, K0L=0.0
KA4002D: MULTIPOLE, K0L=0.0
KA4003U: MULTIPOLE, K0L=0.0
KA4003D: MULTIPOLE, K0L=0.0
RAK4001: HKICKER, L=LRKD25_MAG, KICK=RAK400_ANG
RAK4002: HKICKER, L=LRKD25_MAG, KICK=RAK400_ANG
RAK4003: HKICKER, L=LRKD25_MAG, KICK=RAK400_ANG
RAK400_SLOT: DRIFT, L=RKD25_UEND[L]+LRKD25_MAG+RKD25_DEND[L]
SEXEND: DRIFT, L=0.028575
SEXSLOT: DRIFT, L=LSEX+2.0*SEXEND[L]
SEXH: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=K2F
SEXV: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=K2D
S112: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S112_I*K2PERAMP
S114: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S112_I*K2PERAMP
S116: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S112_I*K2PERAMP
S118: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S112_I*K2PERAMP
S128: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S128_I*K2PERAMP
S130: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S128_I*K2PERAMP
S202: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S128_I*K2PERAMP
S204: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S128_I*K2PERAMP
S330: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S330_I*K2PERAMP
S332: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S330_I*K2PERAMP
S334: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S330_I*K2PERAMP
S336: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S330_I*K2PERAMP
S412: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S412_I*K2PERAMP
S414: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S412_I*K2PERAMP
S416: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S412_I*K2PERAMP
S418: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S412_I*K2PERAMP
S428: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S428_I*K2PERAMP
S430: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S428_I*K2PERAMP
S502: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S428_I*K2PERAMP
S504: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S428_I*K2PERAMP
S630: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S630_I*K2PERAMP
S632: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S630_I*K2PERAMP
S634: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S630_I*K2PERAMP
S636: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=S630_I*K2PERAMP
SC220A: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=SC220_I*K2PERAMP
SC220B: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=SC220_I*K2PERAMP
SC222A: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=SC222_I*K2PERAMP
SC222B: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=SC222_I*K2PERAMP
SC319A: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=SC319_I*K2PERAMP
SC319B: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=SC319_I*K2PERAMP
SC321A: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=SC321_I*K2PERAMP
SC321B: SEXTUPOLE, TYPE=XCHR, L=LSEX, K2=SC321_I*K2PERAMP
S112U: MULTIPOLE, K2L=0.0
S112D: MULTIPOLE, K2L=0.0
S114U: MULTIPOLE, K2L=0.0
S114D: MULTIPOLE, K2L=0.0
S116U: MULTIPOLE, K2L=0.0
S116D: MULTIPOLE, K2L=0.0
S118U: MULTIPOLE, K2L=0.0
S118D: MULTIPOLE, K2L=0.0
S128U: MULTIPOLE, K2L=0.0
S128D: MULTIPOLE, K2L=0.0
S130U: MULTIPOLE, K2L=0.0
S130D: MULTIPOLE, K2L=0.0
S202U: MULTIPOLE, K2L=0.0
S202D: MULTIPOLE, K2L=0.0
S204U: MULTIPOLE, K2L=0.0
S204D: MULTIPOLE, K2L=0.0
S330U: MULTIPOLE, K2L=0.0
S330D: MULTIPOLE, K2L=0.0
S332U: MULTIPOLE, K2L=0.0
S332D: MULTIPOLE, K2L=0.0
S334U: MULTIPOLE, K2L=0.0
S334D: MULTIPOLE, K2L=0.0
S336U: MULTIPOLE, K2L=0.0
S336D: MULTIPOLE, K2L=0.0
S412U: MULTIPOLE, K2L=0.0
S412D: MULTIPOLE, K2L=0.0
S414U: MULTIPOLE, K2L=0.0
S414D: MULTIPOLE, K2L=0.0
S416U: MULTIPOLE, K2L=0.0
S416D: MULTIPOLE, K2L=0.0
S418U: MULTIPOLE, K2L=0.0
S418D: MULTIPOLE, K2L=0.0
S428U: MULTIPOLE, K2L=0.0
S428D: MULTIPOLE, K2L=0.0
S430U: MULTIPOLE, K2L=0.0
S430D: MULTIPOLE, K2L=0.0
S502U: MULTIPOLE, K2L=0.0
S502D: MULTIPOLE, K2L=0.0
S504U: MULTIPOLE, K2L=0.0
S504D: MULTIPOLE, K2L=0.0
S630U: MULTIPOLE, K2L=0.0
S630D: MULTIPOLE, K2L=0.0
S632U: MULTIPOLE, K2L=0.0
S632D: MULTIPOLE, K2L=0.0
S634U: MULTIPOLE, K2L=0.0
S634D: MULTIPOLE, K2L=0.0
S636U: MULTIPOLE, K2L=0.0
S636D: MULTIPOLE, K2L=0.0
S111: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S111_I*K2PERAMP
S113: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S113_I*K2PERAMP
S115: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S113_I*K2PERAMP
S117: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S113_I*K2PERAMP
S119: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S119_I*K2PERAMP
S121: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S119_I*K2PERAMP
S123: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S119_I*K2PERAMP
S125: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S119_I*K2PERAMP
S127: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S119_I*K2PERAMP
S129: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S119_I*K2PERAMP
S203: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S207_I*K2PERAMP
S205: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S207_I*K2PERAMP
S207: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S207_I*K2PERAMP
S209: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S207_I*K2PERAMP
S211: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S207_I*K2PERAMP
S213: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S207_I*K2PERAMP
S331: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S331_I*K2PERAMP
S333: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S331_I*K2PERAMP
S411: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S411_I*K2PERAMP
S413: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S413_I*K2PERAMP
S415: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S413_I*K2PERAMP
S417: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S413_I*K2PERAMP
S419: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S419_I*K2PERAMP
S421: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S419_I*K2PERAMP
S423: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S419_I*K2PERAMP
S425: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S419_I*K2PERAMP
S427: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S419_I*K2PERAMP
S429: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S419_I*K2PERAMP
S501: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S507_I*K2PERAMP
S503: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S507_I*K2PERAMP
S507: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S507_I*K2PERAMP
S509: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S507_I*K2PERAMP
S511: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S507_I*K2PERAMP
S513: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S507_I*K2PERAMP
S633: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S633_I*K2PERAMP
S635: SEXTUPOLE, TYPE=YCHR, L=LSEX, K2=S633_I*K2PERAMP
S111U: MULTIPOLE, K2L=0.0
S111D: MULTIPOLE, K2L=0.0
S113U: MULTIPOLE, K2L=0.0