Question: How to show these two expressions are same?

These are the same (i.e. mathematically equivalent for real x)

A:=-x*(x - 4*exp(x/2) + 2);
B:=x*sqrt((-8*x - 16)*exp(x/2) + x^2 + 4*x + 16*exp(x) + 4);

But can't see how to use Maple to show this, other than numerically and by plotting.

Any one knows of a trick? Below is worksheet. Using another software, it was able to show they are same:

Here are my attempts in Maple 2025
 

interface(version);

`Standard Worksheet Interface, Maple 2025.0, Linux, March 24 2025 Build ID 1909157`

restart;

A:=-x*(x - 4*exp(x/2) + 2);
B:=x*sqrt((-8*x - 16)*exp(x/2) + x^2 + 4*x + 16*exp(x) + 4);

-x*(x-4*exp((1/2)*x)+2)

x*((-8*x-16)*exp((1/2)*x)+x^2+4*x+16*exp(x)+4)^(1/2)

plots:-display(Array([plot(A,x=-3..3),plot(B,x=-3..3)]))

 

 

Digits:=16;
seq(MmaTranslator:-Mma:-Chop(A-B),x=-2..2,.1)

16

0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0

simplify(A-B);

-x*(((-8*x-16)*exp((1/2)*x)+x^2+4*x+16*exp(x)+4)^(1/2)-4*exp((1/2)*x)+x+2)

simplify(A-B) assuming real;

-x*(((-8*x-16)*exp((1/2)*x)+x^2+4*x+16*exp(x)+4)^(1/2)-4*exp((1/2)*x)+x+2)

simplify(evala(A-B)) assuming real;

-x*(((-8*x-16)*exp((1/2)*x)+x^2+4*x+16*exp(x)+4)^(1/2)-4*exp((1/2)*x)+x+2)

simplify(normal(A-B)) assuming real;

-x*(((-8*x-16)*exp((1/2)*x)+x^2+4*x+16*exp(x)+4)^(1/2)-4*exp((1/2)*x)+x+2)

simplify(A-B,exp) assuming real;

-x*(((-8*x-16)*exp((1/2)*x)+x^2+4*x+16*exp(x)+4)^(1/2)-4*exp((1/2)*x)+x+2)

simplify(evalc(A-B)) assuming real;

-x*(((-8*x-16)*exp((1/2)*x)+x^2+4*x+16*exp(x)+4)^(1/2)-4*exp((1/2)*x)+x+2)

 

 

Download show_same_may_3_2025.mw

Please Wait...