Skip to content

Commit 754707e

Browse files
committed
BUG: Vector encoding breaks MonteCarlo export.
1 parent 054f893 commit 754707e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

rocketpy/mathutils/vector_matrix.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -418,6 +418,10 @@ def k():
418418
"""Returns the k vector, [0, 0, 1]."""
419419
return Vector([0, 0, 1])
420420

421+
def to_dict(self):
422+
"""Returns the vector as a JSON compatible element."""
423+
return list(self.components)
424+
421425

422426
class Matrix:
423427
"""Pure Python 3x3 Matrix class for simple matrix-matrix and matrix-vector

0 commit comments

Comments
 (0)