play phryzby with physics

Two Sitar Strings

solved Beats

Q. Two sitar strings A and B playing the note 'Dha' are slightly out of tune and produce beats of frequency 5 Hzνbeat,ab=5Hz. The tension of the string B is slightly increased and the beat frequency is found to decrease to 3 Hzνbeat,at=3Hz. What is the original frequency of B if the frequency of A is 427 Hzνa=427Hz, in hertz?

beats = 5 Hzf_a = 427 Hzf_b = ?
Inputs
νbeat,ab
5 Hz
νbeat,at
3 Hz
νa
427 Hz
Outputs
frequencyνb?

How it's solved

Solved with Beats

Given

  • νa=427Hz
  • νbeat,ab=5Hz
  • νbeat,at=3Hz

Find νb.

Working
  1. beats of two sounds(a, b)νbeat,ab=νa-νb
  2. 5=427-νb
  3. νb=422Hz
Conclusion

Tightening B raises its frequency; since the beats then slow down, B was moving towards A from below, so A beats against B from above.

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.

question.rb
1require_relative "../physics"23question :two_sitar_strings do4  kind :numerical5  describes "Two sitar strings A and B playing the note 'Dha' are slightly out of tune and produce beats of frequency " \6            "%{beats}. The tension of the string B is slightly increased and the beat frequency is found to decrease " \7            "to %{fewer_beats}. %{frequency} if the frequency of A is %{frequency_a}, in hertz?"8  given beats: "5 Hz"9  given fewer_beats: "3 Hz"10  given frequency_a: "427 Hz"11  asks frequency: "What is the original frequency of B"12end
solution.rb
1require_relative "../questions/two_sitar_strings"2require_relative "../science/waves/beats"34solve :two_sitar_strings, using: Beats do5  objects :a, :b, :tightened_b67  take frequency_a: a.frequency8  take beats: a.beat_frequency(by: b)9  take fewer_beats: a.beat_frequency(by: tightened_b)1011  frequency = b.frequency12  answer frequency:, in: "Hz"1314  conclusion "Tightening B raises its frequency; since the beats then slow down, B was moving towards A " \15             "from below, so A beats against B from above."16end
playground.rb
1require_relative "../solutions/two_sitar_strings"23play_with :two_sitar_strings do4  title "Two Sitar Strings"5end
The laws it drew on
quantitywrittenunitswithinfrom
frequencyνHz0 … ∞Beats
beat frequencyνbeatHz—Beats
beat frequency of ground by aνbeat,gaHz—
frequency of groundνgHz0 … ∞
frequency of aνaHz0 … ∞
beat frequency of ground by bνbeat,gbHz—
frequency of bνbHz0 … ∞
beat frequency of ground by tightened bνbeat,gtHz—
frequency of tightened bνtHz0 … ∞
beat frequency of a by groundνbeat,agHz—
beat frequency of a by bνbeat,abHz—
beat frequency of a by tightened bνbeat,atHz—
beat frequency of b by groundνbeat,bgHz—
beat frequency of b by aνbeat,baHz—
beat frequency of b by tightened bνbeat,btHz—
beat frequency of tightened b by groundνbeat,tgHz—
beat frequency of tightened b by aνbeat,taHz—
beat frequency of tightened b by bνbeat,tbHz—
νbeat,oo=νo-νo
beats of two sounds
νbeat,ga=νg-νa
beats of two sounds(ground, a)
νbeat,gb=νg-νb
beats of two sounds(ground, b)
νbeat,gt=νg-νt
beats of two sounds(ground, tightened b)
νbeat,ag=νa-νg
beats of two sounds(a, ground)
νbeat,ab=νa-νb
beats of two sounds(a, b)
νbeat,at=νa-νt
beats of two sounds(a, tightened b)
νbeat,bg=νb-νg
beats of two sounds(b, ground)
νbeat,ba=νb-νa
beats of two sounds(b, a)
νbeat,bt=νb-νt
beats of two sounds(b, tightened b)
νbeat,tg=νt-νg
beats of two sounds(tightened b, ground)
νbeat,ta=νt-νa
beats of two sounds(tightened b, a)
νbeat,tb=νt-νb
beats of two sounds(tightened b, b)