Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

p0c setter bug #55

Open
kparasch opened this issue Oct 16, 2020 · 1 comment
Open

p0c setter bug #55

kparasch opened this issue Oct 16, 2020 · 1 comment

Comments

@kparasch
Copy link

part1 = pysixtrack.Particles(p0c=2e10)
part1.tau=1.e-4
part1.ptau=0.

part2 = pysixtrack.Particles()
part2.p0c=2e10
part2.tau=1.e-4
part2.ptau=0.

print(part1.tau)
print(part2.tau)

part1.tau -> 0.0001

part2.tau -> 7.300582693553491e-05

@roman-martin
Copy link

Reasons this happens:

p0c.setter uses _update_ref() and _update_particles_from_absolute() which do not update rvv (and some other stuff like zeta),
then ptau uses the delta.setter, which does not update zeta.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants