You are on page 1of 11

Query:

x^5+x^3-4x=0

Solution Video: Click here

Graph Video: Click here

Solution (Plain Text):

Solve for x over the real numbers:


x^5 + x^3 - 4 x = 0
Factor x from the left hand side:
x (x^4 + x^2 - 4) = 0
Split into two equations:
x = 0 or x^4 + x^2 - 4 = 0
Substitute y = x^2:
x = 0 or y^2 + y - 4 = 0
Add 4 to both sides:
x = 0 or y^2 + y = 4
Add 1/4 to both sides:
x = 0 or y^2 + y + 1/4 = 17/4
Write the left hand side as a square:
x = 0 or (y + 1/2)^2 = 17/4
Take the square root of both sides:
x = 0 or y + 1/2 = sqrt(17)/2 or y + 1/2 = -sqrt(17)/2
Subtract 1/2 from both sides:
x = 0 or y = sqrt(17)/2 - 1/2 or y + 1/2 = -sqrt(17)/2
Substitute back for y = x^2:
x = 0 or x^2 = sqrt(17)/2 - 1/2 or y + 1/2 = -sqrt(17)/2
Take the square root of both sides:
x = 0 or x = sqrt(sqrt(17)/2 - 1/2) or x = -sqrt(sqrt(17)/2 - 1/2) or y +
1/2 = -sqrt(17)/2
Subtract 1/2 from both sides:
x = 0 or x = sqrt(sqrt(17)/2 - 1/2) or x = -sqrt(sqrt(17)/2 - 1/2) or y =
-1/2 - sqrt(17)/2
Substitute back for y = x^2:
x = 0 or x = sqrt(sqrt(17)/2 - 1/2) or x = -sqrt(sqrt(17)/2 - 1/2) or x^2
= -1/2 - sqrt(17)/2
x^2 = -1/2 - sqrt(17)/2 has no solution since for all x on the real line,
x^2 >=0 and -1/2 - sqrt(17)/2<0:
Answer: x = 0 or x = +-sqrt(sqrt(17)/2 - 1/2)
Detected Graphable Function (inline Python):

x**5 + x**3 - 4*x

Detected Graph Ranges:

X-axis: (-2,2,1)
Y-axis: (-3,3,1)

Solution in LaTeX:

Solve \ for \ x: x^{5} + x^{3} - 4 x = 0


Factor \ x \ from \ the \ left \ hand \ side:
x (x^{4} + x^{2} - 4) = 0
Split \ into \ two \ equations:
x = 0 \ or \ x^{4} + x^{2} - 4 = 0
Substitute \ y = x^{2}:
x = 0 \ or \ y^{2} + y - 4 = 0
Add \ 4 \ to \ both \ sides:
x = 0 \ or \ y^{2} + y = 4
Add \ \frac{1}{4} \ to \ both \ sides:
x = 0 \ or \ y^{2} + y + \frac{1}{4} = \frac{17}{4}
Write \ the \ left \ hand \ side \ as \ a \ square:
x = 0 \ or \ \left(y + \frac{1}{2}\right)^{2} = \frac{17}{4}
Take \ the \ square \ root \ of \ both \ sides:
x = 0 \ or \ y + \frac{1}{2} = \frac{\sqrt{17}}{2} \ or \ y + \frac{1}{2}
= -\frac{\sqrt{17}}{2}
Subtract \ \frac{1}{2} \ from \ both \ sides:
x = 0 \ or \ y = \frac{\sqrt{17}}{2} - \frac{1}{2} \ or \ y + \frac{1}{2}
= -\frac{\sqrt{17}}{2}
Substitute \ back \ for \ y = x^{2}:
x = 0 \ or \ x^{2} = \frac{\sqrt{17}}{2} - \frac{1}{2} \ or \ y + \frac{1}
{2} = -\frac{\sqrt{17}}{2}
Take \ the \ square \ root \ of \ both \ sides:
x = 0 \ or \ x = \sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}} \ or \ x =
-\sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}} \ or \ y + \frac{1}{2} =
-\frac{\sqrt{17}}{2}
Subtract \ \frac{1}{2} \ from \ both \ sides:
x = 0 \ or \ x = \sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}} \ or \ x =
-\sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}} \ or \ y = -\frac{1}{2} -
\frac{\sqrt{17}}{2}
Substitute \ back \ for \ y = x^{2}:
x = 0 \ or \ x = \sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}} \ or \ x =
-\sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}} \ or \ x^{2} = -\frac{1}{2}
- \frac{\sqrt{17}}{2}
x^{2} = -\frac{1}{2} - \frac{\sqrt{17}}{2} \ has \ no \ solution \ since \
for \ all \ x \ on \ the \ real \ line, \ x^{2} \geq 0 \ and -\frac{1}{2}
- \frac{\sqrt{17}}{2} < 0:
Answer: x = 0 \ or \ x = \pm\sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}}

Python (Manim) code of Solution:

from manimlib.imports import *


from math import *
class Solution(GraphScene):
def construct(self):
watermark = ImageMobject("./assets/water_mark.png",opacity=0.7)
watermark.scale(1.5)
watermark.to_corner(DOWN+RIGHT, buff=0)
self.play(FadeIn(watermark))
Solve = TexMobject(r"Solve \ for \ x: x^{5} + x^{3} - 4 x = 0" )
Solve.to_edge(UP)
self.play(Write(Solve))
align_mark = TexMobject( r'abs', fill_opacity=0.00,height=0.5)
align_mark.next_to(Solve,DOWN)
self.wait(1)
R0 = TexMobject(r"Factor \ x \ from \ the \ left \ hand \ side:" )
if R0.get_height() > 1:
R0.set_height(height=1,stretch=False)
if R0.get_width() > 12:
R0.set_width(width=12,stretch=False)
R1 = TexMobject(r"x (x^{4} + x^{2} - 4) = 0" )
if R1.get_height() > 1:
R1.set_height(height=1,stretch=False)
if R1.get_width() > 12:
R1.set_width(width=12,stretch=False)
R2 = TexMobject(r"Split \ into \ two \ equations:" )
if R2.get_height() > 1:
R2.set_height(height=1,stretch=False)
if R2.get_width() > 12:
R2.set_width(width=12,stretch=False)
R3 = TexMobject(r"x = 0 \ or \ x^{4} + x^{2} - 4 = 0" )
if R3.get_height() > 1:
R3.set_height(height=1,stretch=False)
if R3.get_width() > 12:
R3.set_width(width=12,stretch=False)
R4 = TexMobject(r"Substitute \ y = x^{2}:" )
if R4.get_height() > 1:
R4.set_height(height=1,stretch=False)
if R4.get_width() > 12:
R4.set_width(width=12,stretch=False)
R5 = TexMobject(r"x = 0 \ or \ y^{2} + y - 4 = 0" )
if R5.get_height() > 1:
R5.set_height(height=1,stretch=False)
if R5.get_width() > 12:
R5.set_width(width=12,stretch=False)
R6 = TexMobject(r"Add \ 4 \ to \ both \ sides:" )
if R6.get_height() > 1:
R6.set_height(height=1,stretch=False)
if R6.get_width() > 12:
R6.set_width(width=12,stretch=False)
R7 = TexMobject(r"x = 0 \ or \ y^{2} + y = 4" )
if R7.get_height() > 1:
R7.set_height(height=1,stretch=False)
if R7.get_width() > 12:
R7.set_width(width=12,stretch=False)
R8 = TexMobject(r"Add \ \frac{1}{4} \ to \ both \ sides:" )
if R8.get_height() > 1:
R8.set_height(height=1,stretch=False)
if R8.get_width() > 12:
R8.set_width(width=12,stretch=False)
R9 = TexMobject(r"x = 0 \ or \ y^{2} + y + \frac{1}{4} = \frac{17}
{4}" )
if R9.get_height() > 1:
R9.set_height(height=1,stretch=False)
if R9.get_width() > 12:
R9.set_width(width=12,stretch=False)
R10 = TexMobject(r"Write \ the \ left \ hand \ side \ as \ a \ square:"
)
if R10.get_height() > 1:
R10.set_height(height=1,stretch=False)
if R10.get_width() > 12:
R10.set_width(width=12,stretch=False)
R11 = TexMobject(r"x = 0 \ or \ \left(y + \frac{1}{2}\right)^{2} =
\frac{17}{4}" )
if R11.get_height() > 1:
R11.set_height(height=1,stretch=False)
if R11.get_width() > 12:
R11.set_width(width=12,stretch=False)
R12 = TexMobject(r"Take \ the \ square \ root \ of \ both \ sides:" )
if R12.get_height() > 1:
R12.set_height(height=1,stretch=False)
if R12.get_width() > 12:
R12.set_width(width=12,stretch=False)
R13 = TexMobject(r"x = 0 \ or \ y + \frac{1}{2} = \frac{\sqrt{17}}{2} \
or \ y + \frac{1}{2} = -\frac{\sqrt{17}}{2}" )
if R13.get_height() > 1:
R13.set_height(height=1,stretch=False)
if R13.get_width() > 12:
R13.set_width(width=12,stretch=False)
R14 = TexMobject(r"Subtract \ \frac{1}{2} \ from \ both \ sides:" )
if R14.get_height() > 1:
R14.set_height(height=1,stretch=False)
if R14.get_width() > 12:
R14.set_width(width=12,stretch=False)
R15 = TexMobject(r"x = 0 \ or \ y = \frac{\sqrt{17}}{2} - \frac{1}{2} \
or \ y + \frac{1}{2} = -\frac{\sqrt{17}}{2}" )
if R15.get_height() > 1:
R15.set_height(height=1,stretch=False)
if R15.get_width() > 12:
R15.set_width(width=12,stretch=False)
R16 = TexMobject(r"Substitute \ back \ for \ y = x^{2}:" )
if R16.get_height() > 1:
R16.set_height(height=1,stretch=False)
if R16.get_width() > 12:
R16.set_width(width=12,stretch=False)
R17 = TexMobject(r"x = 0 \ or \ x^{2} = \frac{\sqrt{17}}{2} - \frac{1}
{2} \ or \ y + \frac{1}{2} = -\frac{\sqrt{17}}{2}" )
if R17.get_height() > 1:
R17.set_height(height=1,stretch=False)
if R17.get_width() > 12:
R17.set_width(width=12,stretch=False)
R18 = TexMobject(r"Take \ the \ square \ root \ of \ both \ sides:" )
if R18.get_height() > 1:
R18.set_height(height=1,stretch=False)
if R18.get_width() > 12:
R18.set_width(width=12,stretch=False)
R19 = TexMobject(r"x = 0 \ or \ x = \sqrt{ \frac{\sqrt{17}}{2} -
\frac{1}{2}} \ or \ x = -\sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}} \ or \
y + \frac{1}{2} = -\frac{\sqrt{17}}{2}" )
if R19.get_height() > 1:
R19.set_height(height=1,stretch=False)
if R19.get_width() > 12:
R19.set_width(width=12,stretch=False)
R20 = TexMobject(r"Subtract \ \frac{1}{2} \ from \ both \ sides:" )
if R20.get_height() > 1:
R20.set_height(height=1,stretch=False)
if R20.get_width() > 12:
R20.set_width(width=12,stretch=False)
R21 = TexMobject(r"x = 0 \ or \ x = \sqrt{ \frac{\sqrt{17}}{2} -
\frac{1}{2}} \ or \ x = -\sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}} \ or \
y = -\frac{1}{2} - \frac{\sqrt{17}}{2}" )
if R21.get_height() > 1:
R21.set_height(height=1,stretch=False)
if R21.get_width() > 12:
R21.set_width(width=12,stretch=False)
R22 = TexMobject(r"Substitute \ back \ for \ y = x^{2}:" )
if R22.get_height() > 1:
R22.set_height(height=1,stretch=False)
if R22.get_width() > 12:
R22.set_width(width=12,stretch=False)
R23 = TexMobject(r"x = 0 \ or \ x = \sqrt{ \frac{\sqrt{17}}{2} -
\frac{1}{2}} \ or \ x = -\sqrt{ \frac{\sqrt{17}}{2} - \frac{1}{2}} \ or \
x^{2} = -\frac{1}{2} - \frac{\sqrt{17}}{2}" )
if R23.get_height() > 1:
R23.set_height(height=1,stretch=False)
if R23.get_width() > 12:
R23.set_width(width=12,stretch=False)
R24 = TexMobject(r"x^{2} = -\frac{1}{2} - \frac{\sqrt{17}}{2} \ has \
no \ solution \ since \ for \ all \ x \ on \ the \ real \ line, \ x^{2}
\geq 0 \ and -\frac{1}{2} - \frac{\sqrt{17}}{2} < 0:" )
if R24.get_height() > 1:
R24.set_height(height=1,stretch=False)
if R24.get_width() > 12:
R24.set_width(width=12,stretch=False)
R25 = TexMobject(r"Answer: x = 0 \ or \ x = \pm\sqrt{ \frac{\sqrt{17}}
{2} - \frac{1}{2}}" )
if R25.get_height() > 1:
R25.set_height(height=1,stretch=False)
if R25.get_width() > 12:
R25.set_width(width=12,stretch=False)
R26 = TexMobject(r"." )
if R26.get_height() > 1:
R26.set_height(height=1,stretch=False)
if R26.get_width() > 12:
R26.set_width(width=12,stretch=False)
R0.next_to(align_mark,DOWN)
self.play(Write(R0))
self.wait(1)
R1.next_to(R0, DOWN)
self.play(Write(R1))
self.wait(1)
R2.next_to(R1, DOWN)
self.play(Write(R2))
self.wait(1)
self.play(FadeOut(R0))
self.play(ApplyMethod(R1.next_to,align_mark,DOWN))
self.play(ApplyMethod(R2.next_to,R1, DOWN))
R3.next_to(R2, DOWN)
self.play(Write(R3))
self.play(FadeOut(R1))
self.play(ApplyMethod(R2.next_to,align_mark,DOWN))
self.play(ApplyMethod(R3.next_to,R2, DOWN))
R4.next_to(R3, DOWN)
self.play(Write(R4))
self.play(FadeOut(R2))
self.play(ApplyMethod(R3.next_to,align_mark,DOWN))
self.play(ApplyMethod(R4.next_to,R3, DOWN))
R5.next_to(R4, DOWN)
self.play(Write(R5))
self.play(FadeOut(R3))
self.play(ApplyMethod(R4.next_to,align_mark,DOWN))
self.play(ApplyMethod(R5.next_to,R4, DOWN))
R6.next_to(R5, DOWN)
self.play(Write(R6))
self.play(FadeOut(R4))
self.play(ApplyMethod(R5.next_to,align_mark,DOWN))
self.play(ApplyMethod(R6.next_to,R5, DOWN))
R7.next_to(R6, DOWN)
self.play(Write(R7))
self.play(FadeOut(R5))
self.play(ApplyMethod(R6.next_to,align_mark,DOWN))
self.play(ApplyMethod(R7.next_to,R6, DOWN))
R8.next_to(R7, DOWN)
self.play(Write(R8))
self.play(FadeOut(R6))
self.play(ApplyMethod(R7.next_to,align_mark,DOWN))
self.play(ApplyMethod(R8.next_to,R7, DOWN))
R9.next_to(R8, DOWN)
self.play(Write(R9))
self.play(FadeOut(R7))
self.play(ApplyMethod(R8.next_to,align_mark,DOWN))
self.play(ApplyMethod(R9.next_to,R8, DOWN))
R10.next_to(R9, DOWN)
self.play(Write(R10))
self.play(FadeOut(R8))
self.play(ApplyMethod(R9.next_to,align_mark,DOWN))
self.play(ApplyMethod(R10.next_to,R9, DOWN))
R11.next_to(R10, DOWN)
self.play(Write(R11))
self.play(FadeOut(R9))
self.play(ApplyMethod(R10.next_to,align_mark,DOWN))
self.play(ApplyMethod(R11.next_to,R10, DOWN))
R12.next_to(R11, DOWN)
self.play(Write(R12))
self.play(FadeOut(R10))
self.play(ApplyMethod(R11.next_to,align_mark,DOWN))
self.play(ApplyMethod(R12.next_to,R11, DOWN))
R13.next_to(R12, DOWN)
self.play(Write(R13))
self.play(FadeOut(R11))
self.play(ApplyMethod(R12.next_to,align_mark,DOWN))
self.play(ApplyMethod(R13.next_to,R12, DOWN))
R14.next_to(R13, DOWN)
self.play(Write(R14))
self.play(FadeOut(R12))
self.play(ApplyMethod(R13.next_to,align_mark,DOWN))
self.play(ApplyMethod(R14.next_to,R13, DOWN))
R15.next_to(R14, DOWN)
self.play(Write(R15))
self.play(FadeOut(R13))
self.play(ApplyMethod(R14.next_to,align_mark,DOWN))
self.play(ApplyMethod(R15.next_to,R14, DOWN))
R16.next_to(R15, DOWN)
self.play(Write(R16))
self.play(FadeOut(R14))
self.play(ApplyMethod(R15.next_to,align_mark,DOWN))
self.play(ApplyMethod(R16.next_to,R15, DOWN))
R17.next_to(R16, DOWN)
self.play(Write(R17))
self.play(FadeOut(R15))
self.play(ApplyMethod(R16.next_to,align_mark,DOWN))
self.play(ApplyMethod(R17.next_to,R16, DOWN))
R18.next_to(R17, DOWN)
self.play(Write(R18))
self.play(FadeOut(R16))
self.play(ApplyMethod(R17.next_to,align_mark,DOWN))
self.play(ApplyMethod(R18.next_to,R17, DOWN))
R19.next_to(R18, DOWN)
self.play(Write(R19))
self.play(FadeOut(R17))
self.play(ApplyMethod(R18.next_to,align_mark,DOWN))
self.play(ApplyMethod(R19.next_to,R18, DOWN))
R20.next_to(R19, DOWN)
self.play(Write(R20))
self.play(FadeOut(R18))
self.play(ApplyMethod(R19.next_to,align_mark,DOWN))
self.play(ApplyMethod(R20.next_to,R19, DOWN))
R21.next_to(R20, DOWN)
self.play(Write(R21))
self.play(FadeOut(R19))
self.play(ApplyMethod(R20.next_to,align_mark,DOWN))
self.play(ApplyMethod(R21.next_to,R20, DOWN))
R22.next_to(R21, DOWN)
self.play(Write(R22))
self.play(FadeOut(R20))
self.play(ApplyMethod(R21.next_to,align_mark,DOWN))
self.play(ApplyMethod(R22.next_to,R21, DOWN))
R23.next_to(R22, DOWN)
self.play(Write(R23))
self.play(FadeOut(R21))
self.play(ApplyMethod(R22.next_to,align_mark,DOWN))
self.play(ApplyMethod(R23.next_to,R22, DOWN))
R24.next_to(R23, DOWN)
self.play(Write(R24))
self.play(FadeOut(R22))
self.play(ApplyMethod(R23.next_to,align_mark,DOWN))
self.play(ApplyMethod(R24.next_to,R23, DOWN))
R25.next_to(R24, DOWN)
self.play(Write(R25))
self.play(FadeOut(R23))
self.play(ApplyMethod(R24.next_to,align_mark,DOWN))
self.play(ApplyMethod(R25.next_to,R24, DOWN))
R26.next_to(R25, DOWN)
self.play(Write(R26))
self.wait(2)
self.play(FadeOut(R26))
self.play(FadeOut(R25))
self.play(FadeOut(R24))
self.play(FadeOut(Solve))
self.play(ApplyMethod(watermark.next_to,align_mark,DOWN))
self.play(FadeOut(watermark))

Python (Manim) code of Graph:

from manimlib.imports import *


from math import *
class Solution(GraphScene):
CONFIG = {
'graph_origin': ORIGIN,
'function_color': WHITE,
'axes_color': BLUE,
'x_min': -2,
'x_max': 2,
'x_labeled_nums' :range(-2,2,1),
'y_min': -3,
'y_max': 3,
'y_labeled_nums' :range(-3,3,1)}

def construct(self):
watermark = ImageMobject("./assets/water_mark.png",opacity=0.7)
watermark.scale(1.5)
watermark.to_corner(DOWN+RIGHT, buff=0)
self.play(FadeIn(watermark))
Solve = TexMobject(r" plot x^{5} + x^{3} - 4 x = 0" )
Solve.to_edge(UP)
self.play(Write(Solve))
align_mark = TexMobject( r'abs', fill_opacity=0.00,height=0.5)
align_mark.next_to(Solve,DOWN)
self.wait(1)
self.wait(2)
self.play(FadeOut(Solve))
self.setup_axes(animate=True)
func_graph = self.get_graph(self.func, self.function_color)
self.play(ShowCreation(func_graph))
self.play(FadeOut(func_graph))
self.play(FadeOut(self.axes))
self.play(ApplyMethod(watermark.next_to,align_mark,DOWN))
self.play(FadeOut(watermark))

def func(self, x):


f = x**5 + x**3 - 4*x

return f

You might also like