// Numbas version: exam_results_page_options {"name": "Balancing heating in materials + wavelength", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"preamble": {"css": "", "js": ""}, "parts": [{"prompt": "

Calculate the total heat absorbed by the water through this process, in kJ, to three significant figures.

", "variableReplacementStrategy": "originalfirst", "allowFractions": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerFraction": false, "type": "numberentry", "maxValue": "siground(Q_water_kj,3)+siground(abs(Q_water_kj/100),3)", "marks": "1", "scripts": {}, "minValue": "siground(Q_water_kj,3)-siground(abs(Q_water_kj/100),3)", "variableReplacements": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}, {"prompt": "

Calculate the change in temperature of the {Mat_string} in the water, to three significant figures.

", "variableReplacementStrategy": "originalfirst", "allowFractions": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerFraction": false, "type": "numberentry", "maxValue": "siground(d_temp2,3)+siground(abs(d_temp2/100),3)", "marks": "2", "scripts": {}, "minValue": "siground(d_temp2,3)-siground(abs(d_temp2/100),3)", "variableReplacements": [{"variable": "q_water", "must_go_first": true, "part": "p0"}], "showCorrectAnswer": true, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}, {"prompt": "

Assuming the {Mat_string} is a perfect blackbody, what was the peak wavelength of emission for the {Mat_string} when it was fully heated in the flame, in microns (μm), to three significant figures. Assume Wien's displacement constant k<sub>W</sub> = {kw} μmK.

", "variableReplacementStrategy": "originalfirst", "allowFractions": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerFraction": false, "type": "numberentry", "maxValue": "siground(wavelength,3)+siground(abs(wavelength/100),3)", "marks": "2", "scripts": {}, "minValue": "siground(wavelength,3)-siground(abs(wavelength/100),3)", "variableReplacements": [{"variable": "d_temp2", "must_go_first": true, "part": "p1"}], "showCorrectAnswer": true, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}], "variables": {"water_heatcap": {"description": "", "group": "Material values", "definition": "4200", "templateType": "anything", "name": "water_heatcap"}, "phase1_temp": {"description": "", "group": "Material values", "definition": "fusion_temp_list[wat_mat]", "templateType": "anything", "name": "phase1_temp"}, "wavelength": {"description": "", "group": "Q values", "definition": "kw/temp2", "templateType": "anything", "name": "wavelength"}, "mass_string": {"description": "", "group": "kg or g", "definition": "if(mass<1,dpformat(mass*1000,0)+' g',dpformat(mass,2)+' kg')", "templateType": "anything", "name": "mass_string"}, "mat_string": {"description": "", "group": "Material values", "definition": "material_list[wat_mat]", "templateType": "anything", "name": "mat_string"}, "temp1": {"description": "", "group": "Random variables", "definition": "temp0+random(1.0..10.0#0.1)", "templateType": "anything", "name": "temp1"}, "mass2": {"description": "", "group": "Random variables", "definition": "random(2.0..9.9#0.1)", "templateType": "anything", "name": "mass2"}, "solid_hc_list": {"description": "", "group": "Lists of values", "definition": "[240,900,450,390,130]", "templateType": "anything", "name": "solid_hc_list"}, "mass": {"description": "", "group": "Random variables", "definition": "random(0.01..0.99#0.01)", "templateType": "anything", "name": "mass"}, "mass2_string": {"description": "", "group": "kg or g", "definition": "if(mass2<1,dpformat(mass2*1000,0)+' g',dpformat(mass2,2)+' kg')", "templateType": "anything", "name": "mass2_string"}, "temp0": {"description": "", "group": "Random variables", "definition": "random(1.0..40.0#0.1)", "templateType": "anything", "name": "temp0"}, "material_list": {"description": "", "group": "Lists of values", "definition": "['Silver','Aluminium','Iron','Copper','Gold']", "templateType": "anything", "name": "material_list"}, "d_temp2": {"description": "", "group": "Q values", "definition": "Q_water_kj*(-1000)/(mass*solid_heatcap)", "templateType": "anything", "name": "d_temp2"}, "solid_heatcap": {"description": "", "group": "Material values", "definition": "solid_hc_list[wat_mat]", "templateType": "anything", "name": "solid_heatcap"}, "wat_mat": {"description": "", "group": "Random variables", "definition": "random(0..4)", "templateType": "anything", "name": "wat_mat"}, "temp2": {"description": "", "group": "Q values", "definition": "temp1+273.15-d_temp2", "templateType": "anything", "name": "temp2"}, "kw": {"description": "", "group": "Q values", "definition": "2898", "templateType": "anything", "name": "kw"}, "fusion_temp_list": {"description": "", "group": "Lists of values", "definition": "[1235,933,1811,1357,1337]", "templateType": "anything", "name": "fusion_temp_list"}, "Q_water": {"description": "", "group": "Q values", "definition": "mass2*water_heatcap*(temp1-temp0)", "templateType": "anything", "name": "Q_water"}, "Q_water_kj": {"description": "", "group": "Q values", "definition": "Q_water/1000", "templateType": "anything", "name": "Q_water_kj"}}, "ungrouped_variables": [], "statement": "

\n

A room is in complete thermal equilibrium at {temp0} °C. A {mass_string} lump of {Mat_string} is heated in a flame for several minutes. The {Mat_string} is then transferred quickly into {mass2_string} of water, and the water and {Mat_string} both reach {temp1} °C. 

\n

\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Solid {Mat_string}Liquid water
Specific heat capacity{solid_heatcap} JK<sup>-1</sup>kg<sup>-1</sup>{water_heatcap} JK<sup>-1</sup>kg<sup>-1</sup>
", "rulesets": {}, "variablesTest": {"maxRuns": 100, "condition": "temp2 < phase1_temp"}, "extensions": ["jsxgraph"], "functions": {"onestep": {"language": "javascript", "type": "html", "parameters": [], "definition": "// Takes variables\n\n// showing K or C?\nk_c = Numbas.jme.unwrapValue(scope.variables.k_c_switch);\n\nif (k_c = 0) {\n var k_c_corr =0;\n var k_c_str=\"K\";\n} else {\n var k_c_corr =-273;\n var k_c_str=\"\u00b0C\";\n}\n\n//Set values\nst = Numbas.jme.unwrapValue(scope.variables.start_temp)+k_c_corr;\net = Numbas.jme.unwrapValue(scope.variables.end_temp)+k_c_corr;\npt = Numbas.jme.unwrapValue(scope.variables.phase_temp)+k_c_corr;\n\n\n// The function provided by the JSXGraph extension wraps the board up in\n// a div tag so that it's easier to embed in the page.\nvar div = Numbas.extensions.jsxgraph.makeBoard('500px','300px',\n {boundingBox: [-4,et+10,20,st-10],\n axis: false,\n showNavigation: false,\n grid: false\n });\n\n// div.board is the object created by JSXGraph, which you use to\n// manipulate elements\nvar board = div.board;\n\n\n\n// create the x-axis.\n//var xaxis = board.create('line',[[0,0],[1,0]], {strokeColor: 'black', fixed: true});\n//var xticks = board.create('ticks',[xaxis,20],{\n// drawLabels: true,\n// minorTicks: 0\n//});\n\n// create the y-axis\nvar yaxis = board.create('line',[[0,0],[0,1]], { strokeColor: 'black', fixed: true });\nvar yticks = board.create('ticks',[yaxis,parseInt((et-st)/50.)*10],{\ndrawZero:true,\ndrawLabels: true,\nlabel: {offset: [20, 0]},\nminorTicks: 0\n});\n\n//\n//slope 1\nvar slope1 = board.create('line',[[4,st],[((pt-st)/((pt-st)+(et-pt))*8)+4,pt]], {straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar slope2 = board.create('line',[[((pt-st)/((pt-st)+(et-pt))*8)+4,pt],[16-((et-pt)/((pt-st)+(et-pt))*8),pt]], {straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar slope3 = board.create('line',[[16-((et-pt)/((pt-st)+(et-pt))*8),pt],[16,et]], {straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\n\nvar dash1 = board.create('line',[[((pt-st)/((pt-st)+(et-pt))*8)+4,st-5],[((pt-st)/((pt-st)+(et-pt))*8)+4,et+5]], {dash:2, strokewidth:1, straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar dash2 = board.create('line',[[16-((et-pt)/((pt-st)+(et-pt))*8),st-5],[16-((et-pt)/((pt-st)+(et-pt))*8),et+5]], {dash:2, strokewidth:1, straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\n\n\n//label the y-axis\n var label = board.create('text',[-2,(et+st)/2,k_c_str]);\n\n\n// and return the container div\nreturn div;"}, "twostep": {"language": "javascript", "type": "html", "parameters": [], "definition": "// Takes variables\n\n// showing K or C?\nk_c = Numbas.jme.unwrapValue(scope.variables.k_c_switch);\n\nif (k_c = 0) {\n var k_c_corr =0;\n var k_c_str=\"K\";\n} else {\n var k_c_corr =-273;\n var k_c_str=\"\u00b0C\";\n}\n\n//Set values\nst = Numbas.jme.unwrapValue(scope.variables.start_temp)+k_c_corr;\net = Numbas.jme.unwrapValue(scope.variables.end_temp)+k_c_corr;\npt1 = Numbas.jme.unwrapValue(scope.variables.phase1_temp)+k_c_corr;\npt2 = Numbas.jme.unwrapValue(scope.variables.phase2_temp)+k_c_corr;\n\n\n// The function provided by the JSXGraph extension wraps the board up in\n// a div tag so that it's easier to embed in the page.\nvar div = Numbas.extensions.jsxgraph.makeBoard('500px','300px',\n {boundingBox: [-5,et+(et-st)/10.,28,st-(et-st)/10.],\n axis: false,\n showNavigation: false,\n grid: false\n });\n\n// div.board is the object created by JSXGraph, which you use to\n// manipulate elements\nvar board = div.board;\n\n\n\n// create the x-axis.\n//var xaxis = board.create('line',[[0,0],[1,0]], {strokeColor: 'black', fixed: true});\n//var xticks = board.create('ticks',[xaxis,20],{\n// drawLabels: true,\n// minorTicks: 0\n//});\n\n// create the y-axis\n\nvar yaxis = board.create('line',[[0,0],[0,1]], { strokeColor: 'black', fixed: true });\nvar yticks = board.create('ticks',[yaxis,parseInt((et-st)/50.)*10],{\ndrawZero:true,\ndrawLabels: true,\nlabel: {offset: [20, 0]},\nminorTicks: 0\n});\n\n\n// full size of the five slopes\nvar allslope=(et-st);\nvar s1sz=(8*(pt1-st)/allslope);\nvar s3sz=(8*(pt2-pt1)/allslope);\nvar s5sz=(8*(et-pt2)/allslope);\n\n\n//\n//slope 1\nvar slope1 = board.create('line',[[4,st],[s1sz+4,pt1]], {straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar slope2 = board.create('line',[[s1sz+4,pt1],[s1sz+8,pt1]], {straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar slope3 = board.create('line',[[s1sz+8,pt1],[s1sz+s3sz+8,pt2]], {straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar slope4 = board.create('line',[[s1sz+s3sz+8,pt2],[s1sz+s3sz+12,pt2]], {straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar slope5 = board.create('line',[[s1sz+s3sz+12,pt2],[s1sz+s3sz+s5sz+12,et]], {straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\n\n//var slope6 = board.create('line',[[4,pt1],[20,pt2]], {dash:2,straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\n\nvar dash1 = board.create('line',[[s1sz+4,st-10],[s1sz+4,et+10]], {dash:2, strokewidth:1, straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar dash2 = board.create('line',[[s1sz+8,st-10],[s1sz+8,et+10]], {dash:2, strokewidth:1, straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar dash3 = board.create('line',[[s1sz+s3sz+8,st-10],[s1sz+s3sz+8,et+10]], {dash:2, strokewidth:1, straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\nvar dash4 = board.create('line',[[s1sz+s3sz+12,st-10],[s1sz+s3sz+12,et+10]], {dash:2, strokewidth:1, straightFirst:false, straightLast:false, strokeColor: 'black', fixed: true });\n\n\n//label the y-axis\n var label = board.create('text',[-2,(et+st)/2,k_c_str]);\n\n\n// and return the container div\nreturn div;"}}, "advice": "

a)

\n

Q = m * C<sub>{'S'}</sub>  * ΔT

\n

Q = {mass2} * {water_heatcap} * ({temp1}-{temp0})

\n

Q = {siground(q_water,6)} J

\n

So the heat added to the water is {siground(q_water_kj,3)} kJ.

\n

b)

\n

The heat added to the water was taken from the {Mat_string}, so that

\n

Q<sub>{Mat_string}</sub> = -{siground(q_water_kj,3)} kJ.

\n

Q<sub>{Mat_string}</sub> = m * C<sub>{Mat_string}</sub> * ΔT

\n

so

\n

ΔT = Q<sub>{Mat_string}</sub>/(m * C<sub>{Mat_string}</sub>)

\n

ΔT = -{siground(q_water,3)}/({mass} * {solid_heatcap})

\n

ΔT ={siground(d_temp2,3)} K

\n

c)

\n

Firstly, calculate the initial temperature of the {Mat_string} in K:

\n

T = {siground(d_temp2*(-1),3)} + {temp0} + 273.15 = {siground(temp2,3)} K

\n

Then calculate the wavelength:

\n

Wavelength = K<sub>W</sub> / T = {kw} /{siground(temp2,3)}

\n

So the {mat_string} was glowing with a peak at {siground(wavelength,3)} μm.

", "name": "Balancing heating in materials + wavelength", "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "

A random heating question, that randomly picks a material, and then heats it through either one or two phase changes, provides an example graph of the heating with scaled temperature ranges (though not with scaled latent and specific heats), and a table with the suitable constants.

"}, "tags": [], "variable_groups": [{"variables": ["mass_string", "mass2_string"], "name": "kg or g"}, {"variables": ["mat_string", "phase1_temp", "solid_heatcap", "water_heatcap"], "name": "Material values"}, {"variables": ["material_list", "solid_hc_list", "fusion_temp_list"], "name": "Lists of values"}, {"variables": ["wat_mat", "temp0", "temp1", "mass", "mass2"], "name": "Random variables"}, {"variables": ["Q_water", "Q_water_kj", "d_temp2", "temp2", "wavelength", "kw"], "name": "Q values"}], "type": "question", "contributors": [{"name": "Tom Stallard", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/841/"}]}]}], "contributors": [{"name": "Tom Stallard", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/841/"}]}