Re: Beginner question: operating on piecewise defined functions
- To: mathgroup at smc.vnet.net
- Subject: [mg41698] Re: [mg41609] Beginner question: operating on piecewise defined functions
- From: "German Buitrago A." <gerbual at col2.telecom.com.co>
- Date: Sat, 31 May 2003 06:07:46 -0400 (EDT)
- References: <200305280857.EAA09573@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
Jan, you can use the Standard Add-On Package Calculus`Limit` and you should keep in mind the syntax of the function Limit: ?Limit "Limit[expr, x->x0] finds the limiting value of expr when x approaches x0." (Appreciate that the couple {} is not required around of "x -> Infinity") In[1]:= f[x_] := 1/x^2 /; x >= 1 In[2]:= f[x_] := 1 /; x < 1 In[5]:= << Calculus`Limit` In[6]:= Limit[f[x], x -> Infinity] Out[6]= 0 Greetings, German Buitrago A. Manizales, Colombia ----- Original Message ----- From: "Jan Rychter" <jan at rychter.com> To: mathgroup at smc.vnet.net Subject: [mg41698] [mg41609] Beginner question: operating on piecewise defined functions > If I define a piecewise function as, say: > > f[x_] := 1/x^2 /; x >= 1 > f[x_] := 1 /; x < 1 > > then how can I get Mathematica to operate on it, as in: > > Limit[f[x], {x->Infinity}] > > Just trying that returns the expression unevaluated, even though > defining: > > g[x_] := 1/x^2 > > and trying: > Limit[g[x], {x -> Infinity}] > > Yields, as expected: > > Out[7]= > {0} > > thanks, > --J. >
- References:
- Beginner question: operating on piecewise defined functions
- From: Jan Rychter <jan@rychter.com>
- Beginner question: operating on piecewise defined functions