simplifyAssertEq(lim(x, x, a), a)
${{\underset{ x\rightarrow a}{\lim}}{{x}}} = {a}$
GOOD
time: 1.442000ms
stack: size: 10
  • Init
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(x, x, a, '+'), a)
${{\underset{ x\rightarrow{ a{}^+}}{\lim}}{{x}}} = {a}$
GOOD
time: 0.483000ms
stack: size: 8
  • Init
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(x, x, a, '-'), a)
${{\underset{ x\rightarrow{ a{}^-}}{\lim}}{{x}}} = {a}$
GOOD
time: 0.989000ms
stack: size: 8
  • Init
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

constants

simplifyAssertEq(lim(0, x, a), 0)
${{\underset{ x\rightarrow a}{\lim}}{{0}}} = {0}$
GOOD
time: 2.003000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(1, x, a), 1)
${{\underset{ x\rightarrow a}{\lim}}{{1}}} = {1}$
GOOD
time: 2.013000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

ops

simplifyAssertEq(lim(x + 2, x, a), a + 2)
${{\underset{ x\rightarrow a}{\lim}}{{\left({{x} + {2}}\right)}}} = {{a} + {2}}$
GOOD
time: 10.662000ms
stack: size: 9
  • Init
  • +:Prune:combineConstants
  • Prune
  • Expand
  • Prune
  • +:Factor:apply
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(x + x, x, a), 2 * a)
${{\underset{ x\rightarrow a}{\lim}}{{\left({{x} + {x}}\right)}}} = {{{2}} {{a}}}$
GOOD
time: 7.091000ms
stack: size: 8
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(x + a, x, a), 2 * a)
${{\underset{ x\rightarrow a}{\lim}}{{\left({{x} + {a}}\right)}}} = {{{2}} {{a}}}$
GOOD
time: 7.187000ms
stack: size: 8
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(a + a, x, a), 2 * a)
${{\underset{ x\rightarrow a}{\lim}}{{\left({{a} + {a}}\right)}}} = {{{2}} {{a}}}$
GOOD
time: 9.154000ms
stack: size: 8
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(x * 2, x, a), 2 * a)
${{\underset{ x\rightarrow a}{\lim}}{{\left({{{x}} {{2}}}\right)}}} = {{{2}} {{a}}}$
GOOD
time: 9.676000ms
stack: size: 8
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(x / 2, x, a), a / 2)
${{\underset{ x\rightarrow a}{\lim}}{{{\frac{1}{2}} {x}}}} = {{\frac{1}{2}} {a}}$
GOOD
time: 7.851000ms
stack: size: 14
  • Init
  • Prune
  • Expand
  • Prune
  • /:Factor:polydiv
  • Factor
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • ^:Prune:xToTheZero
  • *:Prune:apply
  • /:Prune:divToPowSub
  • *:Prune:factorDenominators
  • Prune
  • Tidy

involving infinity

simplifyAssertEq(lim(x, x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{x}}} = {\infty}$
GOOD
time: 0.798000ms
stack: size: 8
  • Init
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(x, x, -inf), -inf)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{x}}} = {-{\infty}}$
GOOD
time: 1.921000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(x, x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{x}}} = {\infty}$
GOOD
time: 0.491000ms
stack: size: 8
  • Init
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(1/x, x, inf), 0)
${{\underset{ x\rightarrow \infty}{\lim}}{{\frac{1}{x}}}} = {0}$
GOOD
time: 1.986000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(1/x, x, -inf), 0)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\frac{1}{x}}}} = {0}$
GOOD
time: 2.005000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(1/x, x, 0), invalid)
${{\underset{ x\rightarrow 0}{\lim}}{{\frac{1}{x}}}} = {¿}$
GOOD
time: 3.201000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(1/x, x, 0, '+'), inf)
${{\underset{ x\rightarrow{ 0{}^+}}{\lim}}{{\frac{1}{x}}}} = {\infty}$
GOOD
time: 0.947000ms
stack: size: 9
  • Init
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(1/x, x, 0, '-'), -inf)
${{\underset{ x\rightarrow{ 0{}^-}}{\lim}}{{\frac{1}{x}}}} = {-{\infty}}$
GOOD
time: 3.131000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy


simplifyAssertEq(lim(1/x^2, x, 0, '+'), inf)
${{\underset{ x\rightarrow{ 0{}^+}}{\lim}}{{\frac{1}{{x}^{2}}}}} = {\infty}$
GOOD
time: 9.632000ms
stack: size: 11
  • Init
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(1/x^2, x, 0, '-'), inf)
${{\underset{ x\rightarrow{ 0{}^-}}{\lim}}{{\frac{1}{{x}^{2}}}}} = {\infty}$
GOOD
time: 9.357000ms
stack: size: 11
  • Init
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

sqrts

simplifyAssertEq(lim(sqrt(x), x, 0), invalid)
${{\underset{ x\rightarrow 0}{\lim}}{{\sqrt{x}}}} = {¿}$
GOOD
time: 2.396000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(sqrt(x), x, 0, '-'), invalid)
${{\underset{ x\rightarrow{ 0{}^-}}{\lim}}{{\sqrt{x}}}} = {¿}$
GOOD
time: 2.242000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(sqrt(x), x, 0, '+'), 0)
${{\underset{ x\rightarrow{ 0{}^+}}{\lim}}{{\sqrt{x}}}} = {0}$
GOOD
time: 1.694000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy
in each form ...

simplifyAssertEq(lim(x^frac(1,2), x, 0), invalid)
${{\underset{ x\rightarrow 0}{\lim}}{{{x}^{\frac{1}{2}}}}} = {¿}$
GOOD
time: 2.245000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(x^frac(1,2), x, 0, '-'), invalid)
${{\underset{ x\rightarrow{ 0{}^-}}{\lim}}{{{x}^{\frac{1}{2}}}}} = {¿}$
GOOD
time: 1.598000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(x^frac(1,2), x, 0, '+'), 0)
${{\underset{ x\rightarrow{ 0{}^+}}{\lim}}{{{x}^{\frac{1}{2}}}}} = {0}$
GOOD
time: 1.714000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy
and one more power up ...

simplifyAssertEq(lim(x^frac(1,4), x, 0), invalid)
${{\underset{ x\rightarrow 0}{\lim}}{{{x}^{\frac{1}{4}}}}} = {¿}$
GOOD
time: 1.204000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(x^frac(1,4), x, 0, '-'), invalid)
${{\underset{ x\rightarrow{ 0{}^-}}{\lim}}{{{x}^{\frac{1}{4}}}}} = {¿}$
GOOD
time: 1.033000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(x^frac(1,4), x, 0, '+'), 0)
${{\underset{ x\rightarrow{ 0{}^+}}{\lim}}{{{x}^{\frac{1}{4}}}}} = {0}$
GOOD
time: 1.871000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


functions

TODO all of these are only good for 'a' in Real, not necessarily extended-Real, because I don't distinguish them

another thing to consider ... most these are set up so that the limit is the same as the evaluation without a limit
technically this is not true. technically atan(inf) is not pi/2 but is instead undefined outside of the limit.
should I enforce this?

simplifyAssertEq(lim(sin(x), x, a), sin(a))
${{\underset{ x\rightarrow a}{\lim}}{{\sin\left( x\right)}}} = {\sin\left( a\right)}$
GOOD
time: 2.475000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(sin(x), x, inf), invalid)
${{\underset{ x\rightarrow \infty}{\lim}}{{\sin\left( x\right)}}} = {¿}$
GOOD
time: 1.305000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(sin(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\sin\left( x\right)}}} = {¿}$
GOOD
time: 2.296000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(cos(x), x, a), cos(a))
${{\underset{ x\rightarrow a}{\lim}}{{\cos\left( x\right)}}} = {\cos\left( a\right)}$
GOOD
time: 0.843000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(cos(x), x, inf), invalid)
${{\underset{ x\rightarrow \infty}{\lim}}{{\cos\left( x\right)}}} = {¿}$
GOOD
time: 0.846000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(cos(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\cos\left( x\right)}}} = {¿}$
GOOD
time: 0.950000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(abs(x), x, a), abs(a))
${{\underset{ x\rightarrow a}{\lim}}{{\left| x\right|}}} = {\left| a\right|}$
GOOD
time: 1.619000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(abs(x), x, -inf), inf)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\left| x\right|}}} = {\infty}$
GOOD
time: 0.944000ms
stack: size: 13
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Limit:Prune:apply
  • *:Prune:handleInfAndNan
  • abs:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(abs(x), x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{\left| x\right|}}} = {\infty}$
GOOD
time: 0.906000ms
stack: size: 10
  • Init
  • Limit:Prune:apply
  • abs:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(exp(x), x, a), exp(a))
${{\underset{ x\rightarrow a}{\lim}}{{\exp\left( x\right)}}} = {\exp\left( a\right)}$
GOOD
time: 1.245000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(exp(x), x, -inf), 0)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\exp\left( x\right)}}} = {0}$
GOOD
time: 1.074000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(exp(x), x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{\exp\left( x\right)}}} = {\infty}$
GOOD
time: 0.863000ms
stack: size: 11
  • Init
  • Limit:Prune:apply
  • Limit:Prune:apply
  • ^:Prune:handleInfAndNan
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(atan(x), x, a), atan(a))
${{\underset{ x\rightarrow a}{\lim}}{{atan\left( x\right)}}} = {atan\left( a\right)}$
GOOD
time: 1.881000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(atan(x), x, -inf), -pi/2)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{atan\left( x\right)}}} = {{\frac{1}{2}}{\left({-{π}}\right)}}$
GOOD
time: 10.867000ms
stack: size: 19
  • Init
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • Prune
  • /:Factor:polydiv
  • Factor
  • *:Prune:flatten
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • ^:Prune:xToTheZero
  • /:Prune:divToPowSub
  • *:Prune:factorDenominators
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • /:Tidy:apply
  • Tidy

simplifyAssertEq(lim(atan(x), x, inf), pi/2)
${{\underset{ x\rightarrow \infty}{\lim}}{{atan\left( x\right)}}} = {{\frac{1}{2}} {π}}$
GOOD
time: 7.116000ms
stack: size: 14
  • Init
  • Prune
  • Expand
  • Prune
  • /:Factor:polydiv
  • Factor
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • ^:Prune:xToTheZero
  • *:Prune:apply
  • /:Prune:divToPowSub
  • *:Prune:factorDenominators
  • Prune
  • Tidy


simplifyAssertEq(lim(tanh(x), x, a), tanh(a))
${{\underset{ x\rightarrow a}{\lim}}{{\tanh\left( x\right)}}} = {\tanh\left( a\right)}$
GOOD
time: 1.061000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tanh(x), x, -inf), -1)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\tanh\left( x\right)}}} = {-1}$
GOOD
time: 1.833000ms
stack: size: 8
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Constant:Tidy:apply
  • Tidy

simplifyAssertEq(lim(tanh(x), x, inf), 1)
${{\underset{ x\rightarrow \infty}{\lim}}{{\tanh\left( x\right)}}} = {1}$
GOOD
time: 1.070000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(asinh(x), x, a), asinh(a))
${{\underset{ x\rightarrow a}{\lim}}{{asinh\left( x\right)}}} = {asinh\left( a\right)}$
GOOD
time: 1.393000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(asinh(x), x, -inf), -inf)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{asinh\left( x\right)}}} = {-{\infty}}$
GOOD
time: 4.458000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(asinh(x), x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{asinh\left( x\right)}}} = {\infty}$
GOOD
time: 1.457000ms
stack: size: 10
  • Init
  • Limit:Prune:apply
  • asinh:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(cosh(x), x, a), cosh(a))
${{\underset{ x\rightarrow a}{\lim}}{{\cosh\left( x\right)}}} = {\cosh\left( a\right)}$
GOOD
time: 3.084000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(cosh(x), x, -inf), inf)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\cosh\left( x\right)}}} = {\infty}$
GOOD
time: 1.156000ms
stack: size: 12
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Limit:Prune:apply
  • cosh:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(cosh(x), x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{\cosh\left( x\right)}}} = {\infty}$
GOOD
time: 0.928000ms
stack: size: 10
  • Init
  • Limit:Prune:apply
  • cosh:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(sinh(x), x, a), sinh(a))
${{\underset{ x\rightarrow a}{\lim}}{{\sinh\left( x\right)}}} = {\sinh\left( a\right)}$
GOOD
time: 0.694000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(sinh(x), x, -inf), -inf)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\sinh\left( x\right)}}} = {-{\infty}}$
GOOD
time: 1.981000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(sinh(x), x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{\sinh\left( x\right)}}} = {\infty}$
GOOD
time: 0.473000ms
stack: size: 10
  • Init
  • Limit:Prune:apply
  • sinh:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(sin(x), x, a), sin(a))
${{\underset{ x\rightarrow a}{\lim}}{{\sin\left( x\right)}}} = {\sin\left( a\right)}$
GOOD
time: 1.622000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(sin(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\sin\left( x\right)}}} = {¿}$
GOOD
time: 1.315000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(sin(x), x, inf), invalid)
${{\underset{ x\rightarrow \infty}{\lim}}{{\sin\left( x\right)}}} = {¿}$
GOOD
time: 0.514000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(cos(x), x, a), cos(a))
${{\underset{ x\rightarrow a}{\lim}}{{\cos\left( x\right)}}} = {\cos\left( a\right)}$
GOOD
time: 0.820000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(cos(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\cos\left( x\right)}}} = {¿}$
GOOD
time: 1.349000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(cos(x), x, inf), invalid)
${{\underset{ x\rightarrow \infty}{\lim}}{{\cos\left( x\right)}}} = {¿}$
GOOD
time: 0.412000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(tan(x), x, a), tan(a))
${{\underset{ x\rightarrow a}{\lim}}{{\tan\left( x\right)}}} = {\tan\left( a\right)}$
GOOD
time: 15.560000ms
stack: size: 15
  • Init
  • tan:Prune:apply
  • Prune
  • Expand
  • Prune
  • /:Factor:polydiv
  • Factor
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • ^:Prune:xToTheZero
  • *:Prune:apply
  • /:Prune:divToPowSub
  • *:Prune:factorDenominators
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\tan\left( x\right)}}} = {¿}$
GOOD
time: 2.819000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, -3*pi/2), invalid)
${{\underset{ x\rightarrow{{\frac{1}{2}} {{{-3}} {{π}}}}}{\lim}}{{\tan\left( x\right)}}} = {¿}$
GOOD
time: 8.126000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, -pi), tan(-pi))
${{\underset{ x\rightarrow -{π}}{\lim}}{{\tan\left( x\right)}}} = {\tan\left( -{π}\right)}$
GOOD
time: 3.300000ms
stack: size: 13
  • Init
  • unm:Prune:doubleNegative
  • sin:Prune:apply
  • cos:Prune:apply
  • *:Prune:apply
  • /:Prune:xOverMinusOne
  • tan:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, -pi/2), invalid)
${{\underset{ x\rightarrow{{\frac{1}{2}}{\left({-{π}}\right)}}}{\lim}}{{\tan\left( x\right)}}} = {¿}$
GOOD
time: 4.584000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, 0), tan(0))
${{\underset{ x\rightarrow 0}{\lim}}{{\tan\left( x\right)}}} = {\tan\left( 0\right)}$
GOOD
time: 2.524000ms
stack: size: 11
  • Init
  • sin:Prune:apply
  • cos:Prune:apply
  • /:Prune:xOverOne
  • tan:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, pi/2), invalid)
${{\underset{ x\rightarrow{{\frac{1}{2}} {π}}}{\lim}}{{\tan\left( x\right)}}} = {¿}$
GOOD
time: 2.306000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, pi/2, '+'), -inf)
${{\underset{ x\rightarrow{{{\frac{1}{2}} {π}}{}^+}}{\lim}}{{\tan\left( x\right)}}} = {-{\infty}}$
GOOD
time: 2.366000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(tan(x), x, pi/2, '-'), inf)
${{\underset{ x\rightarrow{{{\frac{1}{2}} {π}}{}^-}}{\lim}}{{\tan\left( x\right)}}} = {\infty}$
GOOD
time: 0.962000ms
stack: size: 16
  • Init
  • tan:Prune:apply
  • Limit:Prune:apply
  • sin:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • cos:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, pi), tan(pi))
${{\underset{ x\rightarrow π}{\lim}}{{\tan\left( x\right)}}} = {\tan\left( π\right)}$
GOOD
time: 2.312000ms
stack: size: 12
  • Init
  • sin:Prune:apply
  • cos:Prune:apply
  • *:Prune:apply
  • /:Prune:xOverMinusOne
  • tan:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, 3*pi/2), invalid)
${{\underset{ x\rightarrow{{\frac{1}{2}} {{{3}} {{π}}}}}{\lim}}{{\tan\left( x\right)}}} = {¿}$
GOOD
time: 3.017000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(tan(x), x, inf), invalid)
${{\underset{ x\rightarrow \infty}{\lim}}{{\tan\left( x\right)}}} = {¿}$
GOOD
time: 1.481000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

if the input is within the domain of the function then we can evaluate it for certain
do local a = set.positiveReal:var'a' simplifyAssertEq(lim(log(x), x, a), log(a)) end
${{\underset{ x\rightarrow a}{\lim}}{{\log\left( x\right)}}} = {\log\left( a\right)}$
GOOD
time: 1.798000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy
if the input is outside the domain of the function then we know the result is invalid. TODO is this the same as indeterminate? Or should I introduce a new singleton?
do local a = set.negativeReal:var'a' simplifyAssertEq(lim(log(x), x, a), invalid) end
${{\underset{ x\rightarrow a}{\lim}}{{\log\left( x\right)}}} = {¿}$
GOOD
time: 3.447000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy
if the input covers both the domain and its complement, and we can't determine the limit evaluation, then don't touch the expression
do local a = set.real:var'a' print(lim(log(x), x, a):prune()) assert(lim(log(x), x, a):prune() == lim(log(x), x, a)) end
${\underset{ x\rightarrow a}{\lim}}{{\log\left( x\right)}}$ GOOD time: 1.091000ms
stack: size: 4
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply

simplifyAssertEq(lim(log(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\log\left( x\right)}}} = {¿}$
GOOD
time: 0.743000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(log(x), x, 0), invalid)
${{\underset{ x\rightarrow 0}{\lim}}{{\log\left( x\right)}}} = {¿}$
GOOD
time: 0.858000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(log(x), x, 0, '+'), -inf)
${{\underset{ x\rightarrow{ 0{}^+}}{\lim}}{{\log\left( x\right)}}} = {-{\infty}}$
GOOD
time: 2.069000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(log(x), x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{\log\left( x\right)}}} = {\infty}$
GOOD
time: 0.363000ms
stack: size: 10
  • Init
  • Limit:Prune:apply
  • log:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


do local a = set.RealSubset(-1, 1, false, false):var'a' simplifyAssertEq(lim(acosh(x), x, a), acosh(a)) end
${{\underset{ x\rightarrow a}{\lim}}{{acosh\left( x\right)}}} = {acosh\left( a\right)}$
GOOD
time: 1.689000ms
stack: size: 8
  • Init
  • acosh:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

do local a = set.RealSubset(-math.huge, -1, false, false):var'a' simplifyAssertEq(lim(acosh(x), x, a), invalid) end
${{\underset{ x\rightarrow a}{\lim}}{{acosh\left( x\right)}}} = {¿}$
GOOD
time: 0.951000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

do local a = set.real:var'a' print(lim(acosh(x), x, a):prune()) assert(lim(acosh(x), x, a):prune() == lim(acosh(x), x, a)) end
${\underset{ x\rightarrow a}{\lim}}{{acosh\left( x\right)}}$ GOOD time: 2.266000ms
stack: size: 4
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply

simplifyAssertEq(lim(acosh(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{acosh\left( x\right)}}} = {¿}$
GOOD
time: 0.882000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(acosh(x), x, 1), invalid)
${{\underset{ x\rightarrow 1}{\lim}}{{acosh\left( x\right)}}} = {¿}$
GOOD
time: 0.899000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(acosh(x), x, 1, '+'), 0)
${{\underset{ x\rightarrow{ 1{}^+}}{\lim}}{{acosh\left( x\right)}}} = {0}$
GOOD
time: 1.074000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(acosh(x), x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{acosh\left( x\right)}}} = {\infty}$
GOOD
time: 0.757000ms
stack: size: 10
  • Init
  • Limit:Prune:apply
  • acosh:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


do local a = set.RealSubset(-1, 1, false, false):var'a' simplifyAssertEq(lim(atanh(x), x, a), atanh(a)) end
${{\underset{ x\rightarrow a}{\lim}}{{atanh\left( x\right)}}} = {atanh\left( a\right)}$
GOOD
time: 2.439000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

do local a = set.RealSubset(-math.huge, -1, false, false):var'a' simplifyAssertEq(lim(atanh(x), x, a), invalid) end
${{\underset{ x\rightarrow a}{\lim}}{{atanh\left( x\right)}}} = {¿}$
GOOD
time: 0.898000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

do local a = set.real:var'a' print(lim(atanh(x), x, a):prune()) assert(lim(atanh(x), x, a):prune() == lim(atanh(x), x, a)) end
${\underset{ x\rightarrow a}{\lim}}{{atanh\left( x\right)}}$ GOOD time: 2.266000ms
stack: size: 4
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply

simplifyAssertEq(lim(atanh(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{atanh\left( x\right)}}} = {¿}$
GOOD
time: 1.723000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(atanh(x), x, -1), invalid)
${{\underset{ x\rightarrow{-1}}{\lim}}{{atanh\left( x\right)}}} = {¿}$
GOOD
time: 1.069000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(atanh(x), x, -1, '+'), -inf)
${{\underset{ x\rightarrow{{-1}{}^+}}{\lim}}{{atanh\left( x\right)}}} = {-{\infty}}$
GOOD
time: 1.284000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(atanh(x), x, 0), 0)
${{\underset{ x\rightarrow 0}{\lim}}{{atanh\left( x\right)}}} = {0}$
GOOD
time: 1.399000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(atanh(x), x, 1), invalid)
${{\underset{ x\rightarrow 1}{\lim}}{{atanh\left( x\right)}}} = {¿}$
GOOD
time: 3.045000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(atanh(x), x, 1, '-'), inf)
${{\underset{ x\rightarrow{ 1{}^-}}{\lim}}{{atanh\left( x\right)}}} = {\infty}$
GOOD
time: 1.276000ms
stack: size: 9
  • Init
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(atanh(x), x, inf), invalid)
${{\underset{ x\rightarrow \infty}{\lim}}{{atanh\left( x\right)}}} = {¿}$
GOOD
time: 0.699000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


do local a = set.RealSubset(-1, 1, false, false):var'a' simplifyAssertEq(lim(asin(x), x, a), asin(a)) end
${{\underset{ x\rightarrow a}{\lim}}{{asin\left( x\right)}}} = {asin\left( a\right)}$
GOOD
time: 2.730000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

do local a = set.RealSubset(-math.huge, -1, false, false):var'a' simplifyAssertEq(lim(asin(x), x, a), invalid) end
${{\underset{ x\rightarrow a}{\lim}}{{asin\left( x\right)}}} = {¿}$
GOOD
time: 0.728000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

do local a = set.real:var'a' print(lim(asin(x), x, a):prune()) assert(lim(asin(x), x, a):prune() == lim(asin(x), x, a)) end
${\underset{ x\rightarrow a}{\lim}}{{asin\left( x\right)}}$ GOOD time: 2.823000ms
stack: size: 4
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply

simplifyAssertEq(lim(asin(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{asin\left( x\right)}}} = {¿}$
GOOD
time: 0.758000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(asin(x), x, -1), invalid)
${{\underset{ x\rightarrow{-1}}{\lim}}{{asin\left( x\right)}}} = {¿}$
GOOD
time: 1.144000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(asin(x), x, -1, '+'), -inf)
${{\underset{ x\rightarrow{{-1}{}^+}}{\lim}}{{asin\left( x\right)}}} = {-{\infty}}$
GOOD
time: 1.616000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(asin(x), x, 0), 0)
${{\underset{ x\rightarrow 0}{\lim}}{{asin\left( x\right)}}} = {0}$
GOOD
time: 0.755000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(asin(x), x, 1), invalid)
${{\underset{ x\rightarrow 1}{\lim}}{{asin\left( x\right)}}} = {¿}$
GOOD
time: 0.786000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(asin(x), x, 1, '-'), inf)
${{\underset{ x\rightarrow{ 1{}^-}}{\lim}}{{asin\left( x\right)}}} = {\infty}$
GOOD
time: 0.583000ms
stack: size: 9
  • Init
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(asin(x), x, inf), invalid)
${{\underset{ x\rightarrow \infty}{\lim}}{{asin\left( x\right)}}} = {¿}$
GOOD
time: 0.659000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


do local a = set.RealSubset(-1, 1, false, false):var'a' simplifyAssertEq(lim(acos(x), x, a), acos(a)) end
${{\underset{ x\rightarrow a}{\lim}}{{acos\left( x\right)}}} = {acos\left( a\right)}$
GOOD
time: 1.484000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

do local a = set.RealSubset(-math.huge, -1, false, false):var'a' simplifyAssertEq(lim(acos(x), x, a), invalid) end
${{\underset{ x\rightarrow a}{\lim}}{{acos\left( x\right)}}} = {¿}$
GOOD
time: 1.358000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

do local a = set.real:var'a' print(lim(acos(x), x, a):prune()) assert(lim(acos(x), x, a):prune() == lim(acos(x), x, a)) end
${\underset{ x\rightarrow a}{\lim}}{{acos\left( x\right)}}$ GOOD time: 1.070000ms
stack: size: 4
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply

simplifyAssertEq(lim(acos(x), x, -inf), invalid)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{acos\left( x\right)}}} = {¿}$
GOOD
time: 1.079000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(acos(x), x, -1), invalid)
${{\underset{ x\rightarrow{-1}}{\lim}}{{acos\left( x\right)}}} = {¿}$
GOOD
time: 0.852000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(acos(x), x, -1, '+'), inf)
${{\underset{ x\rightarrow{{-1}{}^+}}{\lim}}{{acos\left( x\right)}}} = {\infty}$
GOOD
time: 0.430000ms
stack: size: 9
  • Init
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(acos(x), x, 0), pi/2)
${{\underset{ x\rightarrow 0}{\lim}}{{acos\left( x\right)}}} = {{\frac{1}{2}} {π}}$
GOOD
time: 6.231000ms
stack: size: 14
  • Init
  • Prune
  • Expand
  • Prune
  • /:Factor:polydiv
  • Factor
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • ^:Prune:xToTheZero
  • *:Prune:apply
  • /:Prune:divToPowSub
  • *:Prune:factorDenominators
  • Prune
  • Tidy

simplifyAssertEq(lim(acos(x), x, 1), invalid)
${{\underset{ x\rightarrow 1}{\lim}}{{acos\left( x\right)}}} = {¿}$
GOOD
time: 1.101000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(acos(x), x, 1, '-'), -inf)
${{\underset{ x\rightarrow{ 1{}^-}}{\lim}}{{acos\left( x\right)}}} = {-{\infty}}$
GOOD
time: 3.774000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim(acos(x), x, inf), invalid)
${{\underset{ x\rightarrow \infty}{\lim}}{{acos\left( x\right)}}} = {¿}$
GOOD
time: 0.605000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy


simplifyAssertEq(lim(Heaviside(x), x, a), Heaviside(a))
${{\underset{ x\rightarrow a}{\lim}}{{\mathcal{H}\left( x\right)}}} = {\mathcal{H}\left( a\right)}$
GOOD
time: 2.044000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(Heaviside(x), x, -inf), 0)
${{\underset{ x\rightarrow -{\infty}}{\lim}}{{\mathcal{H}\left( x\right)}}} = {0}$
GOOD
time: 0.776000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(Heaviside(x), x, -1), 0)
${{\underset{ x\rightarrow{-1}}{\lim}}{{\mathcal{H}\left( x\right)}}} = {0}$
GOOD
time: 0.815000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(Heaviside(x), x, 0), invalid)
${{\underset{ x\rightarrow 0}{\lim}}{{\mathcal{H}\left( x\right)}}} = {¿}$
GOOD
time: 0.591000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(Heaviside(x), x, 0, '-'), 0)
${{\underset{ x\rightarrow{ 0{}^-}}{\lim}}{{\mathcal{H}\left( x\right)}}} = {0}$
GOOD
time: 0.594000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(Heaviside(x), x, 0, '+'), 1)
${{\underset{ x\rightarrow{ 0{}^+}}{\lim}}{{\mathcal{H}\left( x\right)}}} = {1}$
GOOD
time: 0.532000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(Heaviside(x), x, 1), 1)
${{\underset{ x\rightarrow 1}{\lim}}{{\mathcal{H}\left( x\right)}}} = {1}$
GOOD
time: 1.027000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(Heaviside(x), x, inf), 1)
${{\underset{ x\rightarrow \infty}{\lim}}{{\mathcal{H}\left( x\right)}}} = {1}$
GOOD
time: 0.749000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

products of functions

simplifyAssertEq(lim(x * sin(x), x, a), a * sin(a))
${{\underset{ x\rightarrow a}{\lim}}{{\left({{{x}} {{\sin\left( x\right)}}}\right)}}} = {{{a}} {{\sin\left( a\right)}}}$
GOOD
time: 4.267000ms
stack: size: 8
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • *:Tidy:apply
  • Tidy

TODO polynomial roots

simplifyAssertEq(lim(1 / (x - 1), x, 1), invalid)
${{\underset{ x\rightarrow 1}{\lim}}{{\frac{1}{{x}{-{1}}}}}} = {¿}$
GOOD
time: 8.987000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(1 / (x - 1), x, 1, '+'), inf)
${{\underset{ x\rightarrow{ 1{}^+}}{\lim}}{{\frac{1}{{x}{-{1}}}}}} = {\infty}$
GOOD
time: 6.104000ms
stack: size: 14
  • Init
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • +:Prune:combineConstants
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(1 / (x - 1), x, 1, '-'), -inf)
${{\underset{ x\rightarrow{ 1{}^-}}{\lim}}{{\frac{1}{{x}{-{1}}}}}} = {-{\infty}}$
GOOD
time: 6.155000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

simplifyAssertEq(lim((x + 1) / (x^2 - 1), x, 1), invalid)
${{\underset{ x\rightarrow 1}{\lim}}{{\frac{{x} + {1}}{{{x}^{2}}{-{1}}}}}} = {¿}$
GOOD
time: 27.147000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim((x + 1) / (x^2 - 1), x, 1, '+'), inf)
${{\underset{ x\rightarrow{ 1{}^+}}{\lim}}{{\frac{{x} + {1}}{{{x}^{2}}{-{1}}}}}} = {\infty}$
GOOD
time: 23.205000ms
stack: size: 40
  • Init
  • +:Prune:combineConstants
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • Limit:Prune:apply
  • Limit:Prune:apply
  • +:Prune:combineConstants
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • ^:Prune:simplifyConstantPowers
  • Limit:Prune:apply
  • +:Prune:combineConstants
  • Limit:Prune:apply
  • Prune
  • ^:Expand:integerPower
  • Expand
  • +:Prune:combineConstants
  • *:Prune:combinePows
  • Limit:Prune:apply
  • Limit:Prune:apply
  • +:Prune:combineConstants
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • ^:Prune:simplifyConstantPowers
  • Limit:Prune:apply
  • +:Prune:combineConstants
  • Limit:Prune:apply
  • Prune
  • +:Factor:apply
  • Factor
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim((x + 1) / (x^2 - 1), x, 1, '-'), -inf)
${{\underset{ x\rightarrow{ 1{}^-}}{\lim}}{{\frac{{x} + {1}}{{{x}^{2}}{-{1}}}}}} = {-{\infty}}$
GOOD
time: 22.268000ms
stack: size: 14
  • Init
  • *:Prune:handleInfAndNan
  • unm:Prune:doubleNegative
  • Prune
  • Expand
  • *:Prune:handleInfAndNan
  • Prune
  • Factor
  • *:Prune:handleInfAndNan
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

can we evaluate derivatives as limits? yes.

difftest(x)
${f\left( x\right)} = {x}$
limit: ${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{f\left( {{x} + {h}}\right)}{-{f\left( x\right)}}}\right)}}}} = {1}$
derivative: ${{\frac{\partial}{\partial x}}\left({f\left( x\right)}\right)} = {1}$
${1} = {1}$
GOOD
time: 1.939000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

difftest(c * x)
${f\left( x\right)} = {{{c}} {{x}}}$
limit: ${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{f\left( {{x} + {h}}\right)}{-{f\left( x\right)}}}\right)}}}} = {c}$
derivative: ${{\frac{\partial}{\partial x}}\left({f\left( x\right)}\right)} = {c}$
${c} = {c}$
GOOD
time: 9.221000ms
stack: size: 10
  • Init
  • Derivative:Prune:self
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy
  • Limit:Prune:apply
  • Limit:Prune:apply

difftest(x^2)
${f\left( x\right)} = {{x}^{2}}$
limit: ${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{f\left( {{x} + {h}}\right)}{-{f\left( x\right)}}}\right)}}}} = {{{2}} {{x}}}$
derivative: ${{\frac{\partial}{\partial x}}\left({f\left( x\right)}\right)} = {{{2}} {{x}}}$
${{{2}} {{x}}} = {{{2}} {{x}}}$
GOOD
time: 12.395000ms
stack: size: 8
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • *:Tidy:apply
  • Tidy

difftest(x^3)
${f\left( x\right)} = {{x}^{3}}$
limit: ${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{f\left( {{x} + {h}}\right)}{-{f\left( x\right)}}}\right)}}}} = {{{3}} {{{x}^{2}}}}$
derivative: ${{\frac{\partial}{\partial x}}\left({f\left( x\right)}\right)} = {{{3}} {{{x}^{2}}}}$
${{{3}} {{{x}^{2}}}} = {{{3}} {{{x}^{2}}}}$
GOOD
time: 25.310000ms
stack: size: 11
  • Init
  • Prune
  • ^:Expand:integerPower
  • Expand
  • +:Prune:combineConstants
  • *:Prune:combinePows
  • Prune
  • Factor
  • Prune
  • *:Tidy:apply
  • Tidy

difftest(1/x)
${f\left( x\right)} = {\frac{1}{x}}$
limit: ${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{f\left( {{x} + {h}}\right)}{-{f\left( x\right)}}}\right)}}}} = {\frac{-1}{{x}^{2}}}$
derivative: ${{\frac{\partial}{\partial x}}\left({f\left( x\right)}\right)} = {\frac{-1}{{x}^{2}}}$
${\frac{-1}{{x}^{2}}} = {\frac{-1}{{x}^{2}}}$
GOOD
time: 27.683000ms
stack: size: 19
  • Init
  • Prune
  • ^:Expand:integerPower
  • Expand
  • +:Prune:combineConstants
  • *:Prune:combinePows
  • Prune
  • ^:ExpandPolynomial:apply
  • +:Prune:combineConstants
  • *:Prune:combinePows
  • /:Factor:polydiv
  • Factor
  • /:Prune:xOverMinusOne
  • *:Prune:apply
  • *:Prune:flatten
  • Prune
  • Constant:Tidy:apply
  • /:Tidy:apply
  • Tidy

can't handle these yet.
TODO give unit tests a 'reach' section?
so console can show that these tests aren't 100% certified.
use infinite taylor expansion?
or just use L'Hospital's rule -- that solves these too, because, basically, that replaces the limit with the derivative, so it will always be equal.

difftest(sqrt(x))
${f\left( x\right)} = {\sqrt{x}}$
limit: ${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{f\left( {{x} + {h}}\right)}{-{f\left( x\right)}}}\right)}}}} = {{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{\sqrt{{x} + {h}}} + {{{-1}} {{\sqrt{x}}}}}\right)}}}}$
derivative: ${{\frac{\partial}{\partial x}}\left({f\left( x\right)}\right)} = {\frac{1}{{{2}} {{{x}^{\frac{1}{2}}}}}}$
${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{\sqrt{{x} + {h}}} + {{{-1}} {{\sqrt{x}}}}}\right)}}}} = {\frac{1}{{{2}} {{{x}^{\frac{1}{2}}}}}}$
GOOD
time: 319.008000ms
stack: size: 90
  • Init
  • Prune
  • Expand
  • unm:Prune:doubleNegative
  • *:Prune:apply
  • +:Prune:combineConstants
  • +:Prune:factorOutDivs
  • +:Prune:combineConstants
  • *:Prune:apply
  • *:Prune:factorDenominators
  • unm:Prune:doubleNegative
  • *:Prune:apply
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • ^:Prune:xToTheZero
  • *:Prune:apply
  • /:Prune:divToPowSub
  • *:Prune:factorDenominators
  • +:Prune:combineConstants
  • /:Prune:zeroOverX
  • +:Prune:factorOutDivs
  • ^:Prune:xToTheZero
  • *:Prune:combinePows
  • *:Prune:apply
  • *:Prune:factorDenominators
  • unm:Prune:doubleNegative
  • /:Prune:prodOfSqrtOverProdOfSqrt
  • /:Prune:divToPowSub
  • /:Prune:mulBySqrtConj
  • Prune
  • /:Factor:polydiv
  • Factor
  • unm:Prune:doubleNegative
  • *:Prune:apply
  • +:Prune:combineConstants
  • +:Prune:factorOutDivs
  • +:Prune:combineConstants
  • *:Prune:apply
  • *:Prune:factorDenominators
  • unm:Prune:doubleNegative
  • *:Prune:apply
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • ^:Prune:xToTheZero
  • *:Prune:apply
  • /:Prune:divToPowSub
  • *:Prune:factorDenominators
  • +:Prune:combineConstants
  • /:Prune:zeroOverX
  • +:Prune:factorOutDivs
  • ^:Prune:xToTheZero
  • *:Prune:combinePows
  • *:Prune:apply
  • *:Prune:factorDenominators
  • unm:Prune:doubleNegative
  • /:Prune:prodOfSqrtOverProdOfSqrt
  • /:Prune:divToPowSub
  • /:Prune:mulBySqrtConj
  • /:Prune:xOverX
  • *:Prune:factorDenominators
  • unm:Prune:doubleNegative
  • *:Prune:apply
  • +:Prune:combineConstants
  • +:Prune:factorOutDivs
  • +:Prune:combineConstants
  • *:Prune:apply
  • *:Prune:factorDenominators
  • unm:Prune:doubleNegative
  • *:Prune:apply
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • ^:Prune:xToTheZero
  • *:Prune:apply
  • /:Prune:divToPowSub
  • *:Prune:factorDenominators
  • +:Prune:combineConstants
  • /:Prune:zeroOverX
  • +:Prune:factorOutDivs
  • ^:Prune:xToTheZero
  • *:Prune:combinePows
  • *:Prune:apply
  • *:Prune:factorDenominators
  • unm:Prune:doubleNegative
  • /:Prune:prodOfSqrtOverProdOfSqrt
  • /:Prune:divToPowSub
  • /:Prune:mulBySqrtConj
  • Prune
  • ^:Tidy:replacePowerOfFractionWithRoots
  • *:Tidy:apply
  • Tidy

difftest(sin(x))
${f\left( x\right)} = {\sin\left( x\right)}$
limit: ${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{f\left( {{x} + {h}}\right)}{-{f\left( x\right)}}}\right)}}}} = {\cos\left( x\right)}$
derivative: ${{\frac{\partial}{\partial x}}\left({f\left( x\right)}\right)} = {\cos\left( x\right)}$
${\cos\left( x\right)} = {\cos\left( x\right)}$
GOOD
time: 6.198000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

difftest(cos(x))
${f\left( x\right)} = {\cos\left( x\right)}$
limit: ${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{f\left( {{x} + {h}}\right)}{-{f\left( x\right)}}}\right)}}}} = {{{-1}} {{\sin\left( x\right)}}}$
derivative: ${{\frac{\partial}{\partial x}}\left({f\left( x\right)}\right)} = {{{-1}} {{\sin\left( x\right)}}}$
${{{-1}} {{\sin\left( x\right)}}} = {{{-1}} {{\sin\left( x\right)}}}$
GOOD
time: 10.699000ms
stack: size: 10
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Constant:Tidy:apply
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy

difftest(exp(x))
${f\left( x\right)} = {\exp\left( x\right)}$
limit: ${{\underset{ h\rightarrow{ 0{}^+}}{\lim}}{{{\frac{1}{h}}{\left({{f\left( {{x} + {h}}\right)}{-{f\left( x\right)}}}\right)}}}} = {\exp\left( x\right)}$
derivative: ${{\frac{\partial}{\partial x}}\left({f\left( x\right)}\right)} = {\exp\left( x\right)}$
${\exp\left( x\right)} = {\exp\left( x\right)}$
GOOD
time: 7.367000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

some other L'Hospital rule problems:

simplifyAssertEq(lim(sin(x) / x, x, 0), 1)
${{\underset{ x\rightarrow 0}{\lim}}{{{\frac{1}{x}} {\sin\left( x\right)}}}} = {1}$
GOOD
time: 1.885000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim(exp(x) / x^2, x, inf), inf)
${{\underset{ x\rightarrow \infty}{\lim}}{{\frac{\exp\left( x\right)}{{x}^{2}}}}} = {\infty}$
GOOD
time: 9.087000ms
stack: size: 15
  • Init
  • Limit:Prune:apply
  • Limit:Prune:apply
  • ^:Prune:handleInfAndNan
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply
  • ^:Prune:handleInfAndNan
  • Limit:Prune:apply
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim((e^x - 1) / (x^2 + x), x, 0), 1)
${{\underset{ x\rightarrow 0}{\lim}}{{\frac{{\exp\left( x\right)}{-{1}}}{{{x}^{2}} + {x}}}}} = {1}$
GOOD
time: 17.624000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

simplifyAssertEq(lim((2*sin(x) - sin(2*x)) / (x - sin(x)), x, 0), 6)
${{\underset{ x\rightarrow 0}{\lim}}{{\frac{{{{2}} {{\sin\left( x\right)}}}{-{\sin\left( {{{2}} {{x}}}\right)}}}{{x}{-{\sin\left( x\right)}}}}}} = {6}$
GOOD
time: 72.046000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

TODO this one, repeatedly apply L'Hospital until the power of x on top is <= 0
but this seems like it would need a special case of evaluating into a factorial

simplifyAssertEq(lim(x^n * e^x, x, 0), 0)
${{\underset{ x\rightarrow 0}{\lim}}{{\left({{{{x}^{n}}} {{\exp\left( x\right)}}}\right)}}} = {0}$
expected ${\underset{ x\rightarrow 0}{\lim}}{{\left({{{{x}^{n}}} {{\exp\left( x\right)}}}\right)}}$ to equal 0
found ${0}^{n}$ vs $0$
lhs stack
Init ${\underset{ x\rightarrow 0}{\lim}}{{\left({{{{x}^{n}}} {{\exp\left( x\right)}}}\right)}}$
	Limit{*[^[x, n], ^[_e|2.718281828459, x]], x, 0, {}}	

Limit:Prune:apply $e$
	_e|2.718281828459	

Limit:Prune:apply $0$
	0	

^:Prune:xToTheZero $1$
	1	

Limit:Prune:apply $1$
	1	

Limit:Prune:apply $0$
	0	

Limit:Prune:apply $n$
	n	

Limit:Prune:apply ${0}^{n}$
	^[0, n]	

*:Prune:apply ${0}^{n}$
	^[0, n]	

Limit:Prune:apply ${0}^{n}$
	^[0, n]	

Limit:Prune:apply $e$
	_e|2.718281828459	

Limit:Prune:apply $0$
	0	

^:Prune:xToTheZero $1$
	1	

Limit:Prune:apply $1$
	1	

Limit:Prune:apply $0$
	0	

Limit:Prune:apply $n$
	n	

Limit:Prune:apply ${0}^{n}$
	^[0, n]	

*:Prune:apply ${0}^{n}$
	^[0, n]	

Limit:Prune:apply ${0}^{n}$
	^[0, n]	

Limit:Prune:apply ${0}^{n}$
	^[0, n]	

Prune ${0}^{n}$
	^[0, n]	

Expand ${0}^{n}$
	^[0, n]	

Prune ${0}^{n}$
	^[0, n]	

Factor ${0}^{n}$
	^[0, n]	

Prune ${0}^{n}$
	^[0, n]	

Tidy ${0}^{n}$
	^[0, n]	

rhs stack
Init $0$
	0	

Prune $0$
	0	

Expand $0$
	0	

Prune $0$
	0	

Factor $0$
	0	

Prune $0$
	0	

Tidy $0$
	0	

BAD
/home/chris/Projects/lua/symmath/tests/unit/unit.lua:125: failed
stack traceback:
/home/chris/Projects/lua/symmath/tests/unit/unit.lua:246: in function
[C]: in function 'error'
/home/chris/Projects/lua/symmath/tests/unit/unit.lua:125: in function 'simplifyAssertEq'
[string "simplifyAssertEq(lim(x^n * e^x, x, 0), 0)"]:1: in main chunk
/home/chris/Projects/lua/symmath/tests/unit/unit.lua:238: in function
[C]: in function 'xpcall'
/home/chris/Projects/lua/symmath/tests/unit/unit.lua:237: in function 'exec'
limit.lua:249: in function 'cb'
/home/chris/Projects/lua/ext/timer.lua:54: in function 'timer'
limit.lua:6: in main chunk
[C]: at 0x55ac611723e0
time: 5.398000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

TODO this requires representing x ln x as (ln x) / (1/x) before applying L'Hospital

simplifyAssertEq(lim(x * log(x), x, 0, '+'), 0)
${{\underset{ x\rightarrow{ 0{}^+}}{\lim}}{{\left({{{x}} {{\log\left( x\right)}}}\right)}}} = {0}$
GOOD
time: 0.636000ms
stack: size: 7
  • Init
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • Tidy

mortgage repayment formula -- works

simplifyAssertEq(lim( (a * x * (1 + x)^n) / ((1 + x)^n - 1), x, 0 ), a / n)
${{\underset{ x\rightarrow 0}{\lim}}{{\frac{{{a}} {{x}} {{{\left({{1} + {x}}\right)}^{n}}}}{{{\left({{1} + {x}}\right)}^{n}}{-{1}}}}}} = {{\frac{1}{n}} {a}}$
GOOD
time: 62.104000ms
stack: size: 14
  • Init
  • Prune
  • Expand
  • Prune
  • /:Factor:polydiv
  • Factor
  • unm:Prune:doubleNegative
  • +:Prune:combineConstants
  • ^:Prune:xToTheZero
  • *:Prune:apply
  • /:Prune:divToPowSub
  • *:Prune:factorDenominators
  • Prune
  • Tidy

the infamous tanh(x) ... works? hmm ... this is infamous for taking an infinite number of L'Hospital applications. Why is it working?

print( ((e^x + e^-x) / (e^x - e^-x)):lim(x, inf):prune() )
$1$ GOOD time: 32.127000ms
stack: size: 29
  • Init
  • Derivative:Prune:constants
  • Derivative:Prune:constants
  • *:Prune:apply
  • Derivative:Prune:self
  • *:Prune:apply
  • +:Prune:combineConstants
  • Derivative:Prune:eval
  • log:Prune:apply
  • *:Prune:apply
  • Derivative:Prune:other
  • *:Prune:apply
  • /:Prune:zeroOverX
  • +:Prune:combineConstants
  • Derivative:Prune:eval
  • +:Prune:combineConstants
  • Derivative:Prune:eval
  • Prune
  • Expand
  • Prune
  • Factor
  • Prune
  • *:Tidy:apply
  • *:Tidy:apply
  • Tidy
  • /:Prune:xOverX
  • Limit:Prune:apply
  • Limit:Prune:apply
  • Limit:Prune:apply