Find the cubic polynomial \( f(x) \) such that \( f(1) = 3 \), \( f(2) = -1 \), \( f(3) = 2 \), and \( f(4) = 5 \).

["# Find the Cubic Polynomial ( f(x) ) Given Four Points", "When tasked with determining a polynomial passing through specific points, cubic polynomials often provide a precise fit due to their flexibility. In this article, we’ll explore how to find the unique cubic polynomial ( f(x) = ax^3 + bx^2 + cx + d ) satisfying:", "[\n\begin{cases}\nf(1) = 3 \\nf(2) = -1 \\nf(3) = 2 \\nf(4) = 5\n\end{cases}\n]", "By using the given values, we construct a system of equations and solve for the coefficients ( a ), ( b ), ( c ), and ( d ). Whether you're a student, teacher, or self-learner, this step-by-step guide will help you understand how to determine a cubic polynomial from point data.", "## Step 1: Set Up the General Form", "Assume the cubic polynomial is:", "[\nf(x) = ax^3 + bx^2 + cx + d\n]", "We substitute each of the four given points into this equation to form a system of equations:", "1. For ( x = 1 ), ( f(1) = 3 ):", "[\na(1)^3 + b(1)^2 + c(1) + d = 3 \quad \Rightarrow \quad a + b + c + d = 3 \quad \ ext{(Equation 1)}\n]", "2. For ( x = 2 ), ( f(2) = -1 ):", "[\na(8) + b(4) + c(2) + d = -1 \quad \Rightarrow \quad 8a + 4b + 2c + d = -1 \quad \ ext{(Equation 2)}\n]", "3. For ( x = 3 ), ( f(3) = 2 ):", "[\na(27) + b(9) + c(3) + d = 2 \quad \Rightarrow \quad 27a + 9b + 3c + d = 2 \quad \ ext{(Equation 3)}\n]", "4. For ( x = 4 ), ( f(4) = 5 ):", "[\na(64) + b(16) + c(4) + d = 5 \quad \Rightarrow \quad 64a + 16b + 4c + d = 5 \quad \ ext{(Equation 4)}\n]", "## Step 2: Solve the System of Equations", "We now solve the system of four linear equations:", "[\n\begin{cases}\n(1) & a + b + c + d = 3 \\n(2) & 8a + 4b + 2c + d = -1 \\n(3) & 27a + 9b + 3c + d = 2 \\n(4) & 64a + 16b + 4c + d = 5 \\n\end{cases}\n]", "Subtract Equation (1) from Equation (2):", "[\n(8a + 4b + 2c + d) - (a + b + c + d) = -1 - 3\n]\n[\n7a + 3b + c = -4 \quad \ ext{(Equation 5)}\n]", "Subtract Equation (2) from Equation (3):", "[\n(27a + 9b + 3c + d) - (8a + 4b + 2c + d) = 2 - (-1)\n]\n[\n19a + 5b + c = 3 \quad \ ext{(Equation 6)}\n]", "Subtract Equation (3) from Equation (4):", "[\n(64a + 16b + 4c + d) - (27a + 9b + 3c + d) = 5 - 2\n]\n[\n37a + 7b + c = 3 \quad \ ext{(Equation 7)}\n]", "Now subtract Equation (5) from Equation (6):", "[\n(19a + 5b + c) - (7a + 3b + c) = 3 - (-4)\n]\n[\n12a + 2b = 7 \quad \ ext{(Equation 8)}\n]", "Subtract Equation (6) from Equation (7):", "[\n(37a + 7b + c) - (19a + 5b + c) = 3 - 3\n]\n[\n18a + 2b = 0 \quad \ ext{(Equation 9)}\n]", "Now solve Equations (8) and (9) simultaneously:", "From Equation (9):\n[\n18a + 2b = 0 \quad \Rightarrow \quad 9a + b = 0 \quad \Rightarrow \quad b = -9a\n]", "Substitute ( b = -9a ) into Equation (8):", "[\n12a + 2(-9a) = 7 \quad \Rightarrow \quad 12a - 18a = 7 \quad \Rightarrow \quad -6a = 7 \quad \Rightarrow \quad a = -\frac{7}{6}\n]", "Now find ( b ):", "[\nb = -9 \left( -\frac{7}{6} \right) = \frac{63}{6} = \frac{21}{2}\n]", "Now use Equation (5) to find ( c ):", "[\n7a + 3b + c = -4\n]\n[\n7\left(-\frac{7}{6}\right) + 3\left(\frac{21}{2}\right) + c = -4\n]\n[\n-\frac{49}{6} + \frac{63}{2} + c = -4\n]", "Convert to common denominator (6):", "[\n-\frac{49}{6} + \frac{189}{6} + c = -4 \quad \Rightarrow \quad \frac{140}{6} + c = -4 \quad \Rightarrow \quad \frac{70}{3} + c = -4\n]\n[\nc = -4 - \frac{70}{3} = -\frac{12}{3} - \frac{70}{3} = -\frac{82}{3}\n]", "Now use Equation (1) to find ( d ):", "[\na + b + c + d = 3\n]\n[\n-\frac{7}{6} + \frac{21}{2} - \frac{82}{3} + d = 3\n]", "Convert all terms to denominator 6:", "[\n-\frac{7}{6} + \frac{63}{6} - \frac{164}{6} + d = 3 \quad \Rightarrow \quad \frac{-7 + 63 - 164}{6} + d = 3\n]\n[\n\frac{-108}{6} + d = 3 \quad \Rightarrow \quad -18 + d = 3 \quad \Rightarrow \quad d = 21\n]", "## Step 3: Write the Final Polynomial", "Putting all coefficients together:", "[\nf(x) = -\frac{7}{6}x^3 + \frac{21}{2}x^2 - \frac{82}{3}x + 21\n]", "---", "## Alternative Verification: Using Lagrange Interpolation", "While solving a system is efficient, another powerful method is Lagrange interpolation, which builds the polynomial directly from known points.", "The Lagrange form for four points ( (x_i, y_i) ) is:", "[\nf(x) = \sum_{i=1}^{4} y_i \cdot L_i(x), \quad \ ext{where} \quad L_i(x) = \prod_{\substack{j=1\j <br/>\ne i}}^{4} \frac{x - x_j}{x_i - x_j}\n]", "With ( (1,3), (2,-1), (3,2), (4,5) ), compute each ( L_i(x) ) and combine:", "Compute ( L_1(x) ) (for ( x=1 )):", "[\nL_1(x) = \frac{(x-2)(x-3)(x-4)}{(1-2)(1-3)(1-4)} = \frac{(x-2)(x-3)(x-4)}{(-1)(-2)(-3)} = -\frac{(x-2)(x-3)(x-4)}{6}\n]", "Similarly compute ( L_2(x) ), ( L_3(x) ), ( L_4(x) ), then:", "[\nf(x) = 3L_1(x) + (-1)L_2(x) + 2L_3(x) + 5L_4(x)\n]", "After expanding each cubic term and combining like terms, this method yields the same polynomial as obtained by elimination:", "[\nf(x) = -\frac{7}{6}x^3 + \frac{21}{2}x^2 - \frac{82}{3}x + 21\n]", "---", "## Conclusion", "We’ve determined the unique cubic polynomial ( f(x) ) that satisfies the four conditions:", "[\nf(x) = -\frac{7}{6}x^3 + \frac{21}{2}x^2 - \frac{82}{3}x + 21\n]", "This polynomial models data in fields such as physics, finance, and engineering where precise fitting of discrete measurements to a continuous function is required. For verification, plugging ( x = 1,2,3,4 ) confirms each ( f(x) ) matches the given value. Use this method to approach any problem involving cubic interpolation with known function values.", "---", "### Want to Build Your Own?", "Use this template:", "1. Assume ( f(x) = ax^3 + bx^2 + cx + d )\n2. Plug in each point to form equations\n3. Solve the linear system via substitution or elimination\n4. Confirm with polynomial expansion or computational tools", "Mastering this technique enables accurate modeling from discrete data — essential for scientific computation and curve fitting.", "---", "Keywords: cubic polynomial, find ( f(x) ), interpolation, cubic equation, solve system of equations, polynomial fitting, algebraic method, Lagrange interpolation, polynomial coefficients, ( f(1)=3 ), ( f(2)=-1 ), ( f(3)=2 ), ( f(4)=5 )"]









