{Sqrt[1+x^2]/(1-x^3), x, 12, (2/3)*ArcTan[(1 + x)/Sqrt[1 + x^2]] + (1/3)*Sqrt[2]*ArcTanh[(1 + x)/(Sqrt[2]*Sqrt[1 + x^2])]}
/MathematicaSyntaxTestSuite-4.16.0/1 Algebraic functions/1.3 Miscellaneous/1.3.2 Algebraic functions.m
┌ Warning: (* {(Sqrt[x]+x)^(2/3), x, 0} *)
/MathematicaSyntaxTestSuite-4.16.0/1 Algebraic functions/1.3 Miscellaneous/1.3.2 Algebraic functions.m
┌ Warning: (* {(-3*x+x^2)^(-1/3), x, 0} *)
/MathematicaSyntaxTestSuite-4.16.0/1 Algebraic functions/1.3 Miscellaneous/1.3.2 Algebraic functions.m
┌ Warning: (* {1/Sqrt[a*x+b*x^3], x, 0} *)
/MathematicaSyntaxTestSuite-4.16.0/1 Algebraic functions/1.3 Miscellaneous/1.3.2 Algebraic functions.m
┌ Warning: (* {E^(a + b*x + c*x^2)/(d + e*x)^2, x, 0} *)
E^x
used instead of Exp[x]
? Int([a_. + b_.*x_), x_Symbol]
mean?@miguelraz Internally Rubi uses inert trig functions to greatly reduce the number of circular and hyperbolic trig integration rules required.
Before searching for integration rules to apply, Rubi uses the utility routine DeactivateTrig
to convert integrands involving the 6 trig and 6 hyperbolic functions to equivalents ones involving just the 3 inert trig functions sin
, tan
and csc
.
For example, Cos[x] is converted to the inert sin[x+Pi/2]. If instead it was converted to the active Sin[x+Pi/2], Mathematica would immediately simplify it back to Cos[x]. Similarly, Sinh[x] is converted to -I sin[I x] and Cosh[x] is converted to sin[I x+Pi/2].
So just 1 rule instead of 4 are required to integrate Sin[x], Cos[x], Sinh[x] and Cosh[x] wrt x. Similar rule consolidations are done for the tangent and secant (circular and hyperbolic) trig functions.
Currently Rubi has over 2000 inert trig integration rules. Without this consolidation there would be over 8000 active trig and hyperbolic integration rules.
If[TrueQ[$LoadShowSteps], Int[...] :=
?
Modele[{...}]
is used in some places and With[{...}]
is used in other places? IIUC, both introduce a local scope to make the calculations less verbose.
@miguelraz When building Rubi with the ability to show steps, a few rules are hard-wired to display more meaningfully when the rule is applied. For your purposes, just assume $LoadShowSteps
is False and use the Int
rule defined by the fail condition of the If statement.
See the Mathematica online help for the distinction between With
, Module
and Block
.
E^x
and Exp[x]
are interchangeable since Mathematica automatically simplifies the latter to the former.
@cbauer:matrix.org I'm glad you find Rubi's integration prowess of value.
When showing integration steps, you and others have requested a way to find for the rules being applied the documentation included with their definition in Rubi's source files.
As a help toward that end, now available on Rubi's website is an Integration Rule Index. It shows the numbers of the rules defined in each of the rule source files. For more on using the index, see the third paragraph of the Rules menu option on the website
Hello, hope all is well.
I have a somewhat conceptual (although possibly very stupid) question. If we have that s = Int[e, x]
, then is it reasonable to expect that D[s, x] - e
is equal to 0 (possibly after applying Simplify
to the left-hand side)?
This, of course, generally holds, but there are a few cases where this is not the case, for example:
Int[(f^x * x^2) / ((a + b*f^(2*x))^3), x]
Int[x / (b / (f^x) + a * f^x)^3, x]
Can someone explain me what is going on here? I asked a similar question somewhere in SymPy's GitHub issues and the people there explained to me that it is possible to get such discrepancies because of some implicit assumptions, related to the domains for which the integrand and the result of the integration are defined. I am not sure that this is also the case here, though. Am I terribly wrong somewhere? Thanks
@mpeychev_gitlab If the derivative of the antiderivative Rubi returns is not equal to the integrand, I consider the antiderivative incorrect and a bug in Rubi. However, the host CAS, in this case Mathematica, may not be able demonstrate expressions equal even using FullSimplify.
The optimal antiderivatives of each of the 70,000+ integrals in Rubi's test-suite has been verified correct. Sometimes this requires manually helping out Mathematica show equality using various techniques.
@jg3c:matrix.org The Rubi-5 repository has the latest information on the Rubi 5 Project.
It contains an actual functioning prototype of Rubi 5 that shows the structure of the proposed integrator. Also it provides an example how to compile Rubi 4 pattern matching rules into a Rubi 5 if-then-else decision tree. The repository's README file provides more details.