This is strange because I get:
I:=complexIntegrate(acos(x^2),x);
J:=complexNormalize(D(I,x)-acos(x^2));
complexNumeric eval(J,x=1/2) --> .. E-20
tst(z) == complexNumericIfCan eval(J,x=z) --> ~0 for most z ;)
There must be another issue (eval doesn't commute wiht complexNormalize):
complexNumeric complexNormalize(eval(D(I,x)-acos(x^2),x=1/2)) --> -
2.6362321433 - 0.7 E -20 %i
complexNumeric eval(complexNormalize(D(I,x)-acos(x^2)),x=1/2) --> -
0.1866265314 E -20 - 0.7228014483 E -20 %i
By the way, the result of complexIntegrate(acos(x^2),x) seems to be
correct, at least in fricas.
Using the log repr of acos, D(I,x)-acos(x^2) reads:
R:=normalize (D(I,x)+%i*log(x^2+%i*sqrt(1-x^4)));
real R --> 0
imag numer R --> 0 (after a manual subst).
On Wednesday, 28 January 2026 at 09:11:26 UTC+1 Fabian wrote:
> Hello FriCAS group,
>
> Thank you Kurt, Qian, and Waldek for your prompt replies. I have tried out
> the suggestion by Kurt to use complexIntegrate. The following check
> indicates that this does not work for acos(x^2):
>
> from sage.interfaces.fricas import fricas
> fricas.eval(
> "f:=acos(x^2);"
> "F:=complexIntegrate(f,x);"
> )
> print(fricas("complexNumeric(eval(D(F,x)-f,x=1/2))"))
>
> This produces the output - 2.63..., which is not close to desired value 0.
>
> Fabian
>
> On Wednesday, January 28, 2026 at 3:33:46 AM UTC+1 Waldek Hebisch wrote:
>
>> On Wed, Jan 28, 2026 at 10:09:14AM +0800, Qian Yun wrote:
>> > Thanks for the report.
>> >
>> > Git bisect points to
>> >
>> https://github.com/fricas/fricas/commit/1f42999f91ce516a8d027a61be4ecbf32ad2ada4
>>
>> >
>> > "Handle some elliptic integrals", June 14, 2022.
>> > (Between 1.3.7 and 1.3.8)
>> >
>> > Before this commit, the result is a integral sign
>> > which means fricas proves it does not have elemental
>> > integral, which is correct.
>>
>> The reason is that transformations used in postprocessing result
>> of integration may incorrectly transform elliptic integrals to
>> 0.
>>
>> >
>> > - Best,
>> > - Qian
>> >
>> > On 1/28/26 1:42 AM, Fabian wrote:
>> > > Hello FriCAS group,
>> > >
>> > > It looks like I found a bug in FriCAS:
>> > > F:=integrate(acos(x^2),x)
>> > > gives:
>> > > +--------+
>> > > | 4 2 2
>> > > - 2 \|- x + 1 + x acos(x )
>> > > ----------------------------
>> > > x
>> > >
>> > > D(F,x)-acos(x^2)
>> > > gives the following instead of 0:
>> > > 2
>> > > -------------
>> > > +--------+
>> > > 2 | 4
>> > > x \|- x + 1
>> > >
>> > > I use FriCAS via https://sagecell.sagemath.org/ . Here is some
>> Sage-code
>> > > that produces the above output:
>> > >
>> > > from sage.interfaces.fricas import fricas
>> > > fricas.eval(
>> > > "F:=integrate(acos(x^2),x)"
>> > > )
>> > > print("F=\n",fricas("F"))
>> > > fricas.eval("f:=D(F,x)-acos(x^2)")
>> > > print("F'-acos(x^2)=\n",fricas("f"))
>> > >
>> > > The FriCAS version is 1.3.12. (print(fricas.eval(")lisp |
>> > > $build_version|") tells me this.)
>> > >
>> > > The SageMath version is 10.8, Release Date: 2025-12-18. (version()
>> tells
>> > > me this.)
>> > >
>> > > Fabian
>> > >
>> > > --
>> > > You received this message because you are subscribed to the Google
>> > > Groups "FriCAS - computer algebra system" group.
>> > > To unsubscribe from this group and stop receiving emails from it,
>> send
>> > > an email to [email protected] <mailto:fricas-
>> > > [email protected]>.
>> > > To view this discussion visit
>> https://groups.google.com/d/msgid/fricas-
>> > > devel/e5fde980-d9d7-4e5d-9fb9-d1cc5c45c021n%40googlegroups.com
>> <https://
>> > > groups.google.com/d/msgid/fricas-devel/e5fde980-d9d7-4e5d-9fb9-
>> > > d1cc5c45c021n%40googlegroups.com?utm_medium=email&utm_source=footer>.
>>
>> >
>> > --
>> > You received this message because you are subscribed to the Google
>> Groups "FriCAS - computer algebra system" group.
>> > To unsubscribe from this group and stop receiving emails from it, send
>> an email to [email protected].
>> > To view this discussion visit
>> https://groups.google.com/d/msgid/fricas-devel/e34f4198-37cd-463a-9c65-fba93aa7f97f%40gmail.com.
>>
>>
>>
>> --
>> Waldek Hebisch
>>
>
--
You received this message because you are subscribed to the Google Groups
"FriCAS - computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion visit
https://groups.google.com/d/msgid/fricas-devel/94236d47-fcc2-44b7-b8d1-83f57a3b27fan%40googlegroups.com.