help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Latex Fonts and Octave


From: Ben Abbott
Subject: Re: Latex Fonts and Octave
Date: Thu, 26 Mar 2009 21:44:44 -0400


On Mar 26, 2009, at 9:28 PM, Thomas Markovich wrote:

<groundstate1.ps>

(I attached something, did it work?)

We just have a few things like that. They're generated through a fourier sum. Using psfrag we replaced asd with \varphi and zxc with \psi_0^{(+)}(\varphi).

On Mar 26, 2009, at 8:24 PM, Ben Abbott wrote:

hmmm ... I'm not certain what you imply by "image". Are you using octave's image toolbox?

So I understand better, can you explain what your figure is illustrating? ... perhaps you can provide a link to something similar?

Ben


Great, there is a solution to your problem! ... actually more than one.

(1) First a broad solution ...

Mac OSX has access to a lot of nice Linux stuff (I'm a Mac OSX user myself).

If haven't already done so, I recommend you install either the Fink or DarwinPorts package manager. The link below compares the two.

        
http://abstract.cs.washington.edu/wiki/index.php/Mac_Users:DarwinPorts_vs_Fink

I'm using Fink, but many prefer DarwinPorts.

Each of these package managers make installing and updating software a breeze.

If you install xfig

        http://en.wikipedia.org/wiki/Xfig

You can use Octave's "fig" terminal to produce an xfig file that you can read using xfig and then export the result in various formats ... which include a PDF/LaTeX format as well as a TIFF format.

I like xfig, but it *may* take some time to get use to. The links below should be helpful for your problem.

http://epb.lbl.gov/xfig/frm_printing.html (see the section "xfig and PDFLaTeX")

Each of these package managers can also keep Octave, gnuplot, and LaTeX up to date!

(2) You might also try converting the xfig file to a tikz file (using fig2tikz)

        
http://kogs-www.informatik.uni-hamburg.de/~meine/software/figpy/#fig2tikz

(3) You can try using png/TikZ to solve your problem. This approach will allow you to produce the figure from within LaTeX.

        http://www.texample.net/tikz/examples/gnuplot-basics/

(4) You can use my original suggestion

        a) Produce your figure using Octave
        b) Then from Octave's command line, type

                drawnow ("latex", "your_figure.tex")

        c) Include it in your paper using the commands below.

          \begin{figure}
            \begin{center}
              \setlength{\unitlength}{2.54cm}
              \begin{picture}(6.4,4.8)
                \input{test.tex}
              \end{picture}
            \end{center}
            \caption{The figure's caption goes here.}
            \label{fig:label_for_ref}
          \end{figure}

        Be sure to change the (6.4,4.8) to obtain the figure size you desire.

You mentioned that this solution didn't give you want you wanted. Can you be more specific?

Ben


reply via email to

[Prev in Thread] Current Thread [Next in Thread]