Skip to content

Commit

Permalink
Merge pull request #122 from MarinDeniaud/definesPosition
Browse files Browse the repository at this point in the history
gdml : fixed position upgradeToVector
  • Loading branch information
stewartboogert authored Nov 4, 2023
2 parents 2005e2a + 563115e commit d41f6b9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/pyg4ometry/gdml/Defines.py
Original file line number Diff line number Diff line change
Expand Up @@ -749,6 +749,8 @@ def __repr__(self):
)

def __add__(self, other):
other = upgradeToVector(other, self.registry, "position", "", False)

p = Position(
f"vec_{self.name}_add_{other.name}",
f"({self.x.expressionString})+({other.x.expressionString})",
Expand Down

0 comments on commit d41f6b9

Please sign in to comment.