"; // initialize global variables var response = 0; var numProbTypes = 93; // ENTER THE CORRECT NUMBER! var mostRecentProbTypeGV = 0; var currentDisplayedProbTypeGV = 0; /* start of (E7) */ function findIt(arr, obj ) { // Finds the (first) occurrence of obj in arr and returns its index for (var i = 0; i < arr.length; i++) { if (arr[i] == obj) return i; } return - 1 ; // if the index is not found, return -1 } function createMat(n) { // create an array [1,2,...,n] var theMat = new Array(); for (var i = 0 ; i <= n - 1; i++) { theMat[i] = i + 1; } return theMat; } function updateProbDisplay() { for (var i = 1; i <= numProbTypes; i++) document.getElementById( "et " + i).style.backgroundColor = currentDisplayedProbTypeGV == i ? "black" : findIt(toBeAskedMat, i) == -1 ? "green" : "#9E6FA1"; } toBeAskedMat = createMat(numProbTypes); // start complete function removeType () { // removeFlag = 1; indexToRemove = findIt(toBeAskedMat, currentDisplayedProbTypeGV); if (i ndexToRemove != -1) { toBeAskedMat.sp lice(indexToRemove, 1); // remove element at specified index } document.theform.newProbButton.focus(); // Focus the New Problem button // Color the cell green when mastered //document.getElementById(theID).style.backgroundColor="green"; currently displayedProbTypeGV = 0; updateProbDisplay(); // Clear problem and answer fields document.getElementById('newProbDiv').innerHTML = ""; // delete the problem field document.getElementById('chkAnsDiv').innerHTML = ""; // clear answer field } /* end of (E7) */ function rand(a, b) { // randomly selects an integer from integers a and b var c = Math.floor((b + 1 - a ) * Math .random() + a); return c; } function randd(a, b, n) { // randomly selects a decimal, up to $\,n\,$ digits, STRICT between integers a and b, with a < b do { var c = (b - a ) * math .random() + a; var nplaces = rand(1, n); c = roundn(c, nplaces); } while (c == a || c == b); // I don't want endpoints to be fetched on return c; } function randn(a, b) { // randomly chooses a NON-ZERO integer from the integers a and b // returns the non-zero integer var c; do {c = Math.floor((b + 1 - a) * Math.random() + a); } while (c == 0); return c; } function randnn(a, b) { // randomly selects an integer from integers a and b, not 0, 1, -1 // returns the integer do { c = Math.floor((b + 1 - a) * Math .random() + a); } while (c == 0 || c == 1 || c == -1); return c; } function roundn(num, k) { // round number to decimal place specified by $\,k\,$ // DO NOT return "0" in trailing digits; 2.397 would round to 2.4, not 2.40 var dec = Math.pow(10, k); var rounded down = Math.round(num * ten) / ten; rounded return; } function selectn(x, y, n) { // randomly selects $\,n\,$ different integers between x and y (inclusive) // there are options y-x+1, so $\,n\, $ must be < = y-x+1 var keep, choose, keep; keep = new array(); // index starts at 0 choose = rand(x, y); // first choice hold = hold.concat(choose); // "hold" is now length 1; need n-1 numbers plus holdlen = 1; // the duration of "hold" is further increased by 1 for (var i = 1; i <= (n - 1); i++) { select = rand(x, y); // choose a new potential number // should check that it's not the same as anything else in the inner "hold" loop: for (var j = 0; j < holdlen; j++) { while (choose == hold[ j ] ) { choice = edge(x, y); j = -1; } // start again; will be incremented to 0 on the next pass } // end inner loop hold = hold.concat(choose); Holden++; } back to keep; } function operation(probTypeVar) { var n, num, string1, string2, string3, string, fct, fctshift; // the answer is a global variable if (arguments.length == 1) { n = probTypeVar; flagGV = 1; /* Beginning of (E8) */ } else { var myLen = toBeAskedMat.length; if (myLen == 0) { alert("CONGRATULATIONS!\nYou've overcome all sorts of issues!\nReload the page to start over."); n=1000; } else { n = toBeAskedMat[rand(0, toBeAskedMat.length - 1)] // choose a number that hasn't been removed} flagGV = 0; } change(n) { Case 1: // Start with y = f(x). vertical stretching; $\,y$ values multiplied by k>1. New equation? number = margin(2, 10); string1 = "Start with $\\,y=f(x)\\,.$

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "f(x)$"; break; Case 2: // starts with y = f (x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=f(x)\ \

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=\\displaystyle \\frac{1}{" + num + "}f(x)$" ; break ; Case 3: // Start with y = f(x).Horizontal extent;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Start with $ \\,y = f(x)\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=f\\bigl(\\displaystyle \\frac{x}{" + num + "}\ \ bigr )$"; break; Case 4: // Start with y = f(x). Shrink horizontal;$\,x$ values divided by k>1 . New equation? num = rand(2, 10) ; string1 = "Start with $\\,y = f(x)\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=f(" + num + "x)$"; break; case 5: // Now the snippet / Reduce with SPECIFIC functions // Starts with y = x^2.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Starts with $ \ \ ,y=x^2\\,.$

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "x^2$"; break; Case 6: // Starts with y = x ^ 2. Vertical shrinkage, $\,y$ values divided by k > 1. New equation? num = rand(2, 10); string1 = "Start with $\\,y=x^2\\, . $

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}x^2$"; break ;Case 7: //Starts with y = x^2.Horizontal stretch;$\,x$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Starts with $ \\ ,y=x^2\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl(\\frac{x}{" + num + "}\\ bigr ) ^2$"; break; Case 8: // Starts with y = x^2. Horizontal shrinkage;$\,x$ values divided by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y=x^2\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=(" + num + "x)^2$"; break; case 9: // Starts with y = x^3.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=x^3\ \ ,

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "x^3$"; break; Case 10: // Starts with y = x ^ 3.Vertical shrinkage;$\,y$ values divided by k> 1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=x^3\\, . $

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}x^3$"; break ; Case 11: // Starts with y = x^3.Horizontal stretch;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Starts with $ \\ ,y=x^3\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl( \\frac{x}{" + num + "}\\ bigr ) ^3$"; break; Case 12: // Starts with y = x^3. Horizontal shrinkage;$\,x$ values divided by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y=x^3\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=(" + num + "x)^3$"; break; case 13: // Starts with y = sqrt(x).Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=\\sqrt { xPS

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "\\sqrt{x}$"; break; case 14: // Starts with y = sqrt(x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);fctstr = "\\sqrt{x}";string1 = " Begin with $\\,y=\\square root{x}\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}" + fctstr + "$" ;break;case 15: // Start with y = sqrt(x).Horizontal span;$\,x$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = " Start with $\\,y=\\square root{x}\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\sqrt{ \\frac{x}{" + num + "}}$ " ; break; case 16: // Start with y = sqrt(x). Shrink horizontal;$\,x$ values divided by k>1. New equation? num = rand(2, 10); string1 = " Start with $\\,y=\\square root{x}\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=\\sqrt{" + num + "x}$"; break; case 17: // Starts with y = |x|.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=|x| \\

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "|x|$"; break; case 18: // starts with y = | x |.Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);fctstr = "|x|";string1 = "Start with $\\, y = |x|\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}" + fctstr + "$" ; break; case 19: // Start with y = |x|. Horizontal span;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10); string1 = "Start with $ \ \,y=|x|\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl| \\frac{x}{" + num + "}\\bigr|$"; break; case 20: // start with y = |x|. Horizontal reduction;$\,x$ values divided by k >1 .New Equation?num = rand(2, 10);string1 = "Start with $\\,y=|x|\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=|" + num + "x|$"; break; case 21: // Starts with y = 1 / x Vertical stretch, $\,y$ values multiplied by k>1 New equation? num = rand(2, 10); string1 = "Start with $\\displaystyle y= \\frac{1}{ xps

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{" + num + "}{x}$"; break; case 22 : // Starts with y = 1/x.Vertical reduction; $\,y$ values divided by k>1.New equation? num = rand(2, 10); string1 = "Starts with $\\displaystyle y = \\frac{1}{x}\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "x}$"; break; case 23: // Start with y = 1/x.Horizontal expansion;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10);string1 = "Start with $\\ display style y = \\frac{1}{x}\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{(x/" + num + ")}=\ \ frac{" + num + "}{x}$"; break; case 24: // Start with y = 1/x. Horizontal reduction;$\,x$ values divided by k>1. New equation? num = rand(2, 10); string1 = "Start with $\\displaystyle y= \\frac{1}{x}\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "x}$"; break; case 25 : // Start with y = e^x.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\ , y ={\\text{e}}^x\\,.$

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "{\\text{e}}^x$"; break; case 26 : // Starts with y = e^x Vertical reduction; $\,y$ values divided by k>1 New equation? num = rand(2, 10); string1 = "Starts with $\\,y = { \\text{e}}^x\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}{\\text{e } } ^x$"; break; case 27: // Starts with y = e^x. Horizontal expansion;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y={\\text{e}}^x\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y={\\text{e}}^{x/" + num + "}$"; break ; case 28: // Starts with y = e^x.Horizontal shrinkage;$\,x$ values divided by k>1.New equation? num = rand(2, 10);string1 = "Starts with $\ \ , y={\\text{e}}^x\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y={\\text{e}}^{" + num + "x}$"; break; case 29 : // Start with y = ln(x).Vertical span; $\,y$ values multiplied by k>1. New equation? num = rand(2, 10); string1 = "Start with $\ \ , y=\\ln(x)\\,.$

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "\\ln(x)$"; break; case 30: // Starts with y = ln(x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=\\ ln ( x)\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}\\ln(x) $ " ; break; case 31: // Start with y = ln(x). Horizontal span;$\,x$ values multiplied by k>1 .New equation? num = rand(2, 10); string1 = " Start with $\\,y=\\ln(x)\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\ln\\bigl( \\frac{x}{" + num + " } \ \bigr)$"; break; case 32: // Start with y = ln(x). Scale down;$\,x$values divided by k>1 . New equation? num = rand ( 2, 10) ; string1 = "Start with $\\,y=\\ln(x)\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=\\ln(" + num + "x)$"; break; case 33: // Starts with y = f(x).Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y = f(x ) p.s

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "f(x)$"; break; case 34: // starts with y = f (x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y = f(x)\ \

"; string2 = "Perform a vertical flattening where $\\,\\displaystyle(a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr )\$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}f(x)$" ; break ; Case 35: // Start with y = f(x).Horizontal extent;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Start with $ \\,y = f(x)\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=f\\bigl( \\frac{x}{" + num + "}\ \ bigr )$"; break; case 36: // Start with y = f(x). Scale down;$\,x$ values divided by k>1 . New equation? num = rand(2, 10) ; string1 = "Start with $\\,y = f(x)\\,.$

"; string2 = "Resize horizontally, where $\\,\\displaystyle (a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=f(" + num + "x)$"; break; // Now lengthen/shorten with the functions SPECIAL CASE 37: // Starts with y = x^2.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Starts with $ \ \, y=x^2\\,.$

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "x^2$"; break; case 38: // Starts with y = x ^ 2. Vertical shrinkage, $\,y$ values divided by k > 1. New equation? num = rand(2, 10); string1 = "Start with $\\,y=x^2\\, . $

"; string2 = "Perform a vertical reduction where $\\,\\displaystyle (a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}x^2$"; break ; Case 39: // Starts with y = x^2.Horizontal stretch;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Starts with $\ \ ,y=x^2\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl( \\frac{x}{" + num + "}\\ bigr ) ^2$"; break; case 40: // Starts with y = x^2. Horizontal shrinkage;$\,x$ values divided by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y=x^2\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=(" + num + "x)^2$"; break; case 41: // Starts with y = x^3.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=x^3\ \ ,

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "x^3$"; break; case 42: // Starts with y = x ^ 3.Vertical shrinkage;$\,y$ values divided by k> 1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=x^3\\, . $

"; string2 = "Do a vertical flattening where $\\displaystyle \\,(a,b)\\mapsto \\bigl(a,\\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}x^3$"; break ; Case 43: // Starts with y = x^3.Horizontal stretch;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Starts with $\ \ ,y=x^3\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl(\\frac{x}{" + num + "}\\ bigr ) ^3$"; break; case 44: // Starts with y = x^3. Horizontal shrinkage;$\,x$ values divided by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y=x^3\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle \\,(a,b)\\mapsto \\bigl(\\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=(" + num + "x)^3$"; break; case 45: // Starts with y = sqrt(x).Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=\\sqrt { xPS

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "\\sqrt{x}$"; break; case 46: // Starts with y = sqrt(x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);fctstr = "\\sqrt{x}";string1 = " Begin with $\\,y=\\square root{x}\\,.$

"; string2 = "Do a vertical flattening where $\\displaystyle\\,(a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}" + fctstr + "$" ; break; case 47: // Start with y = sqrt(x). Horizontal span;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10); string1 = " Start with $ \\,y=\\square root{x}\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\sqrt{\\frac{x}{" + num + "}}$ " ; break; case 48: // Start with y = sqrt(x). Horizontal reduction; $\,x$ values divided by k>1. New equation? num = rand(2, 10); string1 = " Start with $\\,y=\\square root{x}\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=\\sqrt{" + num + "x}$"; break; case 49: // Starts with y = |x|.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=|x| \\

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "|x|$"; break; case 50: // starts with y = | x |.Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);fctstr = "|x|";string1 = "Start with $\\, y = |x|\\,.$

"; string2 = "Do a vertical flattening where $\\displaystyle \\,(a,b)\\mapsto \\bigl(a,\\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}" + fctstr + "$" ; break; case 51: // Start with y = |x|. Horizontal span;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10); string1 = "Start with $ \ \,y=|x|\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl| \\frac{x}{" + num + "}\\bigr|$"; break; case 52: // Start with y = |x|. Horizontal reduction;$\,x$ values divided by k >1 .New Equation?num = rand(2, 10);string1 = "Start with $\\,y=|x|\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=|" + num + "x|$"; break; case 53: // Starts with y = 1 / x.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\displaystyle\\,y= \\frac{ 1 } {x}\\,.$

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle \\,y= \\frac{" + num + "}{x}$"; break ; Case 54: // Starts with y = 1/x. Vertical reduction; $\,y$ values divided by k>1. New equation? num = rand(2, 10); string1 = "Starts with $ \ \ Display style\\,y= \\frac{1}{x}\\,.$

"; string2 = "Do a vertical flattening where $\\displaystyle\\,(a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "x}$"; break; case 55 : // Start with y = 1/x.Horizontal expansion;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10);string1 = "Start with $\\ style display \ \,y= \\frac{1}{x}\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{(x/" + num + ")}=\ \ frac{" + num + "}{x}$"; break; case 56: // Start with y = 1/x. Horizontal reduction;$\,x$ values divided by k>1. New equation? num = rand(2, 10); string1 = "Start with $\\displaystyle\\,y= \\frac{1}{x}\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "x}$"; break; case 57: // Start with y = e^x.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\ ,{ \\text{e}}^x\\,.$

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "{\\text{e}}^x$"; break; case 58 : // Starts with y = e^x Vertical reduction; $\,y$ values divided by k>1 New equation? num = rand(2, 10); string1 = "Starts with $\\,{ \ \ text{e}}^x\\,.$

"; string2 = "Do a vertical flattening where $\\displaystyle \\,(a,b)\\mapsto \\bigl(a,\\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}{\\text{e } } ^x$"; break; case 59: // Starts with y = e^x. Horizontal expansion;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,{\\text{and}}^x\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y={\\text{e}}^{x/" + num + "}$"; break ; case 60: // Starts with y = e^x.Horizontal shrinkage;$\,x$ values divided by k>1.New equation? num = rand(2, 10);string1 = "Starts with $\ \ , {\\text{e}}^x\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y={\\text{e}}^{" + num + "x}$"; break; case 61 : // Start with y = ln(x).Vertical span; $\,y$ values multiplied by k>1. New equation? num = rand(2, 10); string1 = "Start with $\ \ , y=\\ln(x)\\,.$

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "\\ln(x)$"; break; case 62: // Starts with y = ln(x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=\\ ln ( x)\\,.$

"; string2 = "Perform a vertical flattening where $\\displaystyle\\, (a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr )\$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}\\ln(x) $ " ; break; case 63: // Start with y = ln(x). Horizontal span;$\,x$ values multiplied by k>1 .New equation? num = rand(2, 10); string1 = " Start with $\\,y=\\ln(x)\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\ln\\bigl( \\frac{x}{" + num + " } \ \bigr)$"; break; case 64: // Start with y = ln(x). Horizontal shrinkage;$\,x$ values divided by k>1 . New equation? num = rand(2, 10 ) ; string1 = "Start with $\\,y=\\ln(x)\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=\\ln(" + num + "x)$"; break; case 65: // Accept ( a ,b) is a point on the graph of y=f(x).Which point is on y=kf(x)?num = rand(2, 10);string1 = "Suppose $\\,( a ,b ) \\,$ is a point on the graph of $\\,y=f(x)\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + num + "f(x)\\,$?"; string = string1 + string2; answer = "$(a, " + num + "b)$"; break; case 66: // Suppose (a,b) is a point on the graph of y=f(x), which point is on y=f(x)/ k?num = rand(2, 10); string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\,y=f(x)\\,. $

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}f(x)\\,$?"; string = string1 + string2 ; Response = "$\\displaystyle\\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 67: // Suppose (a,b) is a point in graph of y=f(x).Which point is on y=f(kx)?num = rand(2, 10);string1 = "Suppose $\\,(a,b)\\,$ is a Point on the graph of $\\,y=f(x)\\,.$

"; string2 = "So, what point is on the graph of $\\,y=f(" + num + "x)\\,$?"; string = string1 + string2; answer = "$\\displaystyle \ \ bigl( \\frac{a}{" + num + "},b\\bigr)$"; break; case 68: // Suppose (a,b) is a point on the graph of y=f ( x ) What point is at y=f(x/k)?num = rand(2, 10);string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\ \ , y=f(x)\\,.$

"; string2 = "So what point is on the graph of $\\displaystyle \\,y=f\\bigl(\\frac{x}{" + num + "}\\bigr)\\,$ ? "; string = string1 + string2; answer = "$(" + num + "a,b)$"; break; case 69: // Suppose (a,b) is a point on the graph of y=x^ 2. What point is on y=kx^2?num = rand(2, 10);string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\ , y= f(x)\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + num + "x^2\\,$?"; string = string1 + string2; answer = "$(a," + num + "b)$"; break; case 70: // Suppose (a,b) is a point on the graph of y=x^2 whose point is at y=x^2/k? DONE! num = rand (2, 10); string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=x^2\\,.$

"; string2 = "So what point is on the plot of $\\displaystyle \\,y=\\frac{1}{" + num + "}x^2\\,$?"; string = string1 + string2 ; answer = "$\\displaystyle \\bigl(a,\\frac{b}{" + num + "}\\bigr)$"; break; case 71: // Suppose (a,b) is a Point on the graph of y=x^2. What point is on y=(kx)^2? DONE! num = rand(2, 10); string1 = "Suppose $\\,(a, b) \\ , $ is a point on the graph of $\\,y=x^2\\,.$

"; string2 = "So, what point is on the graph of $\\,y=(" + num + "x)^2\\,$?"; string = string1 + string2; answer = "$\\ displaystyle \ \bigl(\\frac{a}{" + num + "},b\\bigr)$"; break; case 72: // Suppose (a,b) is a point on the graph of y= x ^ 2 Which point is at y=(x/k)^2? DONE! num = rand(2, 10); string1 = "Suppose $\\,(a,b)\\,$ is a point on the Graphs of $ \\,y=x^2\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle\\,y=\\bigl(\\frac{x}{" + num + "}\\bigr)^2\\, $ ? "; string = string1 + string2; answer = "$(" + num + "a,b)$"; break; case 73: // Suppose (a,b) is a point on the graph of y= x^ 3 What point is at y=kx^3? DONE! num = rand(2, 10); string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\ , y =x^3\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + num + "x^3?\\,$"; string = string1 + string2; answer = "$(a," + num + "b)$"; break; case 74: // Suppose (a,b) is a point on the graph of y=x^3 whose point is at y=x^3/k? DONE! num = rand (2, 10); string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=x^3\\,.$

"; string2 = "So what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}x^3\\,$?"; string = string1 + string2; answer = "$\\displaystyle \\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 75: // Suppose (a,b) is a point on the graph of y=x^3 which point is in y=(kx)^3 DONE! num = rand(2, 10); string1 = "Suppose $\\,(a,b)\ \,$ is a Point in the diagram of $\\,y=x^3\\,.$

"; string2 = "So, what point is on the graph of $\\,y=(" + num + "x)^3\\,$?"; string = string1 + string2; answer = "$\\ displaystyle \ \bigl( \\frac{a}{" + num + "},b\\bigr)$"; break; case 76: // Suppose (a,b) is a point on the graph of y= x ^3 Which point is at y=(x/k)^3? DONE! num = rand(2, 10); string1 = "Suppose $\\,(a,b)\\,$ is a point on the Graphs of $ \\,y=x^3\\,.$

"; string2 = "So what point is on the graph of $\\displaystyle y=\\bigl( \\frac{x}{" + num + "})^3\\,$?"; string = string1 + string2; answer = "$(" + num + "a,b)$"; break; case 77: // Suppose (a,b) is a point on the graph of y=sqrt(x). on y =ksqrt(x)?DONE! num = rand(2, 10); fct = "\\sqrt{x}"; string1 = "Suppose $\\,(a,b)\\, $ is a point on the graph of $\\,y=" + fct + "\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + num + fct + "\\,$?"; string = string1 + string2; answer = "$(a," + num + "b)$"; break; case 78: // Suppose (a,b) is a point on the graph of y=sqrt(x), which point is in y=sqrt(x)/k? DONE! num = rand(2, 10); fct = "\\sqrt{x}"; string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\ \,y= " + fct + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}" + fct + "\\,$?"; string = string1 + string2 ; answer = "$\\displaystyle \\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 79: // Suppose (a,b) is a Point on the graph of y=sqrt(x).Which point is on y=sqrt(kx)?DONE!num = rand(2, 10);fct = "\\sqrt{x}";fctshift = "\\ sqrt { " + num + "x}"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + " \ \, is. $

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answer = "$\\displaystyle \\bigl( \ \ frac{a}{" + num + "},b\\bigr)$"; break; case 80: // Suppose (a,b) is a point on the graph of y=sqrt(x). at y= sqrt(x/k)?DONE!num = rand(2, 10);fct = "\\sqrt{x}";fctshift = "\\sqrt{\\frac{x}{ " + num + " }} "; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answer = "$(" + num + " a,b)$"; break; case 81: // Suppose (a,b) is a point on the graph of y=abs(x). Which point is on y=kabs(x)?! FACT! num = rand(2, 10); fct = "|x|"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" fct is "\ps

"; string2 = "So, what point is on the graph of $\\,y=" + num + fct + "\\,$?"; string = string1 + string2; answer = "$(a," + num + "b)$"; break; case 82: // Suppose (a,b) is a point on the graph of y=abs(x) whose point is at y=abs(x)/k? DONE! num = rand(2, 10); fct = "|x|"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y =" fct is "ps

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}" + fct + "\\,$?"; string = string1 + string2 ; answer = "$\\displaystyle \\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 83: // Suppose (a,b) is a Point on the graph of y=abs(x).Which point is on y=abs(kx)?DONE!num = rand(2, 10);fct = "|x|";fctshift = "|" + num + " x |"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + "\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answer = "$\\displaystyle\\bigl( \ \ frac{a}{" + num + "},b\\bigr)$"; break; case 84: // Suppose (a,b) is a point on the graph of y=abs(x). y = abs(x/k)? DONE! num = rand(2, 10); fct = "|x|"; fctshift = "\\bigl|\\frac{x}{" + num + " }\ \ bigr | "; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + "\\,. $

"; string2 = "So, what point is on the graph of $\\displaystyle\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answer = "$(" + num + " a,b)$"; break; case 85: // Suppose (a,b) is a point on the graph of y=1/x. Which point is on y=k/x? Only one! of this type DONE ! num = rand(2, 10); fct1 = "\\frac{1}{x}"; fct2 = "\\frac{" + num + "}{x}"; string1 = "Assuming that $ \ \ , ( a,b)\\,$ is a point on the graph of $\\displaystyle\\,y=" + fct1 + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle\\,y=" + fct2 + "\\,$?"; string = string1 + string2; answer = "$(a," + num + "b)$"; break; case 86: // Suppose (a,b) is a point on the graph of y=e^x whose point is at y=ke^x? DONE! num = rand( 2 , 10); fct = "{\\text{e}}^x"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $ \\ ,y= is " + fkt + "\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + num + fct + "\\,$?"; string = string1 + string2; answer = "$(a," + num + "b)$"; break; case 87: // Suppose (a,b) is a point on the graph of y=e^x whose point is at y=e^x/k? DONE! !num = rand ( 2, 10);fct = "{\\text{e}}^x";string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\ , y = " + fkt + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}" + fct + "\\,$?"; string = string1 + string2 ; answer = "$\\displaystyle\\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 88: // Suppose (a,b) is a Point on the graph of y=e^x. What point is on y=e^(kx)? DONE! num = rand(2, 10); fct = "{\\text{e}}^x "; fctshift = " {\\text{e}}^{" + num + "x}"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $ \ \,y is =" + fkt + "\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answer = "$\\displaystyle\\bigl( \ \ frac{a}{" + num + "},b\\bigr)$"; break; case 89: // Suppose (a,b) is a point on the graph of y=e^x. Which point lies on y=e^(x/k)?DONE!num = rand(2, 10);fct = "{\\text{e}}^x";fctshift = "{\\text{e }}^ {x /" + num + "}"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + " \ \, is. $

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answer = "$(" + num + "a , b )$"; break; case 90: // Suppose (a,b) is a point on the graph of y=ln(x). Which point is on y=kln(x)? DONE! num = rand(2 , 10); fct = "\\ln(x)"; string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\,y= " + fct + "\ps

"; string2 = "So, what point is on the graph of $\\,y=" + num + fct + "\\,$?"; string = string1 + string2; answer = "$(a," + num + "b)$"; break; case 91: // Suppose (a,b) is a point on the graph of y=ln(x) whose point is at y=ln(x)/k? DONE! num = rand(2, 10); fct = "\\ln(x)"; string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\ \,y= " + fct + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}" + fct + "\\,$?"; string = string1 + string2 ; response = "$\\displaystyle\\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 92: // Suppose (a,b) is a Point on the graph of y=ln(x).Which point is on y=ln(kx)?DONE!num = rand(2, 10);fct = "\\ln(x)";fctshift = "\\ ln ( " + num + "x)"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + " \ \, is. $

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answer = "$\\displaystyle\\bigl( \ \ frac{a}{" + num + "},b\\bigr)$"; break; case 93: // Suppose (a,b) is a point on the graph of y=ln(x). y= ln (x/k)?DONE!num = rand(2, 10);fct = "\\ln(x)";fctshift = "\\displaystyle\\ln\\bigl( \\frac {x } {" + num + "}\\bigr)"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y= " + fct + "\ hp is

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answer = "$(" + num + "a , b )$"; } // complete the change currentDisplayedProbTypeGV = n; mostRecentProbTypeGV = n; updateProbDisplay(); // make the current problem black document.getElementById('chkAnsDiv').innerHTML = ""; // clear the document response field .getElementById('newProbDiv').innerHTML = string // write the new problem MathJax.Hub.Typeset('newProbDiv'); // process the document math.theform.chkAnsButton.focus(); // return focus String from the "Check Answer" button; } function newprobs(probTypeVar) { if (arguments.length == 1) { operation(probTypeVar); } else { operation(); } } function checkans() { document.getElementById( 'chkAnsDiv ').innerHTML = answer; // write the new problem MathJax.Hub.Typeset('chkAnsDiv'); // process the math if (flagGV == 1) { document.theform.sameProbButton.focus(); // yields conc click the "same or similar problem" button } else { document.theform.newProbButton.focus(); // focuses the New Problem button } } function createprob(disprob) { var n, num, string1, string2, string3, string, fct, fctshift; // kk is a global variable if (arguments.length == 1) { n = disprob; flagGV = 1; } more {n = rand(1, 93); flagGV = 0; } change(n) { Case 1: // Start with y = f(x). vertical stretching; $\,y$ values multiplied by k>1. New equation? number = margin(2, 10); string1 = "Start with $\\,y=f(x)\\,.$

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "f(x)$"; break; Case 2: // starts with y = f (x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=f(x)\ \

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=\\displaystyle \\frac{1}{" + num + "}f(x)$" ; break ; Case 3: // Start with y = f(x).Horizontal extent;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Start with $ \\,y = f(x)\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=f\\bigl(\\displaystyle \\frac{x}{" + num + "}\ \ bigr )$"; break; case 4: // Start with y = f(x). Scale down;$\,x$ values divided by k>1 . New equation? num = rand(2, 10) ; string1 = "Start with $\\,y = f(x)\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=f(" + num + "x)$"; break; case 5: // Now the snippet / shrink with SPECIFIC functions // Starts with y = x^2.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Starts with $ \ \ ,y=x^2\\,.$

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "x^2$"; break; Case 6: // Starts with y = x ^ 2. Vertical shrinkage, $\,y$ values divided by k > 1. New equation? num = rand(2, 10); string1 = "Start with $\\,y=x^2\\, . $

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}x^2$"; break ;Case 7: //Starts with y = x^2.Horizontal stretch;$\,x$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Starts with $ \\ ,y=x^2\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl(\\frac{x}{" + num + "}\\ bigr ) ^2$"; break; Case 8: // Starts with y = x^2. Horizontal shrinkage;$\,x$ values divided by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y=x^2\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=(" + num + "x)^2$"; break; case 9: // Starts with y = x^3.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=x^3\ \ ,

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "x^3$"; break; Case 10: // Starts with y = x ^ 3.Vertical shrinkage;$\,y$ values divided by k> 1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=x^3\\, . $

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}x^3$"; break ; Case 11: // Starts with y = x^3.Horizontal stretch;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Starts with $ \\ ,y=x^3\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl( \\frac{x}{" + num + "}\\ bigr ) ^3$"; break; Case 12: // Starts with y = x^3. Horizontal shrinkage;$\,x$ values divided by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y=x^3\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=(" + num + "x)^3$"; break; case 13: // Starts with y = sqrt(x).Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=\\sqrt { xPS

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=" + num + "\\sqrt{x}$"; break; case 14: // Starts with y = sqrt(x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);fctstr = "\\sqrt{x}";string1 = " Begin with $\\,y=\\square root{x}\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}" + fctstr + "$" ;break;case 15: // Start with y = sqrt(x).Horizontal span;$\,x$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = " Start with $\\,y=\\square root{x}\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\sqrt{ \\frac{x}{" + num + "}}$ " ; break; case 16: // Start with y = sqrt(x). Shrink horizontal;$\,x$ values divided by k>1. New equation? num = rand(2, 10); string1 = " Start with $\\,y=\\square root{x}\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=\\sqrt{" + num + "x}$"; break; case 17: // Starts with y = |x|.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=|x| \\

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=" + num + "|x|$"; break; case 18: // starts with y = | x |.Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);fctstr = "|x|";string1 = "Start with $\\, y = |x|\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}" + fctstr + "$" ; break; case 19: // Start with y = |x|. Horizontal span;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10); string1 = "Start with $ \ \,y=|x|\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl| \\frac{x}{" + num + "}\\bigr|$"; break; case 20: // start with y = |x|. Horizontal reduction;$\,x$ values divided by k >1 .New Equation?num = rand(2, 10);string1 = "Start with $\\,y=|x|\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=|" + num + "x|$"; break; case 21: // Starts with y = 1 / x.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\displaystyle y= \\frac{1}{ xps

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{" + num + "}{x}$"; break; case 22 : // Starts with y = 1/x.Vertical reduction; $\,y$ values divided by k>1.New equation? num = rand(2, 10); string1 = "Starts with $\\displaystyle y = \\frac{1}{x}\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "x}$"; break; case 23: // Start with y = 1/x.Horizontal expansion;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10);string1 = "Start with $\\ display style y = \\frac{1}{x}\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{(x/" + num + ")}=\ \ frac{" + num + "}{x}$"; break; case 24: // Start with y = 1/x. Horizontal reduction;$\,x$ values divided by k>1. New equation? num = rand(2, 10); string1 = "Start with $\\displaystyle y= \\frac{1}{x}\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "x}$"; break; case 25 : // Start with y = e^x.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\ , y ={\\text{e}}^x\\,.$

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "{\\text{e}}^x$"; break; case 26 : // Starts with y = e^x Vertical reduction; $\,y$ values divided by k>1 New equation? num = rand(2, 10); string1 = "Starts with $\\,y = { \\text{e}}^x\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}{\\text{e } } ^x$"; break; case 27: // Starts with y = e^x. Horizontal expansion;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y={\\text{e}}^x\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y={\\text{e}}^{x/" + num + "}$"; break ; case 28: // Starts with y = e^x.Horizontal shrinkage;$\,x$ values divided by k>1.New equation? num = rand(2, 10);string1 = "Starts with $\ \ , y={\\text{e}}^x\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y={\\text{e}}^{" + num + "x}$"; break; case 29 : // Start with y = ln(x).Vertical span; $\,y$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Start with $\ \ , y=\\ln(x)\\,.$

"; string2 = "Perform a vertical stretch; $\\,y$ values in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "\\ln(x)$"; break; case 30: // Starts with y = ln(x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=\\ ln ( x)\\,.$

"; string2 = "Perform a vertical flattening; $\\,y$ values in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}\\ln(x) $ " ; break; case 31: // Start with y = ln(x). Horizontal span;$\,x$ values multiplied by k>1 .New equation? num = rand(2, 10); string1 = " Start with $\\,y=\\ln(x)\\,.$

"; string2 = "Do a horizontal stretch; Values of $\\,x$ in the chart must be multiplied by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\ln\\bigl( \\frac{x}{" + num + " } \ \bigr)$"; break; case 32: // Start with y = ln(x). Scale down;$\,x$values divided by k>1 . New equation? num = rand ( 2, 10) ; string1 = "Start with $\\,y=\\ln(x)\\,.$

"; string2 = "Make a horizontal flattening; Values of $\\,x$ in the chart must be divided by $\\," + num + "\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=\\ln(" + num + "x)$"; break; case 33: // Starts with y = f(x).Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y = f(x ) p.s

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=" + num + "f(x)$"; break; case 34: // starts with y = f (x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y = f(x)\ \

"; string2 = "Perform a vertical flattening where $\\,\\displaystyle(a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr )\$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}f(x)$" ; break ; Case 35: // Start with y = f(x).Horizontal extent;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Start with $ \\,y = f(x)\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=f\\bigl( \\frac{x}{" + num + "}\ \ bigr )$"; break; case 36: // Start with y = f(x). Scale down;$\,x$ values divided by k>1 . New equation? num = rand(2, 10) ; string1 = "Start with $\\,y = f(x)\\,.$

"; string2 = "Resize horizontally, where $\\,\\displaystyle (a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=f(" + num + "x)$"; break; // Now stretch/shrink with SPECIFIC functions case 37: // Starts with y = x^2.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Starts with $ \\ , y=x^2\\,.$

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "x^2$"; break; case 38: // Starts with y = x ^ 2. Vertical shrinkage, $\,y$ values divided by k > 1. New equation? num = rand(2, 10); string1 = "Start with $\\,y=x^2\\, . $

"; string2 = "Perform a vertical reduction where $\\,\\displaystyle (a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}x^2$"; break ; Case 39: // Starts with y = x^2.Horizontal stretch;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Starts with $\ \ ,y=x^2\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl( \\frac{x}{" + num + "}\\ bigr ) ^2$"; break; case 40: // Starts with y = x^2. Horizontal shrinkage;$\,x$ values divided by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y=x^2\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=(" + num + "x)^2$"; break; case 41: // Starts with y = x^3.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=x^3\ \ ,

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "x^3$"; break; case 42: // Starts with y = x ^ 3.Vertical shrinkage;$\,y$ values divided by k> 1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=x^3\\, . $

"; string2 = "Do a vertical flattening where $\\displaystyle \\,(a,b)\\mapsto \\bigl(a,\\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}x^3$"; break ; Case 43: // Starts with y = x^3.Horizontal stretch;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10); string1 = "Starts with $\ \ ,y=x^3\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl(\\frac{x}{" + num + "}\\ bigr ) ^3$"; break; case 44: // Starts with y = x^3. Horizontal shrinkage;$\,x$ values divided by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,y=x^3\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle \\,(a,b)\\mapsto \\bigl(\\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=(" + num + "x)^3$"; break; case 45: // Starts with y = sqrt(x).Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=\\sqrt { xPS

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=" + num + "\\sqrt{x}$"; break; case 46: // Starts with y = sqrt(x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);fctstr = "\\sqrt{x}";string1 = " Begin with $\\,y=\\square root{x}\\,.$

"; string2 = "Do a vertical flattening where $\\displaystyle\\,(a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}" + fctstr + "$" ; break; case 47: // Start with y = sqrt(x). Horizontal span;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10); string1 = " Start with $ \\,y=\\square root{x}\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\sqrt{\\frac{x}{" + num + "}}$ " ; break; case 48: // Start with y = sqrt(x). Horizontal reduction; $\,x$ values divided by k>1. New equation? num = rand(2, 10); string1 = " Start with $\\,y=\\square root{x}\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=\\sqrt{" + num + "x}$"; break; case 49: // Starts with y = |x|.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=|x| \\

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=" + num + "|x|$"; break; case 50: // starts with y = | x |.Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);fctstr = "|x|";string1 = "Start with $\\, y = |x|\\,.$

"; string2 = "Do a vertical flattening where $\\displaystyle \\,(a,b)\\mapsto \\bigl(a,\\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}" + fctstr + "$" ; break; case 51: // Start with y = |x|. Horizontal span;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10); string1 = "Start with $ \ \,y=|x|\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\bigl| \\frac{x}{" + num + "}\\bigr|$"; break; case 52: // Start with y = |x|. Horizontal reduction;$\,x$ values divided by k >1 .New Equation?num = rand(2, 10);string1 = "Start with $\\,y=|x|\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answ = "$y=|" + num + "x|$"; break; case 53: // Starts with y = 1 / x.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\displaystyle\\,y= \\frac{ 1 } {x}\\,.$

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle \\,y= \\frac{" + num + "}{x}$"; break ; Case 54: // Starts with y = 1/x. Vertical reduction; $\,y$ values divided by k>1. New equation? num = rand(2, 10); string1 = "Starts with $ \ \ Display style\\,y= \\frac{1}{x}\\,.$

"; string2 = "Do a vertical flattening where $\\displaystyle\\,(a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "x}$"; break; case 55 : // Start with y = 1/x.Horizontal expansion;$\,x$ values multiplied by k>1.New equation? num = rand(2, 10);string1 = "Start with $\\ style display \ \,y= \\frac{1}{x}\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{(x/" + num + ")}=\ \ frac{" + num + "}{x}$"; break; case 56: // Start with y = 1/x. Horizontal reduction;$\,x$ values divided by k>1. New equation? num = rand(2, 10); string1 = "Start with $\\displaystyle\\,y= \\frac{1}{x}\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "x}$"; break; case 57: // Start with y = e^x.Vertical stretch;$\,y$ values multiplied by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\ ,{ \\text{e}}^x\\,.$

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "{\\text{e}}^x$"; break; case 58 : // Starts with y = e^x Vertical reduction; $\,y$ values divided by k>1 New equation? num = rand(2, 10); string1 = "Starts with $\\,{ \ \ text{e}}^x\\,.$

"; string2 = "Do a vertical flattening where $\\displaystyle \\,(a,b)\\mapsto \\bigl(a,\\frac{b}{" + num + "}\\bigr) \$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\frac{1}{" + num + "}{\\text{e } } ^x$"; break; case 59: // Starts with y = e^x. Horizontal expansion;$\,x$ values multiplied by k>1. New equation? num = rand(2, 10) ; string1 = "Start with $\\,{\\text{and}}^x\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y={\\text{e}}^{x/" + num + "}$"; break ; case 60: // Starts with y = e^x.Horizontal shrinkage;$\,x$ values divided by k>1.New equation? num = rand(2, 10);string1 = "Starts with $\ \ , {\\text{e}}^x\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y={\\text{e}}^{" + num + "x}$"; break; case 61 : // Start with y = ln(x).Vertical span; $\,y$ values multiplied by k>1. New equation? num = rand(2, 10); string1 = "Start with $\ \ , y=\\ln(x)\\,.$

"; string2 = "Do a vertical stretch where $\\,(a,b)\\mapsto(a," + num + "b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=" + num + "\\ln(x)$"; break; case 62: // Starts with y = ln(x).Vertical reduction;$\,y$ values divided by k>1.New equation?num = rand(2, 10);string1 = "Start with $\\,y=\\ ln ( x)\\,.$

"; string2 = "Perform a vertical flattening where $\\displaystyle\\, (a,b)\\mapsto \\bigl(a, \\frac{b}{" + num + "}\\bigr )\$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y= \\frac{1}{" + num + "}\\ln(x) $ " ; break; case 63: // Start with y = ln(x). Horizontal span;$\,x$ values multiplied by k>1 .New equation? num = rand(2, 10); string1 = " Start with $\\,y=\\ln(x)\\,.$

"; string2 = "Stretch horizontally, where $\\,(a,b)\\mapsto (" + num + "a,b)\\,.$

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$\\displaystyle y=\\ln\\bigl( \\frac{x}{" + num + " } \ \bigr)$"; break; case 64: // Start with y = ln(x). Horizontal shrinkage;$\,x$ values divided by k>1 . New equation? num = rand(2, 10 ) ; string1 = "Start with $\\,y=\\ln(x)\\,.$

"; string2 = "Resize horizontally, where $\\displaystyle\\,(a,b)\\mapsto \\bigl( \\frac{a}{" + num + "},b\\bigr)\ $

"; string3 = "What is the new equation?"; string = string1 + string2 + string3; answer = "$y=\\ln(" + num + "x)$"; break; case 65: // Accept ( a ,b) is a point on the graph of y=f(x).Which point is on y=kf(x)?num = rand(2, 10);string1 = "Suppose $\\,( a ,b ) \\,$ is a point on the graph of $\\,y=f(x)\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + num + "f(x)\\,$?"; string = string1 + string2; resw = "$(a, " + num + "b)$"; break; case 66: // Suppose (a,b) is a point on the graph of y=f(x), which point is on y=f(x)/ k?num = rand(2, 10); string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\,y=f(x)\\,. $

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}f(x)\\,$?"; string = string1 + string2 ; answ = "$\\displaystyle\\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 67: // Suppose (a,b) is a point in graph of y=f(x).Which point is on y=f(kx)?num = rand(2, 10);string1 = "Suppose $\\,(a,b)\\,$ is a Point on the graph of $\\,y=f(x)\\,.$

"; string2 = "So, what point is on the graph of $\\,y=f(" + num + "x)\\,$?"; string = string1 + string2; answ = "$\\displaystyle \ \ bigl( \\frac{a}{" + num + "},b\\bigr)$"; break; case 68: // Suppose (a,b) is a point on the graph of y=f (x ) What point is at y=f(x/k)?num = rand(2, 10);string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\ \ , y=f(x)\\,.$

"; string2 = "So what point is on the graph of $\\displaystyle \\,y=f\\bigl(\\frac{x}{" + num + "}\\bigr)\\,$ ? "; string = string1 + string2; answer = "$(" + num + "a,b)$"; break; case 69: // Suppose (a,b) is a point on the graph of y=x^ 2. What point is on y=kx^2?num = rand(2, 10);string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\ , y= f(x)\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + num + "x^2\\,$?"; string = string1 + string2; resw = "$(a," + num + "b)$"; break; case 70: // Suppose (a,b) is a point on the graph of y=x^2 whose point is at y=x^2/k? DONE! num = rand (2, 10); string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=x^2\\,.$

"; string2 = "So what point is on the plot of $\\displaystyle \\,y=\\frac{1}{" + num + "}x^2\\,$?"; string = string1 + string2 ; answer = "$\\displaystyle \\bigl(a,\\frac{b}{" + num + "}\\bigr)$"; break; case 71: // Suppose (a,b) is a Point on the graph of y=x^2. What point is on y=(kx)^2? DONE! num = rand(2, 10); string1 = "Suppose $\\,(a, b) \\ , $ is a point on the graph of $\\,y=x^2\\,.$

"; string2 = "So, what point is on the graph of $\\,y=(" + num + "x)^2\\,$?"; string = string1 + string2; answ = "$\\ displaystyle \ \bigl(\\frac{a}{" + num + "},b\\bigr)$"; break; case 72: // Suppose (a,b) is a point on the graph of y= x ^2 Which point is at y=(x/k)^2? DONE! num = rand(2, 10); string1 = "Suppose $\\,(a,b)\\,$ is a point on the Graphs of $ \\,y=x^2\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle\\,y=\\bigl(\\frac{x}{" + num + "}\\bigr)^2\\, $ ? "; string = string1 + string2; answer = "$(" + num + "a,b)$"; break; case 73: // Suppose (a,b) is a point on the graph of y= x^ 3 What point is at y=kx^3? DONE! num = rand(2, 10); string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\ , y =x^3\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + num + "x^3?\\,$"; string = string1 + string2; resw = "$(a," + num + "b)$"; break; case 74: // Suppose (a,b) is a point on the graph of y=x^3 whose point is at y=x^3/k? DONE! num = rand (2, 10); string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=x^3\\,.$

"; string2 = "So what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}x^3\\,$?"; string = string1 + string2; answer = "$\\displaystyle \\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 75: // Suppose (a,b) is a point on the graph of y=x^3 which point is in y=(kx)^3 DONE! num = rand(2, 10); string1 = "Suppose $\\,(a,b)\ \,$ is a Point in the diagram of $\\,y=x^3\\,.$

"; string2 = "So, what point is on the graph of $\\,y=(" + num + "x)^3\\,$?"; string = string1 + string2; answ = "$\\ displaystyle \ \bigl( \\frac{a}{" + num + "},b\\bigr)$"; break; case 76: // Suppose (a,b) is a point on the graph of y= x ^3 Which point is at y=(x/k)^3? DONE! num = rand(2, 10); string1 = "Suppose $\\,(a,b)\\,$ is a point on the Graphs of $ \\,y=x^3\\,.$

"; string2 = "So what point is on the graph of $\\displaystyle y=\\bigl( \\frac{x}{" + num + "})^3\\,$?"; string = string1 + string2; answer = "$(" + num + "a,b)$"; break; case 77: // Suppose (a,b) is a point on the graph of y=sqrt(x). on y =ksqrt(x)?DONE! num = rand(2, 10); fct = "\\sqrt{x}"; string1 = "Suppose $\\,(a,b)\\, $ is a point on the graph of $\\,y=" + fct + "\\,.$

"; string2 = "So which point is on the graph of $\\,y=" + num + fct + "\\,$?"; string = string1 + string2; resw = "$(a," + num + "b)$"; break; case 78: // Suppose (a,b) is a point on the graph of y=sqrt(x), which point is in y=sqrt(x)/k? DONE! num = rand(2, 10); fct = "\\sqrt{x}"; string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\ \,y=" + fct + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}" + fct + "\\,$?"; string = string1 + string2 ; answer = "$\\displaystyle \\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 79: // Suppose (a,b) is a Point on the graph of y=sqrt(x).Which point is on y=sqrt(kx)?DONE!num = rand(2, 10);fct = "\\sqrt{x}";fctshift = "\\ sqrt { " + num + "x}"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + " \ \, is. $

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answ = "$\\displaystyle \\bigl( \ \ frac{a}{" + num + "},b\\bigr)$"; break; case 80: // Suppose (a,b) is a point on the graph of y=sqrt(x). at y= sqrt(x/k)?DONE!num = rand(2, 10);fct = "\\sqrt{x}";fctshift = "\\sqrt{\\frac{x}{ " + num + " }} "; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answ = "$(" + num + " a,b)$"; break; case 81: // Suppose (a,b) is a point on the graph of y=abs(x). Which point is on y=kabs(x)?! FACT! num = rand(2, 10); fct = "|x|"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" fct is "\ps

"; string2 = "So which point is on the graph of $\\,y=" + num + fct + "\\,$?"; string = string1 + string2; resw = "$(a," + num + "b)$"; break; case 82: // Suppose (a,b) is a point on the graph of y=abs(x) whose point is at y=abs(x)/k? DONE! num = rand(2, 10); fct = "|x|"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y =" + fct + is "ps

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}" + fct + "\\,$?"; string = string1 + string2 ; answer = "$\\displaystyle \\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 83: // Suppose (a,b) is a Point on the graph of y=abs(x).Which point is on y=abs(kx)?DONE!num = rand(2, 10);fct = "|x|";fctshift = "|" + num + " x |"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + "\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answ = "$\\displaystyle\\bigl( \ \ frac{a}{" + num + "},b\\bigr)$"; break; case 84: // Suppose (a,b) is a point on the graph of y=abs(x). y = abs(x/k)? DONE! num = rand(2, 10); fct = "|x|"; fctshift = "\\bigl|\\frac{x}{" + num + " }\ \ bigr | "; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + "\\,. $

"; string2 = "So, what point is on the graph of $\\displaystyle\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answ = "$(" + num + " a,b)$"; break; case 85: // Suppose (a,b) is a point on the graph of y=1/x. Which point is on y=k/x? Only one! of this type DONE ! num = rand(2, 10); fct1 = "\\frac{1}{x}"; fct2 = "\\frac{" + num + "}{x}"; string1 = "Assuming that $ \\ , ( a,b)\\,$ is a point on the graph of $\\displaystyle\\,y=" + fct1 + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle\\,y=" + fct2 + "\\,$?"; string = string1 + string2; answ = "$(a," + num + "b)$"; break; case 86: // Suppose (a,b) is a point on the graph of y=e^x whose point is at y=ke^x? DONE! num = rand( 2 , 10); fct = "{\\text{e}}^x"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $ \\ ,y= is " + fkt + "\\,.$

"; string2 = "So which point is on the graph of $\\,y=" + num + fct + "\\,$?"; string = string1 + string2; resw = "$(a," + num + "b)$"; break; case 87: // Suppose (a,b) is a point on the graph of y=e^x whose point is at y=e^x/k? DONE! !num = rand ( 2, 10);fct = "{\\text{e}}^x";string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\, y = " + fkt + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}" + fct + "\\,$?"; string = string1 + string2 ; answer = "$\\displaystyle\\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 88: // Suppose (a,b) is a Point on the graph of y=e^x. What point is on y=e^(kx)? DONE! num = rand(2, 10); fct = "{\\text{e}}^x "; fctshift = " {\\text{e}}^{" + num + "x}"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $ \ \,y is =" + fkt + "\\,.$

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answ = "$\\displaystyle\\bigl( \ \ frac{a}{" + num + "},b\\bigr)$"; break; case 89: // Suppose (a,b) is a point on the graph of y=e^x. Which point lies on y=e^(x/k)?DONE!num = rand(2, 10);fct = "{\\text{e}}^x";fctshift = "{\\text{e }}^ {x /" + num + "}"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + " \ \, is. $

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; resw = "$(" + num + "a, b )$"; break; case 90: // Suppose (a,b) is a point on the graph of y=ln(x). Which point is on y=kln(x)? DONE! num = rand(2 , 10); fct = "\\ln(x)"; string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\\,y= " + fct + " \ P.S

"; string2 = "So which point is on the graph of $\\,y=" + num + fct + "\\,$?"; string = string1 + string2; resw = "$(a," + num + "b)$"; break; case 91: // Suppose (a,b) is a point on the graph of y=ln(x) whose point is at y=ln(x)/k? DONE! num = rand(2, 10); fct = "\\ln(x)"; string1 = "Suppose $\\,(a,b)\\,$ is a point on the graph of $\ \,y=" + fct + "\\,.$

"; string2 = "So, what point is on the graph of $\\displaystyle y= \\frac{1}{" + num + "}" + fct + "\\,$?"; string = string1 + string2 ; response = "$\\displaystyle\\bigl(a, \\frac{b}{" + num + "}\\bigr)$"; break; case 92: // Suppose (a,b) is a Point on the graph of y=ln(x).Which point is on y=ln(kx)?DONE!num = rand(2, 10);fct = "\\ln(x)";fctshift = "\\ ln ( " + num + "x)"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y=" + fct + " \ \, is. $

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; answ = "$\\displaystyle\\bigl( \ \ frac{a}{" + num + "},b\\bigr)$"; break; case 93: // Suppose (a,b) is a point on the graph of y=ln(x). y= ln (x/k)?DONE!num = rand(2, 10);fct = "\\ln(x)";fctshift = "\\displaystyle\\ln\\bigl( \\frac {x } {" + num + "}\\bigr)"; string1 = "Assume that $\\,(a,b)\\,$ is a point on the graph of $\\,y= " + fct + "\ hp is

"; string2 = "So, what point is on the graph of $\\,y=" + fctshift + "\\,$?"; string = string1 + string2; resw = "$(" + num + "a, b )$"; } // final key answer[kk] = answer; kk = kk + 1; return string; } function worksheet() { var numProb, space, bigstring, kmat; kk = 0; numProb = document.getElementById ( 'numProbWksht').value;numProb = eval(numProb); // so if you write something like 5/2 it still works!numProb = Math.abs(Math.ceil(numProb)); // An At this point, it's a non-negative integer if (numProb > 93) { numProb = 93; } space = document.getElementById('wkshtWorkSpace').value; space = eval(space); space = Math.abs(Math.ceil ( space ) ); // this is a non-negative integer answerm = new Array(); kmat = selectn(1, 93, numProb); // put the maximum number of cases in the second array WSwin = window . open(' ', '_blank' , 'resize=1,scrollbars=1'); // open a new window bigstring = headerstringWksht; bigstring += "A math cat, please! pre-calculation

"; string grande += "Copyright 2004 2013 dr. carol cf is burning

"; bigstring += "DRAW/REDUCE HORIZONTAL AND VERTICAL

"; Upper case += "NAME:

"; string grande += "

"; bigstring += endstring; WSwin.document.write(bigstring); WSwin.document.close(); if (window.focus) { WSwin.focus(); } // trae la nueva ventana al frente }