Closed coldfix closed 1 year ago
That was quick! I also thought it could be useful to have access to the list of beams. See https://github.com/hibtc/cpymad/compare/master...rdemaria:cpymad:beam-list
That was quick! I also thought it could be useful to have access to the list of beams. See master...rdemaria:cpymad:beam-list
Sure, makes sense. Post a PR when ready.
Resolves #122
@rdemaria This will change the property
madx.beam
to return the current beam (instead of deferring tomadx.command.beam
as was done until now), e.g.:mad = Madx() mad.beam(particle='electron') assert mad.beam.particle == 'electron'
Hello! Very nice to get this. Do I understand correctly that this would behave similarly to how madx.twiss()
does compared to madx.command.twiss()
?
Resolves #122 @rdemaria This will change the property
madx.beam
to return the current beam (instead of deferring tomadx.command.beam
as was done until now), e.g.:mad = Madx() mad.beam(particle='electron') assert mad.beam.particle == 'electron'
Hello! Very nice to get this. Do I understand correctly that this would behave similarly to how
madx.twiss()
does compared tomadx.command.twiss()
?
In a way. Both mad.twiss
and mad.beam
will be overloads of mad.command.XXX
with some specialized behaviour.
Resolves #122
@rdemaria This will change the property
madx.beam
to return the current beam (instead of deferring tomadx.command.beam
as was done until now), e.g.: