MathGroup Archive 2007

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

Search the Archive

Re: Delayed Derivative Operator

  • To: mathgroup at smc.vnet.net
  • Subject: [mg81785] Re: [mg81762] Delayed Derivative Operator
  • From: DrMajorBob <drmajorbob at bigfoot.com>
  • Date: Wed, 3 Oct 2007 06:08:54 -0400 (EDT)
  • References: <17850401.1191395290047.JavaMail.root@m35>
  • Reply-to: drmajorbob at bigfoot.com

For f'[x] to be defined, you first have to define f[x] -- and even then 
Mathematica may not "know" what f'[x] should be. These are fine:

f[x_] = x^3;
f'[x]

3 x^2

f[x_] := x^3
f'[x]

3 x^2

Clear[f]
f[x_] := If[x <= 0, x^3, x^-3]
f'[x]

If[x <= 0, 3 x^2, -(3/x^4)]

but this isn't quite so helpful:

Clear[f]
f[x_]/;x<=0:=x^3
f[x_]/;x>0:=x^-3
f'[x]

f'[x]

We take what we can get.

Bobby

On Wed, 03 Oct 2007 01:26:48 -0500, ToddSmith <elliptic1 at gmail.com> wrote:

> Hi,
>  I would like to be able to have an equation
>
> eq := D[f[x],x]==5;
>
> And a substitution rule
>
> rule = f[x]->x^3;
>
> And perform the substitution
>
> eq/.rule
>
> And get back the equation 3x^2==5. But Mathematica sees f'[x] and
> doesn't do any substitutions. I tried a delayed assignment for eq but
> it didn't work. What can I do?
>
> -Thanks
>
>
>



-- 

DrMajorBob at bigfoot.com


  • Prev by Date: Re: Multiple nests?
  • Next by Date: Re: Re: Equivalent functionality to colorbar in Mathematica?
  • Previous by thread: Re: Delayed Derivative Operator
  • Next by thread: Re: Re: Delayed Derivative Operator