12403 Reputation

19 Badges

8 years, 155 days

MaplePrimes Activity

These are replies submitted by vv

@ecterrab  Just want to notice that for an analytic f,  d/dz |f(z)|  exists in a nbd of a point  iff  f is constant.

@jschatzman A standard way to check symbolic results is to compute numerical values for several numerical values of the parameters (like evalf above). If the values agree (sometimes working with high precision if possible), there are big chances to have a correct symbolic result.

@jschatzman You are wrong. The integral for f=+-1/(2*Pi) is Pi/2 and must be considered in the sense of Cauchy principal value.
You can see this using a numerical evaluation:

evalf(Int(sin(x)*exp(-I*x)/x, x = -infinity .. infinity));


@Axel Vogt Actually, for a correct result, Heaviside(0) must be 1/2.

Note however that for f = +- 1/(2Pi), the integral must be considered in the sense of Cauchy principal value.

@Preben Alsholm I do not trust much in solve/identity for such complicated equations.
For example, sol:=solve(identity(EQ,X),[x0,y0,A]);
gives several solutions, but not the correct one: [x0 = 0, y0 = 0, A = 0]

@ecterrab  As mentioned in the definition, `diff/abs`  implements  d/dx |f(x+iy)|,  (for f analytic), not  d/dz |f(z)|. The latter does not exist because it's not a Wirtinger derivative. So,  obviously  d/dx conj(x+iy) = 1.
[for f analytic,  d/dx f = d/dz f].
`diff/abs`  is not suited for a general usage; it works for real variables (as in the provided example). A general solution will have to implement the rest of the nonanalytic functions.


@Carl Love I mean the example without x=y=0. The result of Maple (a+b+x)*(a+x+y)  is different from your simulation.

I don't think that automatic simplification can explain this.

By the way, your use of %%%f  is very ingenious!

@Carl Love OK, but what about the second example (with x,y) where the simuation does not agree with Maple?

@Carl Love Do you know how the automatic simplification can make the two results different for x=y=0?

@ecterrab I see two consequences of this approach:

--  Physics:-diff will be the only command giving different results when called directly or after with.

-- It will be impossible to compute Wirtinger derivatives in a procedure, unless Physics is already loaded (because with is forbidden in a proc). This is not a big problem because it is not hard to compute them directly ( see Old bug in `diff/abs` - MaplePrimes ) but unfortunately diff/abs &co  will have to be redefined (the mentioned "old bugs" are still present).

I am not very surprised by this behavior.
In the Physics package almost everything is redefined and a special environment is used.
This should not be a problem, but more and more "regular" functions call Physics routines.
The :-diff problem described is of course a bug, but even after a fix, similar problems are prone to pop up due to this design. 
In my opinion, Physics (an interesting and useful huge package) should have been completely separated by the rest of Maple, or incorporated into a distinct product.
Of course, I might be wrong about this.

@acer Thanks, you did it!
FF:=simplify(evalc(Re(Q))) assuming x::real;

is real and continuous. FF = F but the check is also a challenge.

@acer   int(convert(f,exp),x)  gives a concise elementary result but in terms of complex arctan, ln ...
and it is not continuous (for real x). Probably it can be converted to a real form, but evalc does not work well and complicates the expression.

I know to obtain F by hand, but I would be happy to see a Maple solution.

@acer The simplest way for a check seems to be

(simplify@@2@convert)(diff(H,x)-f, tan);   # 0

(note the double simplification!)

A bit simpler antiderivative is


For this, your simplification does not quite work, but an extra simplify almost does it.

P.S. It seems that simplfy should be revised.

@pallav This is not possible as my answer shows. It would be, if e.g. A were symmetric in x and sigma, but then A1 is independent of x, sigma. Take a simpler A to see what happens, e.g. A = x + 2 sigma^2 + x^2*c.  

4 5 6 7 8 9 10 Last Page 6 of 165