100 likes | 121 Views
Learn about optics data model, processing methods, Twiss output generation, and error handling in LSA. Automated process with evolving procedures and continuous improvements.
E N D
LSA optics processing Marek Strzelczyk AB/OP
Overview • Introduction • What do we need in LSA • Optics data model • Some LSA concepts related to optics • How do we process • Twiss generation • Optics upload • Further optics usage • Remarks, questions, discussion... M.Strzelczyk - LSA optics processing
What do we need in LSA • LSA requirements • Optic - named set of strengths per logical hardware • Link between optic and its source (file)– for on-line model • Ordered set of optics in time – beamprocess type • Data model • Optics • Twiss_outputs • Optic_strenghts • Optic_parameters • Optic_table M.Strzelczyk - LSA optics processing
Optics processing • Input: • Optics definition files • MAD-X job definition file • Output: • Optics • Twiss outputs • Strength (K) for each of logical hardware • Optics parameters • Tools: • Perl script • MAD-X M.Strzelczyk - LSA optics processing
Process overview • Twiss generation (MAD-X) • Result: Twiss output (files) • Twiss upload to LSA DB • Result: twiss_outputs, optics & optics_parameters tables filled • Optics population within LSA DB • Result: optic_strengths table filled • Further use in LSA • Settings generation • On-line model M.Strzelczyk - LSA optics processing
Twiss output generation • Loop over optics definition files (in a given path) • MAD-X job definition file substitution • Betas at IP (in meters) should be clearly defined in source files • Source file naming convention (ex. IP5_beta11.0p.str) • Call to MAD-X • Output files • Naming convention (ex. lhc.a1100c1100a1000l1000p.b2.data) • File name is then used to name an optic M.Strzelczyk - LSA optics processing
Optics upload and population in LSA DB • Insert new optics into optics table • Optic name and beam originating from Twiss output file name • Load all Twiss output files to twiss_outputs table • Split MCBX.*, MCX3.*, MCSOX.*, MCDO.* • Fill optic_parameters table • Loop over all Twiss outputs of a given optics set • Loop over all elements • Take appropriate value from file (K0L, K1L, VKICK, K1S, ...) • Resolve using element type (RBEND, QUADRUPOLE, VKICKER, ...) and element name • Put the strength into optic_strengths table M.Strzelczyk - LSA optics processing
Error handling • Check for: • Overwriting the existing optic • Not existing elements • Missing strengths • Strength differences among elements of the same logical hardware • ... • Create a log file M.Strzelczyk - LSA optics processing
Remarks... • Process of Twiss output generation and optics upload is automatised • It relies on some conventions • Procedure is well established... • ...but still evolving • New requirements are being precised • Improvements are being done M.Strzelczyk - LSA optics processing
Questions? • ... M.Strzelczyk - LSA optics processing