A Pendulum by Dimensions
Q. A pendulum of length and bob of mass swings where gravity is . How does its period depend on what it is made of?
Inputs
Outputs
power of length0.5
power of gravity-0.5
power of mass0
period2.01 s
How it's solved
Solved with DimensionalAnalysis
Given
- from “assumed”
- , , yours to vary
Find , , , .
Working
- matching time
- matching length
- matching mass
- assumed
- period as powers
Conclusion
Only powers that make the dimensions match are allowed: x + y = 0 for length, −2y = 1 for time and z = 0 for mass. So T = k√(l ⁄ g). The mass drops out, and dimensions alone could never have told you that k is 2π.
The web of concepts
given read from the words equation asked
The Ruby that solves it
The question and its solution are small Ruby files. The engine runs them.
1require_relative "../physics"23question :pendulum_by_dimensions do4 describes "A pendulum of length %{length} and bob of mass %{mass} swings where gravity is %{gravity}. %{period}?"5 given :length6 given :gravity7 given :mass8 asks period: "How does its period depend on what it is made of"9end1require_relative "../questions/pendulum_by_dimensions"2require_relative "../science/units_and_measurement/dimensional_analysis"34solve :pendulum_by_dimensions, using: DimensionalAnalysis do5 take length: :l, gravity: :g, mass: :m6 assume k: 2 * pi7 find_value :x8 find_value :y9 find_value :z10 take period: :T11 find_value :period1213 conclusion "Only powers that make the dimensions match are allowed: x + y = 0 for length, " \14 "−2y = 1 for time and z = 0 for mass. So T = k√(l ⁄ g). The mass drops out, and " \15 "dimensions alone could never have told you that k is 2π."16endplayground.rb
1require_relative "../solutions/pendulum_by_dimensions"2require_relative "../science/motion_in_a_plane/gravity"34play_with :pendulum_by_dimensions do5 title "A Pendulum by Dimensions"67 input :l, 0.1..3.0, in: "m", step: 0.05, default: 1.0, as: "length"8 input :g, 1.0..25.0, step: 0.01, default: 9.81, marks: GRAVITY, as: "gravity"9 input :m, 0.1..10.0, step: 0.1, default: 1.0, as: "mass in kilograms"1011 output :x, as: "power of length"12 output :y, as: "power of gravity"13 output :z, as: "power of mass"14 output :T, in: "s"15endThe laws it drew on
| quantity | written | units | within | from |
|---|---|---|---|---|
| pi | — | 0 … ∞ | DimensionalAnalysis | |
| speed of light | m/s | — | DimensionalAnalysis | |
| length | m | — | DimensionalAnalysis | |
| gravity | m/s² | — | DimensionalAnalysis | |
| mass | kg | — | DimensionalAnalysis | |
| period | s | — | DimensionalAnalysis | |
| constant | — | — | DimensionalAnalysis | |
| power of length | — | — | DimensionalAnalysis | |
| power of gravity | — | — | DimensionalAnalysis | |
| power of mass | — | — | DimensionalAnalysis | |
| speed | m/s | 0 … ∞ | DimensionalAnalysis | |
| height | m | — | DimensionalAnalysis | |
| time | s | 0 … ∞ | DimensionalAnalysis | |
| acceleration | m/s² | — | DimensionalAnalysis | |
| start | m | — | DimensionalAnalysis | |
| starting speed | m/s | — | DimensionalAnalysis | |
| distance | m | — | DimensionalAnalysis | |
| rest mass | kg | — | DimensionalAnalysis | |
| kinetic energy | J | — | DimensionalAnalysis |