       Re: Differentiation w.r.t. elements of lists

• To: mathgroup at smc.vnet.net
• Subject: [mg79712] Re: Differentiation w.r.t. elements of lists
• From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
• Date: Thu, 2 Aug 2007 03:54:58 -0400 (EDT)
• Organization: Uni Leipzig
• References: <f8pi48\$1l4\$1@smc.vnet.net>
• Reply-to: kuska at informatik.uni-leipzig.de

```Hi,

and you are shure that

> Another, even shorter test case would be
>
> D[x[[i]], x[[j]]]
>
> which "should", IMHO, return KroneckerDelta[i,j].

??

Than
D[x[],x[]]

should be zero ? right ?? but what is

with

x = {Sin[y], y}

D[x[], x[]]

the result is not 0 ..

may be that you are wrong.

Regards
Jens

Daniel Hornung wrote:
> Hello,
> I don't know if what I want to do is impossible to do neatly (probably not)
> or whether I simply chose the wrong way (maybe).
>
> Basically I want to do componentwise differentiation.  Here's a short test
> case:
> ----
> In := h[x_]:=Sum[x[[j]]^2,{j,1,Length[x]}]
>
> In := dh[x_,i_]=D[h[x],x[[i]]]
>>From In:=
> Part::pspec: Part specification i is neither an integer nor a list of
> integers. Mehr...
> Out= 0
>
> In:= Assuming[i\[Element]Integers&&i>0&&i<=n,dh[x_,i_]=D[h[x],x[[i]]]]
>>From In:=
> Part::pspec: Part specification i is neither an integer nor a list of
> integers. Mehr...
> Out= 0
> ----
>
> What I would want is a result like dh[x_,i_]=2x[[i]], of course.
>
> Another, even shorter test case would be
>
> D[x[[i]], x[[j]]]
>
> which "should", IMHO, return KroneckerDelta[i,j].
>
> Any ideas or hints how to solve these problems in a nice way?
>
> Thank you in advance,
> Daniel Hornung
>

```

• Prev by Date: Re: Is Save As->HTML broken in 6.0?
• Next by Date: Re: removing those annoying \$\$\$\$'s from local variables names?
• Previous by thread: Re: removing those annoying \$\$\$\$'s from local variables names?
• Next by thread: Re: Differentiation w.r.t. elements of lists