MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: assigning functions

  • To: mathgroup at
  • Subject: [mg56229] Re: [mg56204] assigning functions
  • From: "Jaccard Florian" <Florian.Jaccard at>
  • Date: Wed, 20 Apr 2005 05:29:59 -0400 (EDT)
  • Sender: owner-wri-mathgroup at

Hello !

First way :  fprime[x_] = D[f[x], x]
Works fine...

Or :  fprime[x_] := Evaluate[D[f[x], x]]

But you can also just write   f'[2] !


-----Message d'origine-----
De : juejung [mailto:juejung at] 
Envoyé : mardi, 19. avril 2005 10:55
À : mathgroup at
Objet : [mg56204] assigning functions

dear all,

i would like to do the following.
assign a function:
f[x_] := x^2;

take its derivate:
D[f[x], x]

and assign the result of this to a new function, like fprime[x]:
fprime[x_] := D[f[x], x]

unfortunately that doesn't work.
when i try to evaluate fprime[2] i get an error message.

can somebody please help, this haunts me for a while now.

thanks and all the best


  • Prev by Date: Re: match 1, replace 2
  • Next by Date: Re: assigning functions
  • Previous by thread: Re: assigning functions
  • Next by thread: Re: assigning functions