From 106e8ea70cbbec2af4b6a50427ae88f6b20f4b2d Mon Sep 17 00:00:00 2001 From: gwm17 Date: Fri, 31 Mar 2023 16:44:54 -0400 Subject: [PATCH] Fix bug in ReactionDialog where reaction angle was displayed in radians not degrees --- spspy/ui/ReactionDialog.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spspy/ui/ReactionDialog.py b/spspy/ui/ReactionDialog.py index 2d505d4..a5fde00 100644 --- a/spspy/ui/ReactionDialog.py +++ b/spspy/ui/ReactionDialog.py @@ -5,6 +5,7 @@ from PySide6.QtWidgets import QVBoxLayout, QFormLayout, QGroupBox from PySide6.QtWidgets import QSpinBox, QDoubleSpinBox, QComboBox from PySide6.QtWidgets import QDialog, QDialogButtonBox from PySide6.QtCore import Signal +from numpy import rad2deg MAXIMUM_NUCLEAR_Z: int = 110 MAXIMUM_NUCLEAR_A: int = 270 @@ -116,6 +117,6 @@ class ReactionDialog(QDialog): self.aeInput.setValue(rxn.params.ejectile.A) self.aeInput.setEnabled(False) self.bkeInput.setValue(rxn.params.beamEnergy) - self.thetaInput.setValue(rxn.params.spsAngle) + self.thetaInput.setValue(rad2deg(rxn.params.spsAngle)) self.bfieldInput.setValue(rxn.params.magneticField) \ No newline at end of file