Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm completely new to LaTeX and I'm trying to draw some state diagrams for an assignment.

So far the options I have found are

1- Use VauCanSon-G to generate the diagrams
2- Draw the diagrams in an external application

I definitely don't want to need 2 applications to write my assignment, so I must use the style. However, I have only ever install single .sty files and moved them to usr/share/texmf/tex/latex/[stylename] and use usepackage{[name]}.

This style is actually more than one (?) and has a bunch of other types of files listed on the download page. I've tried a couple times and always get errors. Can somebody point me in the right direction?

EDIT

I have downloaded and install texlive (and, thus tlmgr). I am sure that my setup is correct because I have been able to use styles I have not explicitly downloaded and install manually. However, when trying to run Herbert's example, I get several errors. I double check if I have the package installed:

max@linux-vwzy:~/downloads> tlmgr show vaucanson-g
package:     vaucanson-g
category:    Package
shortdesc:   PSTricks macros for drawing automata
longdesc:    VauCanSon-G is a package that enables the user to draw automata within texts written using LaTeX. The package macros make use of commands of PStricks
installed:   Yes
revision:    15878
cat-version: 0.4
cat-date:    2008-10-30 09:45:25 +0100
cat-license: lppl
collection:  collection-pstricks

So it is installed. Ideas?

share|improve this question
    
Have you considered the automata library from tikz? –  Peter Grill Nov 20 '11 at 4:48
    
I've just downloaded and extracted the zip from texample.net/tikz/builds. Unzipping it yields several directories and several files. Am I to place each file in my latex tree individually? (sorry for the beginner questions) –  MaxMackie Nov 20 '11 at 4:53
1  
Welcome to TeX.SE! Don't worry about asking 'beginner questions', the users here are generally very friendly. As far as the location of the style files, it's a good idea to let your distribution handle that as it will get the dependencies correct too; if you're using linux then you should be able to do so using tlmgr –  cmhughes Nov 20 '11 at 5:05
1  
I think you should download TeXLive. –  Peter Grill Nov 20 '11 at 5:17
1  
tlmgr is only included in the TeXLive version from tug.org/texlive, but not in the TeXLive from SuSE/Ubuntu/.... –  Herbert Nov 20 '11 at 6:43

1 Answer 1

up vote 3 down vote accepted

save the files of the tarzip from the http://mirror.ctan.org/graphics/pstricks/contrib/vaucanson-g.zip and save the files in your home directory: ~/texmf/tex/generic/vaucanson Then it should be find by TeX.

\documentclass[]{article}
\usepackage{vaucanson-g}

\begin{document}
\begin{VCPicture}{(0,-2)(5.5,2)}
  \State[p]{(0,0)}{A}
  \State{(2.5,0)}{B}
  \State[r]{(5.5,0)}{C}
  \Initial{A} \Final{C}
  \EdgeL{A}{B}{a} \ArcL{B}{C}{b} \ArcL{C}{B}{b}                                                                                                                        
  \LoopN{A}{a} \LoopS{C}{d}                                                                                                             
\end{VCPicture}                                                                                                                         
\end{document}   

enter image description here

run the example with xelatex or latex->dvips->ps2pdf. A more complicated example can be found here: http://mirror.ctan.org/info/examples/PSTricks_en/33-04-3.ltx:

enter image description here

share|improve this answer
    
Thanks, I've edited my question to reflect my new problem –  MaxMackie Nov 20 '11 at 7:31

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.