l0[x_]:=((x-0.5)(x-1)(x-1.5))/((0-0.5)(0-1)(0-1.5))

l1[x_]:=((x-0)(x-1)(x-1.5))/((0.5-0)(0.5-1)(0.5-1.5))

l2[x_]:=((x-0)(x-0.5)(x-1.5))/((1-0)(1-0.5)(1-1.5))

l3[x_]:=((x-0)(x-0.5)(x-1))/((1.5-0)(1.5-0.5)(1.5-1))

ln[x]=l0[x]*1+l1[x]*2+l2[x]*3+l3[x]*4

Simplify[ln[x]]

Solve[{a 0^3+b 0^2+c 0+d==1,a 0.5^3+b 0.5^2+c 0.5+d==2, a 1^3+b 1^2+c 1+d==3, a 1.5^3+b 1.5^2+c 1.5+d==4},{a,b,c,d}]

r0 [x_]:=((x-0.1)(x-0.2)(x-0.3))/((0-0.1)(0-0.2)(0-0.3))

r1[x_]:=((x-0)(x-0.2)(x-0.3))/((0.1-0)(0.1-0.2)(0.1-0.3))

r2[x_]:=((x-0)(x-0.1)(x-0.3))/((0.2-0)(0.2-0.1)(0.2-0.3))

r3[x_]:=((x-0)(x-0.1)(x-0.2))/((0.3-0)(0.3-0.1)(0.3-0.2))

r[x_]=E^0*r0[x]+E^0.1*r1[x]+E^0.2*r2[x]+E^0.3*r3[x]

Simplify[r[x]]

%/.x->0.15

w[x_]:=(x-0)(x-0.1)(x-0.2)(x-0.3)

Greshka=(Max[E^0,E^3]/4!)*w[0.15]

f[x_]=E^x

f[0.15]

N[%13]-N[%7]