Skip to main content
Post Closed as "Duplicate" by J. M.'s missing motivation
Tweeted twitter.com/StackMma/status/742833265552326656
deleted 124 characters in body
Source Link
David G. Stork
  • 42.3k
  • 3
  • 37
  • 106

I've been beating my face against the desk for awhile trying to figure this out, and it's driving me absolutely nuts!

The following code produces the graph of $f(x)=\frac{1}{x-1}$ correctly.

 Plot[1/(x - 1), {x, -5, 5}, PlotRange -> {{-5, 5}, {-5, 5}}, 
 PlotStyle -> {Thick}, BaseStyle -> {FontSize -> 14}, 
 Exclusions -> {x - 1 == 0}, 
 ExclusionsStyle -> Directive[Red, Dashed]]

enter image description here

However, when I try to graph $f(x)=\frac{1}{(x-1)^2}$ with essentially the same code, I lose the vertical asymptote.

Plot[1/(x - 1)^2, {x, -5, 5}, PlotRange -> {{-5, 5}, {-5, 5}}, 
PlotStyle -> {Thick}, BaseStyle -> {FontSize -> 14}, 
Exclusions -> {(x - 1)^2 == 0}, 
ExclusionsStyle -> Directive[Red, Dashed]]

enter image description here

I have tried all sorts of permutations of writing the exclusions, but nothing seems to work! From From what I can tell, whenever I try to graph a rational function that has a factor in the denominator with an even power, the vertical asymptote fails to draw.

Any help would be greatly appreciated!

I've been beating my face against the desk for awhile trying to figure this out, and it's driving me absolutely nuts!

The following code produces the graph of $f(x)=\frac{1}{x-1}$ correctly.

 Plot[1/(x - 1), {x, -5, 5}, PlotRange -> {{-5, 5}, {-5, 5}}, 
 PlotStyle -> {Thick}, BaseStyle -> {FontSize -> 14}, 
 Exclusions -> {x - 1 == 0}, 
 ExclusionsStyle -> Directive[Red, Dashed]]

enter image description here

However, when I try to graph $f(x)=\frac{1}{(x-1)^2}$ with essentially the same code, I lose the vertical asymptote.

Plot[1/(x - 1)^2, {x, -5, 5}, PlotRange -> {{-5, 5}, {-5, 5}}, 
PlotStyle -> {Thick}, BaseStyle -> {FontSize -> 14}, 
Exclusions -> {(x - 1)^2 == 0}, 
ExclusionsStyle -> Directive[Red, Dashed]]

enter image description here

I have tried all sorts of permutations of writing the exclusions, but nothing seems to work! From what I can tell, whenever I try to graph a rational function that has a factor in the denominator with an even power, the vertical asymptote fails to draw.

Any help would be greatly appreciated!

The following code produces the graph of $f(x)=\frac{1}{x-1}$ correctly.

 Plot[1/(x - 1), {x, -5, 5}, PlotRange -> {{-5, 5}, {-5, 5}}, 
 PlotStyle -> {Thick}, BaseStyle -> {FontSize -> 14}, 
 Exclusions -> {x - 1 == 0}, 
 ExclusionsStyle -> Directive[Red, Dashed]]

enter image description here

However, when I try to graph $f(x)=\frac{1}{(x-1)^2}$ with essentially the same code, I lose the vertical asymptote.

Plot[1/(x - 1)^2, {x, -5, 5}, PlotRange -> {{-5, 5}, {-5, 5}}, 
PlotStyle -> {Thick}, BaseStyle -> {FontSize -> 14}, 
Exclusions -> {(x - 1)^2 == 0}, 
ExclusionsStyle -> Directive[Red, Dashed]]

enter image description here

I have tried all sorts of permutations of writing the exclusions, but nothing seems to work! From what I can tell, whenever I try to graph a rational function that has a factor in the denominator with an even power, the vertical asymptote fails to draw.

Any help would be greatly appreciated!

Source Link
Jon
  • 213
  • 2
  • 5

Plotting Vertical Asymptotes

I've been beating my face against the desk for awhile trying to figure this out, and it's driving me absolutely nuts!

The following code produces the graph of $f(x)=\frac{1}{x-1}$ correctly.

 Plot[1/(x - 1), {x, -5, 5}, PlotRange -> {{-5, 5}, {-5, 5}}, 
 PlotStyle -> {Thick}, BaseStyle -> {FontSize -> 14}, 
 Exclusions -> {x - 1 == 0}, 
 ExclusionsStyle -> Directive[Red, Dashed]]

enter image description here

However, when I try to graph $f(x)=\frac{1}{(x-1)^2}$ with essentially the same code, I lose the vertical asymptote.

Plot[1/(x - 1)^2, {x, -5, 5}, PlotRange -> {{-5, 5}, {-5, 5}}, 
PlotStyle -> {Thick}, BaseStyle -> {FontSize -> 14}, 
Exclusions -> {(x - 1)^2 == 0}, 
ExclusionsStyle -> Directive[Red, Dashed]]

enter image description here

I have tried all sorts of permutations of writing the exclusions, but nothing seems to work! From what I can tell, whenever I try to graph a rational function that has a factor in the denominator with an even power, the vertical asymptote fails to draw.

Any help would be greatly appreciated!