Graphics, Figures & TablesPoint Plotting Problem

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

Point Plotting Problem

Post by coachbennett1981 »

I am trying to draw a solution to an inequality on a number line. However, when I draw the solution, (x<0), the point does not automatically go to zero. I know I can just mess with the ordered pair until it reaches where I want to, but I am wondering if their is something wrong in my code.

Code: Select all

\documentclass{article}
\usepackage{pstricks-add}
\usepackage{pst-func}
\usepackage{pst-tree}
\usepackage{color}



\begin{document}
\begin{center}
\psset{yAxis=false}
\psline[linecolor=blue,arrowinset=0,linewidth=2pt,arrowsize=.1]{<->}(0,0)(-5,0)
\psaxes[subticks=0,tickcolor=red,linecolor=blue,xlabelPos=bottom](0,0)(5,5)(-5,-5)
\psdots*[dotsize=.25,dotstyle=o](0,0)
\end{center}

\end{document}
I am wondering if it is because I am using psaxes. If anyone has suggestions on why I can't get the point directly on 0. Thank you

Nick
Last edited by coachbennett1981 on Sun Jun 13, 2010 3:02 pm, edited 1 time in total.

Recommended reading 2024:

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

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

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

Point Plotting Problem

Post by CrazyHorse »

coachbennett1981 wrote:I am trying to draw a solution to an inequality on a number line. However, when I draw the solution, (x<0), the point does not automatically go to zero. I know I can just mess with the ordered pair until it reaches where I want to, but I am wondering if their is something wrong in my code.

I am wondering if it is because I am using psaxes. If anyone has suggestions on why I can't get the point directly on 0.
use the pspicture environment, it kills unwanted glue

Code: Select all

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

\begin{document}
\begin{center}
\begin{pspicture}(-5,-0.5)(5,1)
\psset{yAxis=false}%
\psline[linecolor=blue,arrowinset=0,linewidth=2pt,arrowsize=.1]{<->}(0,0)(-5,0)%
\psaxes[subticks=0,tickcolor=red,linecolor=blue,xlabelPos=bottom](0,0)(5,5)(-5,-5)%
\psdots*[dotsize=.25,dotstyle=o](0,0)
\end{pspicture}
\end{center}

\end{document}
and load pstricks-add as last package -> documentation!

Herbert
coachbennett1981
Posts: 274
Joined: Fri Feb 05, 2010 10:15 pm

Re: Point Plotting Problem

Post by coachbennett1981 »

Herbert,

Thank you for the help in this matter... I will take your advice with the pstricks-add at the end of the file. I have a lot to learn..

Again,

Thank you
Post Reply