This is the work we are going to do on Problem 1 from page 226

PTS = {{10,250},{20,400},{30,550},{40,700}}

ListPlot[PTS]

PTSPLOT = ListPlot[PTS,PlotStyle-> {Magenta, PointSize[0.03]},PlotLegends->{"Data"}, AxesLabel->{"E","C"}]

PTS

PTS[[1]]

PTS[[3]]

PTS[[3]]-PTS[[1]]

300/20

This is the change in y over the change in x between the third and first point in the list PTS
the [[2]] is the second entry in PTS[[3]] which is the first entry in the list PTS, something similar for the [[1]]....

PTS[[3]][[1]]

PTS[[3]][[2]]

(PTS[[3]][[2]]-PTS[[1]][[2]])/(PTS[[3]][[1]]-PTS[[1]][[1]])

PTS[[3]]

PTS[[1]]

THIS IS A TITLE!

words words words more words....

ALT+7 gives you a text window
CTRL+C copies, CRTL+V pastes... now to test the slope between the first and 4th point....  hopefully we still get m=15 if the data is linear...

(PTS[[4]][[2]]-PTS[[1]][[2]])/(PTS[[4]][[1]]-PTS[[1]][[1]])

(PTS[[2]][[2]]-PTS[[1]][[2]])/(PTS[[2]][[1]]-PTS[[1]][[1]])

So we know the slope is m=15, we need to find the “b” in y = mx + b

PTS[[1]]

Clear[b]

Solve[250== 15*10+b,b]

PTS

So the equation of our line is C = 15*E+100

LINEPLOT = Plot[15*x+100,{x,0,50}, PlotStyle->{Blue, Thickness[0.005]}]

Show[PTSPLOT, LINEPLOT , PlotRange->{{0,50},{0,800}}, AxesOrigin->{0,0}]

(Y==15*X+b)/.{X-> PTS[[1]][[1]],Y-> PTS[[1]][[2]]}

Solve[(Y==15*X+b)/.{X-> PTS[[1]][[1]],Y-> PTS[[1]][[2]]},b]

Solve[(Y==15*X+b)/.{X-> PTS[[2]][[1]],Y-> PTS[[2]][[2]]},b]

Solve[(Y==15*X+b)/.{X-> PTS[[3]][[1]],Y-> PTS[[3]][[2]]},b]