Graphics, Figures & TablesRemovable discontinuity Graph

Information and discussion about graphics, figures & tables in LaTeX documents.
coachbennett1981
Posts: 274
Joined: Fri Feb 05, 2010 10:15 pm

Removable discontinuity Graph

Post by coachbennett1981 »

I am trying to graph f(x)=[(x+2)(x+3)]/(x+2) in PStricks, I know that I should have a point of discontinuity at x=-2, where the denominator would be zero. PStricks does not show this, I am assuming the it is graphing just x+3 after simplifying this. Is there a way to show discontinuity? Would I have to draw a circle and restrict the domain of the function?

Code: Select all

\documentclass{minimal}
\usepackage{pstricks-add}


\begin{document}

\pspicture(-3,-3)(3,10)
\psaxes[Oy=2]{<->}(0,0)(8,6)(-8,-8)
    \psplot[arrows=<->,linewidth=2pt,linecolor=red]{-4}{1}{x 3 add x 2 add mul x 2 add div}
   
\endpspicture


\end{document}

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Removable discontinuity Graph

Post by localghost »

The Postscript language is smart enough to calculate the result as x+3 so that there is no discontinuity plotted. And from the pure mathematical standpoint there isn't a discontinuity anyway.


Best regards
Thorsten
CrazyHorse
Posts: 351
Joined: Sat Aug 02, 2008 8:47 am

Removable discontinuity Graph

Post by CrazyHorse »

coachbennett1981 wrote:I am trying to graph f(x)=[(x+2)(x+3)]/(x+2) in PStricks, I know that I should have a point of discontinuity at x=-2, where the denominator would be zero. PStricks does not show this, I am assuming the it is graphing just x+3 after simplifying this. Is there a way to show discontinuity? Would I have to draw a circle and restrict the domain of the function?
f(x)=[(x+2)(x+3)]/(x+2) is the same as f(x)=x+3

do you mean f(x)=[(x-2)(x+3)]/(x+2)?

Herbert
User avatar
gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Removable discontinuity Graph

Post by gmedina »

localghost wrote:The Postscript language is smart enough to calculate the result as x+3 so that there is no discontinuity plotted. And from the pure mathematical standpoint there isn't a discontinuity anyway.
No, that's not true. The function given by f(x)=[(x+2)(x+3)]/(x+2) has a removable discontinuity at x=-2, whilst f(x)=x+3 is continuous in all of its domain. For all the other points (x\neq -2), the two functions are the same.
CrazyHorse wrote: f(x)=[(x+2)(x+3)]/(x+2) is the same as f(x)=x+3
No, they are not the same (as I already explained): the latter has all of the real numbers as its domain; the former is not defined for x=-2.

In terms of the graphs this implies that the graphs will be different at the point: x=-2. The graph of the second function (being continous) will have no "holes", while the graph of the first one will have a "hole" at x=-2.
Last edited by gmedina on Sat Apr 10, 2010 5:11 pm, edited 1 time in total.
1,1,2,3,5,8,13,21,34,55,89,144,233,...
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Removable discontinuity Graph

Post by localghost »

gmedina wrote:No, they are not the same: the latter has all of the real numbers as its domain; the former is not defined for x=-2.

In terms of the graphs this implies that the graphs will be different at the point: x=-2. The graph of the second function (being continous) will have no "holes", while the graph of the first one will have a "hole" at x=-2.
If so, then why do all plot programs cancel (x+2) and simply plot f(x)=x+3 over the entire range of the domain? Of course these functions are identical. Logically you always cancel common factors from nominator and denominator. And there will be no way to visualize the discontinuity in this case.
User avatar
gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Removable discontinuity Graph

Post by gmedina »

localghost wrote: If so, then why do all plot programs cancel (x+2) and simply plot f(x)=x+3 over the entire range of the domain?..
I don't know if that is true, but in case it is, then all plot programs are poorly programmed (at least for cases like this one).
localghost wrote: ...Of course these functions are identical. Logically you always cancel common factors from nominator and denominator...
In the expression f(x)=[(x+2)(x+3)]/(x+2) you can cancel out the factor (x+2) if and only if x\neq -2; otherwise you are "dividing by zero" which is not possible. Not noticing this fact is a common mistake.
localghost wrote:...And there will be no way to visualize the discontinuity in this case.
The standard procedure in cases like this one is to represent the discontinuity with a "hole" in the graph of the function; take a look at example 1, here:

http://en.wikipedia.org/wiki/Classifica ... s#Examples
1,1,2,3,5,8,13,21,34,55,89,144,233,...
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Removable discontinuity Graph

Post by localghost »

gmedina wrote:[…]The standard procedure in cases like this one is to represent the discontinuity with a "hole" in the graph of the function; take a look at example 1, here:

http://en.wikipedia.org/wiki/Classifica ... s#Examples
The examples are not continuous at the critical point, but only continuable. The discussed function is continuous. You can find that out by forming the limes of the differential quotient from different sides.

Supplement:
I remember one striking sentence from my lectures in mathematics:
Sum, Difference, Product and Quotient of continuous functions are continuous themselves.
User avatar
gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Re: Removable discontinuity Graph

Post by gmedina »

No. The function f(x)=[(x+2)(x+3)]/(x+2) is not continuous at x=-2. If you evaluate the lateral limits as x approaches -2 you will find in both cases that both limits exist and are equal to 1, so the (bilateral) limit of f as x approaches -2 exists and is 1; this alone, however, does not imply continuity. The other prerequisite for a function to be continuous at a point is that that the limit (once you know that it exists) must be equal to the value of the function at the point; in our particular case, f is not defined at x=-2, so it has a removable discontinuity there.
1,1,2,3,5,8,13,21,34,55,89,144,233,...
User avatar
gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Removable discontinuity Graph

Post by gmedina »

localghost wrote: Supplement:
I remember one striking sentence from my lectures in mathematics:
Sum, Difference, Product and Quotient of continuous functions are continuous themselves.
Yes, and precisely sentences like those (that forget to mention relevant conditions) are the cause of misunderstandings and errors like the one discussed here. The last part "Quotient of continuous functions are continuous themselves" forgets to mention something extremely relevant: "whenever they are defined"
1,1,2,3,5,8,13,21,34,55,89,144,233,...
coachbennett1981
Posts: 274
Joined: Fri Feb 05, 2010 10:15 pm

Re: Removable discontinuity Graph

Post by coachbennett1981 »

So, did anyone come up with a solution to my graph =0). The discontinuity is removable because you can simplify the expression..
Post Reply