Skip to content

Corrections for PlasmaLinac.assemble_trackables() that calculates the linac nominal energy from the nominal energy gains of each plasma stage#174

Merged
ben-c-2013 merged 5 commits intomainfrom
PlasmaLinac_nominal_energy_correction
Dec 19, 2025
Merged

Corrections for PlasmaLinac.assemble_trackables() that calculates the linac nominal energy from the nominal energy gains of each plasma stage#174
ben-c-2013 merged 5 commits intomainfrom
PlasmaLinac_nominal_energy_correction

Conversation

@ben-c-2013
Copy link
Collaborator

No description provided.

… linac nominal energy from the nominal energy gains of each plasma stage.
@ben-c-2013 ben-c-2013 requested a review from kyrsjo December 1, 2025 16:40
@ben-c-2013 ben-c-2013 added the bug Something isn't working label Dec 1, 2025
@kyrsjo
Copy link
Collaborator

kyrsjo commented Dec 19, 2025

Finally I understand, the only real change here is removing

if self.nom_energy is None:
            if self.stage is not None:
                self.nom_energy = self.source.energy + self.num_stages * self.stage.nom_energy_gain
            else:
                self.nom_energy = self.source.energy

And doing the prints per-stage (however the prints of upramp/downramp is conflicting with #182).

Merge #182 first, then merge back here and fix here. Then OK to merge.

@ben-c-2013
Copy link
Collaborator Author

Finally I understand, the only real change here is removing

if self.nom_energy is None:
            if self.stage is not None:
                self.nom_energy = self.source.energy + self.num_stages * self.stage.nom_energy_gain
            else:
                self.nom_energy = self.source.energy

And doing the prints per-stage (however the prints of upramp/downramp is conflicting with #182).

Merge #182 first, then merge back here and fix here. Then OK to merge.

Done in commit b90a61c.

@ben-c-2013 ben-c-2013 merged commit 205e23e into main Dec 19, 2025
1 check passed
@ben-c-2013 ben-c-2013 deleted the PlasmaLinac_nominal_energy_correction branch December 19, 2025 15:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants