**Find an equation of a cubic function whose graph is going through (3,0) and (1,4) and is tangent to the x-axis at the origin**

**Answer:**

Let cubic function be f(x)=ax^3+bx^2+cx+d,

since it passes through (3,0) , f(3)=0

since it passes through (1,4) , f(1)=4

it is tangent to origin at (0,0) is equivalent to say that the function has double roots. zero and zero. i.e f^(1)(0)=0, f(0)=0.

27a+9b+3c+d=0

a+b+c+d=4

f^(1)(x)=derivative of f(x)=3ax^2+2bx+c

f^(1)(0)=c. c=0

f(0)=d d=0

27a+9b=0

a+b=4

solving we get a=-2, b=6

f(x)=-2x^(3)+6x^(2) this is the required cubic function.