You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: physics/hookes_law.py
+6-8Lines changed: 6 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,4 @@
1
-
#Hookes Law
1
+
#Hookes Law
2
2
"""
3
3
Hookes Law states that the Force is directly proportional to the extension or compression of an elastic object, provided the limit of proportionality is not exceeded.
4
4
@@ -14,7 +14,8 @@
14
14
15
15
"""
16
16
17
-
defhookes_law(k:float, x:float) ->float:
17
+
18
+
defhookes_law(k: float, x: float) ->float:
18
19
"""
19
20
Calculate the Hookes law from the given values of spring constant 'k'
20
21
and the displacement 'x' from the equilibrium position.
0 commit comments