Re: Newbie Question About An Error Message

*To*: mathgroup at smc.vnet.net*Subject*: [mg55457] Re: [mg55443] Newbie Question About An Error Message*From*: DrBob <drbob at bigfoot.com>*Date*: Thu, 24 Mar 2005 03:41:56 -0500 (EST)*References*: <200503231034.FAA04057@smc.vnet.net>*Reply-to*: drbob at bigfoot.com*Sender*: owner-wri-mathgroup at wolfram.com

This is a correct answer for the given input: D[abs[{x - xi}]^2, x] 2*abs[{x - xi}]* Derivative[{1}][abs][{x - xi}] But you meant Abs, not "abs", and make sure x doesn't have a value, or you'll get an error differentiating with respect to a constant. The other error (from Part) can't come from that input, so I think you haven't sent us the input as it actually was. Bobby On Wed, 23 Mar 2005 05:34:54 -0500 (EST), Adam Hartshorne <oracle3001 at yahoo.com> wrote: > Hi All, > > I am a real newbie to mathematica and have just encountered the > following error message and I have no idea why and what it means. > > I have written a function to calculate the abs of a vector as follows > > abs[x_] := Sqrt[x[[1]]^2+x[[2]]^2+x[[3]]^2] > > then i was doing the following fine until a few moments ago and > mathematica starting complaining. I am to my knowledge not asking > anything different to what I asked it before, but I don't know enough > about mathematica to know much more. > > Ok then I try > > D[(abs[{x-xi}])^2,x] > > Which is know the answer to is 2(x-xi), and mathematica has given me the > answer. However now it is saying, maybe I have changed my input and no > am typing something wrong. > > Part::partw: Part 2 of {x - xi} does not exist. > > Part::partw: Part 3 of {x - xi} does not exist. > > Any help will be much appreciated, > > Adam > > > > -- DrBob at bigfoot.com

**References**:**Newbie Question About An Error Message***From:*Adam Hartshorne <oracle3001@yahoo.com>