math_helpers
utils.math_helpers
Math helpers for Blueprints.
utils.math_helpers.angle_to_slope
angle_to_slope(angle: DEG) -> PERCENTAGE
Convert an angle in degrees to a slope (as a percentage).
Parameters:
-
angle(DEG) –Angle in degrees.
Returns:
-
PERCENTAGE–Slope as a percentage.
Source code in blueprints/utils/math_helpers.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 | |
utils.math_helpers.cot
cot(x: DEG) -> DIMENSIONLESS
Calculate the cotangent of an angle in degrees.
Parameters:
-
x(DEG) –Angle in degrees.
Returns:
-
DIMENSIONLESS–Cotangent of the angle.
Source code in blueprints/utils/math_helpers.py
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | |
utils.math_helpers.csc
csc(x: DEG) -> DIMENSIONLESS
Calculate the cosecant of an angle in degrees.
Parameters:
-
x(DEG) –Angle in degrees.
Returns:
-
DIMENSIONLESS–Cosecant of the angle.
Source code in blueprints/utils/math_helpers.py
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | |
utils.math_helpers.sec
sec(x: DEG) -> DIMENSIONLESS
Calculate the secant of an angle in degrees.
Parameters:
-
x(DEG) –Angle in degrees.
Returns:
-
DIMENSIONLESS–Secant of the angle.
Source code in blueprints/utils/math_helpers.py
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 | |
utils.math_helpers.slope_to_angle
slope_to_angle(slope: PERCENTAGE) -> DEG
Convert a slope (as a percentage) to an angle in degrees.
Parameters:
-
slope(PERCENTAGE) –Slope as a percentage.
Returns:
-
DEG–Angle in degrees.
Source code in blueprints/utils/math_helpers.py
63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |