question.rb
solution.rb
playground.rb
1 require_relative "../physics" 2 3 question :argon_as_fast_as_cold_helium do 4 kind :numerical 5 describes "The atomic mass of Ar is %{argon} and of He is %{helium}. %{temperature} of an atom in an argon gas " \ 6 "cylinder equal to the rms speed of a helium gas atom at – 20 °C, in kelvin?" 7 given argon: "39.9 g/mol" 8 given helium: "4.0 g/mol" 9 asks temperature: "At what temperature is the root mean square speed" 10 end
1 require_relative "../questions/argon_as_fast_as_cold_helium" 2 require_relative "../science/kinetic_theory/rms_speed" 3 4 solve :argon_as_fast_as_cold_helium , using: RmsSpeed do 5 objects :argon , :helium 6 7 take argon: argon . molar_mass 8 take helium: helium . molar_mass 9 10 deduce_from "a helium gas atom at – 20 °C" , helium . temperature => "253 K" 11 deduce_from "equal to the rms speed" , helium . rms_speed => argon . rms_speed 12 13 temperature = argon . temperature 14 answer temperature :, in: "K" , figures: 3 15 16 conclusion "The rms speed goes as the square root of the temperature over the molar mass, so the heavier argon " \ 17 "must be hotter in the same proportion as it is heavier." 18 end
1 require_relative "../solutions/argon_as_fast_as_cold_helium" 2 3 play_with :argon_as_fast_as_cold_helium do 4 title "Argon as Fast as Cold Helium" 5 end