Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
NCTM or The Math Forum.



Re: [mg4633] do we need to be moderated? Re: Piecewise Functions
Posted:
Aug 25, 1996 6:03 PM


george@mech.seas.upenn.edu ( George Jefferson ) [mg4633] do we need to be moderated? Re: Piecewise Functions Is concerned that >>>>> for a piecewise function:
f[x_ /; x> 0] := g[x] f[x_ /; x<=0] := h[x]
differentiation doesn't work correctly even where we specify the point x:
D[f[x],x] /. x> 1
f'[1]
<<<<<<<<
George: You can use If. Thus
f[x_]:= If[x<4,g[x],h[x]]
f'[x]
If[x < 4, g'[x], h'[x]] f'[3] g'[3]
f'[5] h'[5] Allan Hayes hay@haystack.demon.co.uk



