Plotting (& not plotting) Asymptotes in Mathematica

In summary, to plot an asymptote in Mathematica, use the Asymptote function with the equation of the asymptote as its argument. Multiple asymptotes can be plotted on the same graph using this function and the Epilog option. To plot a vertical asymptote, use the VerticalAsymptote function with the x-value as its argument. Asymptotes that are not straight lines can also be plotted using the Asymptote function with more complex equations. To remove an asymptote from the graph, use the Exclusions option to specify which parts of the graph should be excluded.
  • #1
Stroodle
26
0
Hi.

I'm just starting to learn how to use Mathematica, and I'd like to know if there's a way to plot a graph of an equation, such
as [tex]y=\frac{a}{x-h}+k[/tex] without it showing the vertical asymptote

I would also like to know if there's a way to show the horizontal asymptote on the graph.

Thanks for your help
 
Physics news on Phys.org
  • #2
To turn off the vertical asymptote use the option Exclusions->h

To show a horizontal or diagonal asymptote simply plot it.
 
  • #3
Awesome. Thanks for your help.
 

1. How can I plot an asymptote in Mathematica?

To plot an asymptote in Mathematica, you can use the Asymptote function. This function takes in the equation of the asymptote as its argument and plots it on the graph. For example, if you want to plot the asymptote y = 2x + 3, you would use the command Asymptote[y = 2x + 3].

2. Can I plot multiple asymptotes on the same graph?

Yes, you can plot multiple asymptotes on the same graph by using the Asymptote function multiple times with different equations as arguments. You can also use the Epilog option to add additional lines or shapes to your graph.

3. How can I plot a vertical asymptote?

To plot a vertical asymptote, you can use the VerticalAsymptote function. This function takes in the x-value of the asymptote as its argument. For example, if you want to plot the vertical asymptote x = 3, you would use the command VerticalAsymptote[x = 3].

4. Can I plot an asymptote that is not a straight line?

Yes, you can plot asymptotes that are not straight lines by using the Asymptote function with more complex equations as arguments. For example, you can plot a hyperbolic asymptote by using the equation y = 1/x as the argument for Asymptote.

5. How can I remove an asymptote from my graph?

To remove an asymptote from your graph, you can use the Exclusions option. This option allows you to specify which parts of the graph should be excluded from the plot. You can use this option to exclude the asymptote you do not want to appear on the graph.

Similar threads

  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
724
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
203
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
6
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
3
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
4
Views
1K
Back
Top