Input n:

Move yellow points.
Move green sliders.

                              =                                      ×     

=

×

Pink line slope

green line length

interval width

s(t)=5t^3

s'(t)=15t^2

=\frac{1}{k}\sum_{0}^{k-1}{\frac{s(t-m+\frac{(m+n)(p+1)}{k})-s(t-m+\frac{(m+n)p}{k})}{\frac{m+n}{k}} } 

Proof of the mean value theorem:

\frac{1}{k}\sum_{1}^{k}{s'(\mu_p)

\int_{t-m}^{t+n}{ s'(t)dt}=s(t+n)-s(t-m)=\frac{1}{k}\sum_{1}^{k}{s'(\mu_p)

{

{

Gray shaded area =

average length of red lines

×

interval width

Show auxiliary equation

s(t) = (5 * t^(3))
D = Point(xAxis)
C = Point(xAxis)
v(t) = (15 * (t - 2)^(2))
n = 3 (slider from 1 to 240, step 1)
beg: x(C)
end: x(D)
diff: end - beg
B: (beg, s(beg))
A: (end, s(end))
Primf = Sequence(Segment[(p, 0), (p, s(p))], p, beg, end, diff / n)
xv(x) = 2 + x
E: (xv(x(C)), 0)
F: (xv(x(D)), 0)
G: (x(E), v(x(E)))
H: (x(F), v(x(F)))
a = Segment(G, E)
b = Segment(H, F)
c = Segment(B, C)
d = Segment(D, A)
e = Segment(A, B)
ar = Integral(v, xv(x(C)), xv(x(D)))
grd: (Slope[e] * diff)
mv: grd / diff
tcoord: sqrt(mv / 15)
I: (xv(tcoord), 0)
J: (x(I), v(x(I)))
f = Segment(J, I)
inputBox1 = Textfield(n)
derf = Sequence(Segment[(xv(p), 0), (xv(p), v(xv(p)))], p, beg, end, diff / (n + 1))
text3: "" + (LaTeX[grd]) + ""
text6: "" + (LaTeX[f]) + ""
g = Segment(C, D)
text8: "" + (LaTeX[diff]) + ""
k = 1 (slider from 1 to 4, step 1)
xC: x(C)
m(n) = (n + (3 * tcoord) - sqrt((n + (3 * tcoord))^(2) - (4 * (((3 * tcoord) * n) + n^(2))))) / 2
mval: tcoord - x(C)
nval: x(D) - tcoord
mplusn: mval + nval
xD: x(D)
fC: s(xC)
fD: s(xD)
tminusm: tcoord - mval
mplusndivk: mplusn / k
tplusn: tcoord + nval
text15: "\frac{ s(" + (LaTeX[tminusm]) + "+\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})  -   s(" + (LaTeX[tminusm]) + ")}{ \frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "}}  + \frac{  s(" + (LaTeX[tminusm]) + "+\frac{2×" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})-s(" + (LaTeX[tminusm]) + "+\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})  }{\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "} } "
text27: "=\frac{s(" + (LaTeX[xD]) + ")-s(" + (LaTeX[xC]) + ")}{" + (LaTeX[mplusn]) + "}=" + (LaTeX[mv]) + ""
rr: (fD - fC) / mplusn
text18: " \frac{s(" + (LaTeX[tcoord]) + "-" + (LaTeX[mval]) + "+" + (LaTeX[mplusn]) + ")-s(" + (LaTeX[tcoord]) + "-" + (LaTeX[mval]) + ")}{" + (LaTeX[mplusn]) + "}=\frac{s(" + (LaTeX[xD]) + ")-s(" + (LaTeX[xC]) + ")}{" + (LaTeX[mplusn]) + "}
 "
text32: "\frac{s(" + (LaTeX[tminusm]) + "+\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})-s(" + (LaTeX[tminusm]) + ")}{\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "}}+\frac{s(" + (LaTeX[tminusm]) + "+\frac{2×" + (LaTeX[mplusn]) + "}{{" + (LaTeX[k]) + "}})-s(" + (LaTeX[tminusm]) + "+\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})}{\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "}}+"
text17: "=\frac{s(" + (LaTeX[tminusm]) + "+\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})-s(" + (LaTeX[tminusm]) + ")}{\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "}} + \frac{s(" + (LaTeX[tminusm]) + "+\frac{2×" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})-s(" + (LaTeX[tminusm]) + "+\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})}{\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "}}+"
text19: "+\frac{s(" + (LaTeX[tminusm]) + "+\frac{3×" + (LaTeX[mplusn]) + " }{" + (LaTeX[k]) + " })-s( " + (LaTeX[tminusm]) + "+\frac{2×" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})}{\frac{ " + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + " }}+\frac{s(" + (LaTeX[tminusm]) + "+\frac{4×" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})-s(" + (LaTeX[tminusm]) + "+\frac{3×" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})}{\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "}}"
text20: "=\frac{s(" + (LaTeX[fD]) + ")-s(" + (LaTeX[fC]) + ")}{" + (LaTeX[mplusn]) + "}=" + (LaTeX[mv]) + ""
text28: "=\frac{" + (LaTeX[fD]) + "-" + (LaTeX[fC]) + "}{" + (LaTeX[mval]) + "}=" + (LaTeX[mv]) + ""
text31: "+\frac{s(" + (LaTeX[tminusm]) + "+\frac{3×" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})-s(" + (LaTeX[tminusm]) + "+\frac{2×" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "})}{\frac{" + (LaTeX[mplusn]) + "}{" + (LaTeX[k]) + "}}=\frac{s(" + (LaTeX[xD]) + ")-s(" + (LaTeX[xC]) + ")}{" + (LaTeX[mplusn]) + "}=" + (LaTeX[mv]) + ""
top: s(tplusn) - s(tminusm)
text23: "s'(t)=\frac{s(t+n)-s(t-m)}{m+n}=s'(" + (LaTeX[tcoord]) + ")=\frac{s(" + (LaTeX[tplusn]) + ")-s(" + (LaTeX[tminusm]) + ")}{" + (LaTeX[mplusn]) + "}=\frac{" + (LaTeX[top]) + "}{" + (LaTeX[mplusn]) + "}=" + (LaTeX[mv]) + ""
h = Segment(E, F)
mn(n) = (n + (3 * tcoord) + sqrt((n + (3 * tcoord))^(2) - (4 * (((3 * tcoord) * n) + n^(2))))) / 2
i = false