play phryzby with physics

Across the Current

solved Vectors

Q. A motorboat heads north at 25 km/hA=25km/h through a current that flows at 10 km/hB=10km/h toward 60° east of southφ=120°. How fast does it actually move, in km/h?

A = 6.94B = 2.78R = ?φ = 120°
Inputs
A
25 km/h
B
10 km/h
Outputs
speedR?

How it's solved

Solved with Vectors

Given

  • A=25km/h
  • B=10km/h
  • φ=120° from “toward 60° east of south”

Find R.

Working
  1. A=25km/h=6.94444444m/s
  2. B=10km/h=2.77777778m/s
  3. law of cosinesR2=A2+B2+2⋅A⋅B⋅cos⁡φ
  4. R2=6.944444442+2.777777782+2⋅6.94444444⋅2.77777778⋅cos⁡120°
  5. R=21.79km/h
  6. R=6.05402631m/s=21.7944947km/h
  7. R≈21.8km/hto 3 significant figures
Conclusion

The boat's own velocity and the current's add as vectors, head to tail; the current partly opposes the boat, so the sum is less than either would suggest by adding their speeds.

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 :across_the_current do4  kind :numerical5  describes "A motorboat heads north at %{boat_speed} through a current that flows at %{current_speed} toward 60° east of south. %{speed}, in km/h?"6  given boat_speed: "25 km/h"7  given current_speed: "10 km/h"8  asks speed: "How fast does it actually move"9end
solution.rb
1require_relative "../questions/across_the_current"2require_relative "../science/motion_in_a_plane/vectors"34solve :across_the_current, using: Vectors do5  take boat_speed: :A, current_speed: :B6  deduce_from "toward 60° east of south", phi: "120 deg"7  take speed: :R8  answer find_value(:speed, in: "km/h", figures: 3)910  conclusion "The boat's own velocity and the current's add as vectors, head to tail; the current " \11             "partly opposes the boat, so the sum is less than either would suggest by adding " \12             "their speeds."13end
playground.rb
1require_relative "../solutions/across_the_current"23play_with :across_the_current do4  title "Across the Current"5end
The laws it drew on
quantitywrittenunitswithinfrom
volumevolume——Vectors
massmass——Vectors
speedspeed——Vectors
densitydensity——Vectors
number of molesn——Vectors
angular frequencyangularfrequency——Vectors
workwork——Vectors
currentcurrent——Vectors
temperaturetemperature——Vectors
pressurepressure——Vectors
timetime——Vectors
powerpower——Vectors
total path lengths——Vectors
energyenergy——Vectors
gravitational potentialgravitationalpotential——Vectors
coefficient of frictionμ——Vectors
chargecharge——Vectors
accelerationacceleration——Vectors
velocityvelocity——Vectors
displacementdisplacement——Vectors
angular velocityangularvelocity——Vectors
forceforce——Vectors
angular momentumangularmomentum——Vectors
linear momentumplin——Vectors
electric fieldelectricfield——Vectors
average velocityaveragevelocity——Vectors
magnetic momentmagneticmoment——Vectors
relative velocityvAB——Vectors
impulseimpulse——Vectors
first vectorA—0 … ∞Vectors
second vectorB—0 … ∞Vectors
angle betweenφ—0 … 3.142Vectors
resultantR—0 … ∞Vectors
resultant directionβ—0 … 3.142Vectors
directionα—-3.142 … 3.142Vectors
x componentAx——Vectors
y componentAy——Vectors
A=Ax2+Ay2
magnitude from components
R2=A2+B2+2⋅A⋅B⋅cos⁡φ
law of cosines
R⋅sin⁡β=B⋅sin⁡φ
law of sines
R⋅cos⁡β=A+B⋅cos⁡φ
along the first
Ax=A⋅cos⁡α
resolved along x
Ay=A⋅sin⁡α
resolved along y