// Numbas version: exam_results_page_options {"name": "CA1 Straight Line Graphs", "extensions": ["geogebra"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "CA1 Straight Line Graphs", "tags": [], "metadata": {"description": "

Calculating gradient and finding intercept from a geogebra graph.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

{app}
Find the gradient of the line.


", "advice": "

Firstly draw a right angled 'step' from left to right. This triangle can be anywhere, but it is more helpful for it to have corners on the vertices (whole number points) of the graph and it is easier to calculate with postive numbers.

\n

{app_advice}

\n

Before we start to calculate, notice that the line is {uod}, so the gradient will be {pon} and the line is {sos}, so the absolute value of the number will be {mol}.

Now find the coordinates of the places your triangle meets the line

\n

$(x_1,y_1)=(\\var{ax},\\var{ay})$ and $(x_2,y_2)=(\\var{bx},\\var{by})$

\n

We need to compare the 'rise on the y-axis' to the 'run across the x-axis', we can say that:

\n

$\\text{gradient} = \\frac{\\text{rise}}{\\text{run}}$

\n

This is equivalent to using the formula:

$  m = \\frac{y_2 - y_1}{x_2 - x_1} $

\n

and substitute the coordinates of the vertices of the triangle:

$\\begin{split} &\\, m = \\frac{\\var{by} - \\var{ay}}{\\var{bx} - \\var{ax}} \\\\  
&\\, = \\frac{\\var{by-ay}}{\\var{bx-ax}} \\\\ 
&\\,  = \\var[fractionNumbers]{m} \\\\
\\end{split} $

\n

Use this link to find resources to help you revise straight line graphs and how to find the gradient of them.

", "rulesets": {}, "extensions": ["geogebra"], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"app": {"name": "app", "group": "Ungrouped variables", "definition": "geogebra_applet(\n 800,500,\n [\n A: [\n definition: p1,\n label_visible: false,\n visible: false\n ],\n B: [\n definition: p2,\n label_visible: false,\n visible: false \n ],\n line: [\n definition: \"Line(A,B)\",\n label_visible: false\n ]\n ]\n)", "description": "", "templateType": "anything", "can_override": false}, "m": {"name": "m", "group": "Ungrouped variables", "definition": "(ay-by)/(ax-bx)", "description": "", "templateType": "anything", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "ay-m*ax", "description": "", "templateType": "anything", "can_override": false}, "P1": {"name": "P1", "group": "Ungrouped variables", "definition": "vector(ax, ay)", "description": "", "templateType": "anything", "can_override": false}, "P2": {"name": "P2", "group": "Ungrouped variables", "definition": "vector(bx,by)", "description": "", "templateType": "anything", "can_override": false}, "uod": {"name": "uod", "group": "Ungrouped variables", "definition": "if(m=0,'horizontal',if(m=abs(m),'going up','going down'))", "description": "

if(m=abs(m),'positive','negative')

", "templateType": "anything", "can_override": false}, "ax": {"name": "ax", "group": "Ungrouped variables", "definition": "random(0,1)", "description": "", "templateType": "anything", "can_override": false}, "ay": {"name": "ay", "group": "Ungrouped variables", "definition": "random(0,1,2,3)", "description": "", "templateType": "anything", "can_override": false}, "bx": {"name": "bx", "group": "Ungrouped variables", "definition": "random(ax+1..3) \n", "description": "", "templateType": "anything", "can_override": false}, "by": {"name": "by", "group": "Ungrouped variables", "definition": "random(0..4 except ay)\n", "description": "", "templateType": "anything", "can_override": false}, "app_advice": {"name": "app_advice", "group": "Ungrouped variables", "definition": "geogebra_applet(\n 800,500,\n [\n A: [\n definition: p1,\n label_visible: false,\n visible: true\n ],\n B: [\n definition: p2,\n label_visible: false,\n visible: true \n ],\n \n C: [\n definition: p3,\n label_visible: false,\n visible: false \n ],\n \n line1: [\n definition: \"Line(A,B)\",\n label_visible: false,\n visible: true\n ],\n \n line2: [\n definition: \"Segment(A,C)\",\n label_visible: false,\n visible: true\n ],\n \n \n \n line3: [\n definition: \"Segment(C,B)\",\n label_visible: false,\n visible: true\n ]\n ]\n)", "description": "", "templateType": "anything", "can_override": false}, "p3": {"name": "p3", "group": "Ungrouped variables", "definition": "vector(bx,ay)", "description": "", "templateType": "anything", "can_override": false}, "pon": {"name": "pon", "group": "Ungrouped variables", "definition": "if(m=0,'zero',if(m=abs(m),'a positive number','a negative number'))", "description": "", "templateType": "anything", "can_override": false}, "sos": {"name": "sos", "group": "Ungrouped variables", "definition": "if(m=0,'horizontal',if(abs(m)<1,'shallow','steep'))", "description": "", "templateType": "anything", "can_override": false}, "mol": {"name": "mol", "group": "Ungrouped variables", "definition": "if(m=0,'zero',if(abs(m)<1,'less than 1','greater than or equal to 1'))", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "m<>1", "maxRuns": 100}, "ungrouped_variables": ["app", "m", "c", "P1", "P2", "uod", "ax", "ay", "bx", "by", "app_advice", "p3", "pon", "sos", "mol"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "alternatives": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "alternativeFeedbackMessage": "

It looks like you have incorrectly rounded this answer.  You might want to look at some resources on rounded decimals.  You can also leave your answer in fraction form as
$\\var[fractionNumbers]{m}$

", "useAlternativeFeedback": false, "answer": "{m}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": "0.1", "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}], "answer": "{m}", "showPreview": true, "checkingType": "dp", "checkingAccuracy": "1", "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Megan Oliver", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23526/"}]}]}], "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Will Morgan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/21933/"}, {"name": "Megan Oliver", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/23526/"}]}