This is in some sense good, since we don't have to care about the derivative at zero,but in an other sense it is not so good, since the subdifferential ∂abs(0) = [0,1] is a bounded and with this definition one could come to the false conclusion that abs(x)has a pole, althoug by taking limits one can easily see that it should be bounded at zero.
On Nov 14, 2014 8:57 AM, "Bill Page" <bill...@newsynthesis.org> wrote:
>
> On 14 November 2014 02:19, Ondřej Čertík <ondrej...@gmail.com> wrote:
> > On Fri, Nov 14, 2014 at 12:14 AM, Ondřej Čertík <ondrej...@gmail.com> wrote:
> >> ...
> >> Ok, thanks for the confirmation.
> >>
> >> There is an issue though --- since |z| is not analytic, the
> >> derivatives depend on the direction. So along "x" you get
> >
> > |z|' = \partial |z| / \partial x = d |z| / d z + d |z| / d conjugate(z) =
> > conjugate(z) / (2*|z|) + z / (2*|z|) = Re(z) / |z|
> >
> > but along "y" you get:
> >
> > |z|' = \partial |z| / \partial i*y = d |z| / d z - d |z| / d conjugate(z) =
> > conjugate(z) / (2*|z|) - z / (2*|z|) = i*Im(z) / |z|
> >
> > So I get something completely different.
>
> It seems to me that we should forget about x and y. All we really need is
>
> |z|' = d |z| / d z = conjugate(z) / (2*|z|)
>
> and the appropriate algebraic properties of conjugate.
Sure, we can make a CAS return this. But then you get the 1/2 there.
>
> > So which direction should be preferred in the CAS convention and why?
> >
>
> Well, um, you did write: "Because I would like to get
>
> d|x| / d x = x / |x|
>
> for real x".
>
> The constant 1/2 is irrelevant.
Well, but how do I recover the real derivative from the complex one if they differ by a factor of 1/2?
In other words, what is the utility of such a definition then?
I can see the utility of differentiating with respect to x, as at least you must recover the real derivative results.
Ondrej
On Nov 14, 2014 11:30 AM, "Bill Page" <bill...@newsynthesis.org> wrote:
>
> On 14 November 2014 13:18, Ondřej Čertík <ondrej...@gmail.com> wrote:
> >
> > On Nov 14, 2014 8:57 AM, "Bill Page" <bill...@newsynthesis.org> wrote:
> >>
> >> It seems to me that we should forget about x and y. All we really need is
> >>
> >> |z|' = d |z| / d z = conjugate(z) / (2*|z|)
> >>
> >> and the appropriate algebraic properties of conjugate.
> >
> > Sure, we can make a CAS return this. But then you get the 1/2 there.
> >
>
> Yes.
>
> >> ...
> >> The constant 1/2 is irrelevant.
> >
> > Well, but how do I recover the real derivative from the complex one if they
> > differ by a factor of 1/2?
> >
>
> What do you mean by "the real derivative"?
The absolute value doesn't have a complex derivative, but it has a real derivative, over the real axis.
> Perhaps we can just define that as
>
> d f / d z + d f / d conjugate(z)
>
> > In other words, what is the utility of such a definition then?
> >
> > I can see the utility of differentiating with respect to x, as at least you
> > must recover the real derivative results.
> >
>
> You are not differentiating with respect to x, you are differentiating
> with respect to
>
> (z+conjugate(z))/2
Is that how you propose to define the derivatives for non-analytic functions? I am a little confused what exactly is your proposal.
I think one either leaves the derivatives of non analytic functions unevaluated, or defines them in such a way that one recovers the real derivative as a special case, as long as there are no inconsistencies.
Vladimir V. Kisil kisilv's patch
http://www.ginac.de/pipermail/ginac-devel/2013-November/002053
looks like a good start to me especially if one doesn't want to
consider the issue of derivatives of non-analytic functions in
general.
> I think you are overly focused on trying to define a derivative that
> reduces to the conventional derivative of non-analytic functions over
> the reals.
I've just been casually following this conversation, but I think it's
important that the derivative of abs(x) be sign(x) not 2*sign(x) or
1/2*sign(x).
If you use a different function, like f.wirtinger_derivative(), then
it doesn't matter so much.
David
On 2014-11-19 9:36 AM, "Bill Page" <bill...@newsynthesis.org> wrote:
> ...
> Then I noticed that if we have f=z we get
>
> conjugate(z).diff(z)
>
> which is 0. So the 2nd term is 0 and the result is just the first Wirtinger derivative.
>
> Perhaps I am misinterpreting something?
>
Oops, my fault. According to your definition
conjugate(z).diff(z) = 1
Bill.
Since this mostly concerns FriCAS I am cross posting to that group. I will also post the patch there. For FriCAS list reference the original email thread is here:
>
> This discussion is about how a CAS should handle (complex)
> differentiation. Since it started here, I would finish it here, so
> that the whole thread is in one mailinglist for future reference.
>
OK. It would be nice to know if other sage-devel subscribers actually
remain interested...