Skip to content

Commit 9c006af

Browse files
authored
Refactor imports in solid_motor.py for clarity
1 parent 442ba76 commit 9c006af

File tree

1 file changed

+9
-12
lines changed

1 file changed

+9
-12
lines changed

rocketpy/motors/solid_motor.py

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,15 @@
77
from ..plots.solid_motor_plots import _SolidMotorPlots
88
from ..prints.solid_motor_prints import _SolidMotorPrints
99
from .motor import Motor
10-
11-
10+
from ..tools import (
11+
parallel_axis_theorem_I11,
12+
parallel_axis_theorem_I22,
13+
parallel_axis_theorem_I33,
14+
parallel_axis_theorem_I12,
15+
parallel_axis_theorem_I13,
16+
parallel_axis_theorem_I23,
17+
)
18+
from ..mathutils.vector_matrix import Vector
1219
class SolidMotor(Motor):
1320
"""Class to specify characteristics and useful operations for solid motors.
1421
@@ -378,16 +385,6 @@ class Function. Thrust units are Newtons.
378385
self.propellant_I_12_from_propellant_CM = self.propellant_I_12
379386
self.propellant_I_13_from_propellant_CM = self.propellant_I_13
380387
self.propellant_I_23_from_propellant_CM = self.propellant_I_23
381-
from ..tools import (
382-
parallel_axis_theorem_I11,
383-
parallel_axis_theorem_I22,
384-
parallel_axis_theorem_I33,
385-
parallel_axis_theorem_I12,
386-
parallel_axis_theorem_I13,
387-
parallel_axis_theorem_I23,
388-
)
389-
from ..mathutils.vector_matrix import Vector
390-
391388
propellant_com_func = self.center_of_propellant_mass
392389

393390
propellant_com_vector_func = Function(

0 commit comments

Comments
 (0)