The #1 Desmos Power Move

Regression Magic Codes

Stop doing algebra manually. Use these "magic codes" to make Desmos solve Linear, Quadratic, and Exponential problems in seconds.

Mastery Status

Complete this to unlock the Desmos God wallpaper pack.

🪄 Linear Regression Hack

Best for: Problems with coordinates like (x, y) or a data table.

📝 SAT Problem

In the xy-plane, a line passes through the points (4, 5) and (7, 9). Which of the following is an equation of the line?

(A) y = 1.33x - 0.33
(B) y = 0.75x + 2
(C) y = 1.33x + 0.33
(D) y = 0.75x - 2

Step 1: Enter Your Points

Open the calculator, click +, and select Table.

Type the points (4, 5) and (7, 9) into rows 1 and 2.

Enter points in Table

Step 2: Paste the Magic Code

Click the empty space Line 2 (below the table) and paste the code below:

y_1 ~ m*x_1 + b
Desmos Linear Result

Done! Desmos gives you m and b instantly. No math required.

✅ Final Answer:

m = 1.33, b = -0.33

The equation is: y = 1.33x - 0.33 (Answer choice A)

🪄 Quadratic Regression Hack

Best for: Problems with 3 points, parabolas, or paths of projectiles.

📝 SAT Problem

A parabola in the xy-plane passes through the points (1, 4), (2, 9), and (3, 16). Which of the following defines the relationship between x and y?

(A) y = x² + 2x + 1
(B) y = 2x² + x + 1
(C) y = x² + x + 2
(D) y = x² + 2x + 2

Step 1: Enter 3 Points in a Table

Open the calculator, click +, and select Table.

Enter the points: (1, 4), (2, 9), and (3, 16) into the table.

Enter 3 points in Table

Step 2: Paste the Magic Code

Click Line 2 (below the table) and paste the Quadratic Regression code.

y_1 ~ a*x_1^2 + b*x_1 + c
Desmos Quadratic Result

Success! Desmos gives you a, b, and c. You just found the whole equation.

✅ Final Answer:

a = 1, b = 2, c = 1

The equation is: y = x² + 2x + 1 (Answer choice A)

🪄 Exponential Regression Hack

Best for: Problems with doubling, halving, or percent growth.

📝 SAT Problem

A population of bacteria starts at 100 and doubles every year. If y is the population after x years, which of the following equations models this growth?

(A) y = 100(2)ˣ
(B) y = 2(100)ˣ
(C) y = 100(1.5)ˣ
(D) y = 100 + 2x

Step 1: Enter Your Growth Points

At year 0, population is 100. At year 1, it's 200. Put these in a table.

Enter growth points in Table

Step 2: Paste the Magic Code

Click Line 2 (below the table) and paste the Exponential code.

y_1 ~ a*b^x_1
Desmos Exponential Result

Perfect! a = 100 (start value) and b = 2 (doubling rate). Equation found.

✅ Final Answer:

a = 100, b = 2

The equation is: y = 100(2)ˣ (Answer choice A)

The Mastery Sandbox

Don't just read it. Try it. Type one of the codes above into your own Desmos calculator now to see the math happen.

Example Challenge:

"A parabola passes through $(1, 4)$, $(2, 9)$, and $(3, 16)$. Find its equation."

  • Step 1: Click +Table in Desmos.
  • Step 2: Enter (1,4), (2,9), and (3,16) by pressing Tab between numbers.
  • Step 3: Click the empty Line 2 BELOW the table.
  • Step 4: Copy the Quadratic Code above and Paste it.
Open Desmos Calculator ↗