Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #1876 > unrolled thread

Re: Limit[f[x], x->a] vs. f[a]. When are they equal?

Started byAndrzej Kozlowski <akoz@mimuw.edu.pl>
First post2011-04-25 11:29 +0000
Last post2011-04-26 10:50 +0000
Articles 3 — 3 participants

Back to article view | Back to comp.soft-sys.math.mathematica


Contents

  Re: Limit[f[x], x->a] vs. f[a]. When are they equal? Andrzej Kozlowski <akoz@mimuw.edu.pl> - 2011-04-25 11:29 +0000
    Re: Limit[f[x], x->a] vs. f[a]. When are they equal? Richard Fateman <fateman@cs.berkeley.edu> - 2011-04-26 08:43 +0000
      Re: Limit[f[x], x->a] vs. f[a]. When are they equal? Stefan <wutchamacallit27@gmail.com> - 2011-04-26 10:50 +0000

#1876 — Re: Limit[f[x], x->a] vs. f[a]. When are they equal?

FromAndrzej Kozlowski <akoz@mimuw.edu.pl>
Date2011-04-25 11:29 +0000
SubjectRe: Limit[f[x], x->a] vs. f[a]. When are they equal?
Message-ID<ip3lub$r9a$1@smc.vnet.net>
On 24 Apr 2011, at 23:22, Andrzej Kozlowski wrote:

>
> On 24 Apr 2011, at 15:25, Richard Fateman wrote:
>
>> On 4/23/2011 10:53 AM, Leonid Shifrin wrote:
>>> Richard,
>>>
>>> On Sat, Apr 23, 2011 at 4:49 AM, Richard Fateman
>>> <fateman@cs.berkeley.edu <mailto:fateman@cs.berkeley.edu>> wrote:
>>>
>>>   Let c=ComplexInfinity
>>>
>>>   then Mathematica (7.0) "knows" that Sin[c] is Indeterminate
>>>
>>>   but Limit[Sin[x],x->c]  is not evaluated.
>>>
>>>   I would have thought that if  f[a] is known, Limit[f[x],x->a] is
>>>   also known.
>>>
>>>
>>> Not necessarily. The limiting procedure has nothing to do with the
>>> value of the function at a given point, it has to do with values of
>>> the function in the neighborhood of that point.
>>>
>>> Regards,
>>> Leonid
>>>
>>>
>>>   RJF
>>>
>>>
>>
>> I agree not necessarily, but sine() is continuous and differentiable
>> everywhere.
>> I think a computer algebra system should do better.
>>
>>
>> I poked around some more..
>>
>> Limit[1 - Exp[I x], x -> 0]  yields 0
>> Limit[1/x, x->0]  yields Infinity
>>
>> Limit[1/(1 - Exp[I x]), x -> 0] yields  I*Infinity. ??
>>  I would think this would be a place for ComplexInfinity.
>>
>> All in Mathematica 7.0
>
> Mathematica uses DirectedInfinity[z] for representing various limits in the complex plane computed along straight lines and uses this concept when computing limits but not  when computing function values.  The answer CompexInfinity is not used when computing limits because it is considered essentially useless - it carries no information while directed infinities do. The answer DirectedInfinity[I] is, for example, justified by the fact that:
>
> In[17]:= Limit[ComplexExpand[Abs[1/(1 - Exp[I*x])]], x -> 0]
>
> Out[17]= Infinity
>
> Limit[ComplexExpand[Arg[1/(1 - Exp[I*x])]], x -> 0]
>
> Pi/2
>
>
> In other words, the limit has infinite modulus and argument Pi/2 - so it is exactly DirectedInfinity[I].
>
> So ComplexInfinity is used for values (e.g. 1/(I 0) ) but DirectedInfinity for limits
>
> In[18]:= Limit[1/(I*x), x -> 0]
>
> Out[18]= DirectedInfinity[-I]
>
> I don't myself know of any mathematical theory of "directed infinities" (although I have in the past indicated how I thought such a theory could be constructed) and there has been a discussion of this on this forum involving (among others) Maxim Rytin and myself.
>
> In fact this is precisely a case of computer algebra "doing better". One just has to understand what it is doing and why.
>
> Andrzej Kozlowski
>
>


I forgot to add that the function Sin is certainly not continuous at infinity (Sin[1/z] has an essential singularity at 0)  so there is no reason why it's value at there should agree with its limit. In fact, it definitely should not do so.


Andrzej Kozlowski

[toc] | [next] | [standalone]


#1880

FromRichard Fateman <fateman@cs.berkeley.edu>
Date2011-04-26 08:43 +0000
Message-ID<ip60jb$aav$1@smc.vnet.net>
In reply to#1876
On 4/25/2011 4:29 AM, Andrzej Kozlowski wrote:
....

>>
>
>
> I forgot to add that the function Sin is certainly not continuous at infinity (Sin[1/z]

has an essential singularity at 0)

so there is no reason why it's value at there should agree with its limit.

In fact, it definitely should not do so.
>
>
> Andrzej Kozlowski
>

Hm. continuity  (excerpt from wikipedia, but whatever)

The limit of f(x) as x approaches c through domain of f does exist and 
is equal to f(c); in mathematical notation, \lim_{x \to c}{f(x)} = f(c). 
If the point c in the domain of f is not a limit point of the domain, 
then this condition is vacuously true, since x cannot approach c through 
values not equal c. Thus, for example, every function whose domain is 
the set of all integers is continuous.

........
There is now a kind of semantic gap, it seems to me. There are, perhaps, 
several gaps.

One gap is between the mathematical concept of limit and the result of 
computing Limit[] in Mathematica.  Often they corresponds. Sometimes 
they differ. I see this difference appearing when the result in 
Mathematica is an Interval, and sometimes when the result is 
ComplexInfinity or its relatives.  I do not believe that the 
mathematical result  1/2+ i*(infinity) is the same as Mathematica's 
I*Infinity or ComplexInfinity. See below for a proof.

Another gap is around special symbolic values that might be used as 
limit points but which have no neighborhoods.  Look at the definition 
above. Is there some set of Mathematica values x1, x2, x3, ...., xn, ... 
all not equal to c, such that their distance from c becomes smaller, 
when c = Infinity? Apparently not, since Abs[x-Infinity] is Infinity for 
all x.

So we fall into the vacuously true clause, in which f[c] is the limit.

This is, I think, a consequence of introducing oddball pseudo-real 
objects into your computer system (notions like indeterminate, 
intervals, infinity).

It's possible I've overlooked something here and another definition of 
continuity more suitable for "hyperreals" or some computer-algebra 
topology fixes this all up.

Here's a fun thing to do with our function f[x_]:=1/(1-Exp[I x])  .

try Plot[Re[f[x]],{x,0.01,20}]
On my system it look like a plot of y=0.  A bug (Mathematica 7)?

And yet Re[f[0.5]] is 0.5, not zero. same for Re[f[0.01]].


Next try Plot[f[x]],{x,0.01,200}], to see some bubbles and a large oddly 
positioned spike between 70 and 80.

In fact, Re[f[x]] should always be 1/2.

As for Mathematica's return of Limit[f[x],x->0] as I*Infinity, I'm 
pretty sure that 1/2+I*Infinity is a better answer. I suspect it is a 
mistake to "simplify" that to I*Infinity.  Here's why.

Limit[f[x]-I/x,x->0]  comes out 1/2.

My answer preserves the identity  lim(A+B) = lim(A)+lim(B).

Mathematica's does not.  [This identity holds if lim(A) and lim(B) both 
exist, which apparently they do in Mathematica.)

Back to Andrzej's note.

  Sin(1/z) as z->0 is not the same as Sin[z] as z->ComplexInfinity.

1/z as z->0 has a neighborhood. There is no neighborhood around 
ComplexInfinity.

(I am not, incidentally, proposing that I have a complete solution to 
these issues.)








[toc] | [prev] | [next] | [standalone]


#1890

FromStefan <wutchamacallit27@gmail.com>
Date2011-04-26 10:50 +0000
Message-ID<ip681f$blf$1@smc.vnet.net>
In reply to#1880
On Apr 26, 4:43 am, Richard Fateman <fate...@cs.berkeley.edu> wrote:
> On 4/25/2011 4:29 AM, Andrzej Kozlowski wrote:
> ....
>
>
>
> > I forgot to add that the function Sin is certainly not continuous at infinity (Sin[1/z]
>
> has an essential singularity at 0)
>
> so there is no reason why it's value at there should agree with its limit.
>
> In fact, it definitely should not do so.
>
>
>
> > Andrzej Kozlowski
>
> Hm. continuity  (excerpt from wikipedia, but whatever)
>
> The limit of f(x) as x approaches c through domain of f does exist and
> is equal to f(c); in mathematical notation, \lim_{x \to c}{f(x)} = f(c).
> If the point c in the domain of f is not a limit point of the domain,
> then this condition is vacuously true, since x cannot approach c through
> values not equal c. Thus, for example, every function whose domain is
> the set of all integers is continuous.
>
> ........
> There is now a kind of semantic gap, it seems to me. There are, perhaps,
> several gaps.
>
> One gap is between the mathematical concept of limit and the result of
> computing Limit[] in Mathematica.  Often they corresponds. Sometimes
> they differ. I see this difference appearing when the result in
> Mathematica is an Interval, and sometimes when the result is
> ComplexInfinity or its relatives.  I do not believe that the
> mathematical result  1/2+ i*(infinity) is the same as Mathematica's
> I*Infinity or ComplexInfinity. See below for a proof.
>
> Another gap is around special symbolic values that might be used as
> limit points but which have no neighborhoods.  Look at the definition
> above. Is there some set of Mathematica values x1, x2, x3, ...., xn, ...
> all not equal to c, such that their distance from c becomes smaller,
> when c = Infinity? Apparently not, since Abs[x-Infinity] is Infinity for
> all x.
>
> So we fall into the vacuously true clause, in which f[c] is the limit.
>
> This is, I think, a consequence of introducing oddball pseudo-real
> objects into your computer system (notions like indeterminate,
> intervals, infinity).
>
> It's possible I've overlooked something here and another definition of
> continuity more suitable for "hyperreals" or some computer-algebra
> topology fixes this all up.
>
> Here's a fun thing to do with our function f[x_]:=1/(1-Exp[I x])  .
>
> try Plot[Re[f[x]],{x,0.01,20}]
> On my system it look like a plot of y=0.  A bug (Mathematica 7)?
>
> And yet Re[f[0.5]] is 0.5, not zero. same for Re[f[0.01]].
>
> Next try Plot[f[x]],{x,0.01,200}], to see some bubbles and a large oddly
> positioned spike between 70 and 80.
>
> In fact, Re[f[x]] should always be 1/2.
>
> As for Mathematica's return of Limit[f[x],x->0] as I*Infinity, I'm
> pretty sure that 1/2+I*Infinity is a better answer. I suspect it is a
> mistake to "simplify" that to I*Infinity.  Here's why.
>
> Limit[f[x]-I/x,x->0]  comes out 1/2.
>
> My answer preserves the identity  lim(A+B) = lim(A)+lim(B).
>
> Mathematica's does not.  [This identity holds if lim(A) and lim(B) both
> exist, which apparently they do in Mathematica.)
>
> Back to Andrzej's note.
>
>   Sin(1/z) as z->0 is not the same as Sin[z] as z->ComplexInfinity.
>
> 1/z as z->0 has a neighborhood. There is no neighborhood around
> ComplexInfinity.
>
> (I am not, incidentally, proposing that I have a complete solution to
> these issues.)

Richard,

Intrigued by your claims, I tried the same plots and did not see what
you describe. I believe you may have overlooked the labels of your
axes in these plots, since Mathematica doesnt always have the x and y
axes meet at the origin. In the first plot you mention, Plot[Re[f[x]],
{x, 0.01, 20}], the axes meet at (x,y) = (0,0.5) and the function is
constant = 0.5.
In the extended plot Plot[Re[f[x]], {x, 0.01, 200}], I do see the
bumps you mention, and I have no idea why that happens, I believe it
to be a question separate from the discussions here. Though I will
note that the axes on my plot ranged from 0.5 to 0.5 in increments of
zero!   This seems to be some strange manifestation of numerical
precision in Plot, rather than a problem with Mathematica evaluating
these functions. Zooming in on the largest bump in that graph, between
70 and 80, I actually found that the bump appeared to extend upward,
where the first graph showed it going down (though all still on a
seemingly infinitesimal range 0.5 to 0.5.  This seems like an
interesting question regarding the numerical methods of Plot which
deserves its own thread.
Finally, with regard to your argument about the limit. I both agree
with your reasoning, but disagree that it is a mistake to say that the
limit is I*Infinity. I think the issue may be more context sensitive.
While it might be important that your function has real part -> 1/2,
it is also the case that when compared to an imaginary part ->
Infinity, the real part is insignificant. Consider the phase of the
limit, Limit[Arg[f[x]],x->0], you would agree this is ArcTan[Infinity/
(1/2)] = Pi/2, and so I*Infinity is an appropriate answer. If you are
interested in the limit of the real part, then use Limit[Re[f[x]],x-
>0] which does indeed give you 1/2.

-Stefan S

[toc] | [prev] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web