[SciPy-user] New Lyx Version eas(ier) to install on Windows.

Dan Christensen jdc at uwo.ca
Fri Feb 10 10:56:06 CST 2006

Fernando Perez <Fernando.Perez at colorado.edu> writes:

> The joys of reading (and getting right in the first place):
> \begin{eqnarray}
> g_{n} & = & \mathbf{T}_{n}^{b_{n}}f_{n}+\uparrow\left[\left(\mathbf{T}_{n-1}^{b_{
> n-1}}-\mathbf{T}_{n-1}^{\left\lfloor b_{n}/2\right\rfloor 
> }\right)f_{n-1}+\uparrow\left[\left(\mathbf{T}_{n-2}^{b_{n-2}}-
> \mathbf{T}_{n-2}^{\left\lfloor b_{n-1}/2\right\rfloor 
> }\right)f_{n-2}+\ldots\right.\right.\label{nsf.eq:apply_algo}\\
>   &  & \left.\left.\ldots+\left[\uparrow\left[\left(\mathbf{T}_{0}-\mathbf{T}_{0}^
> {\left\lfloor b_{1}/2\right\rfloor }\right)f_{0}\right]\right]\ldots\right]\right
> ].\nonumber
> \end{eqnarray}
> are replaced with a perfectly clear equation on screen, where I don't have to 
> worry about any latex errors and which is visually clear enough that I know 
> _exactly_, immediately, whether I typed what I meant or not.

It's exactly the awful latex that lyx produces that makes me prefer
latex.  The logical structure of that formula is completely hidden,
and it was probably hard to be sure that you got all of the
superscripts and subscripts correct.

I much prefer typing something like:

g_n =\ &\T{n}{b_n} f_n 
       + \uparrow \lb \TT{n-1}{n} 
       + \uparrow \lb \TT{n-2}{n-1}
       + \cdots \\                    
      &\cdots + \uparrow \lb \TTT{0}{1}{} \rb \cdots \rb \rb

Sure, this requires some ugly macros at the top of the file
(which I've included below);  but most likely, many of these
subexpressions occur throughout your paper, so it'll save you
typing and reduce the chance of typos if you get them right in
one spot.  Also makes it easy to adjust things, e.g. if you
decide to change the font of the T.

I'd say my way is more pythonic, to get this a bit more on
topic for the list...  :-)

By the way, my version gets rid of an unnecessary pair of square
brackets, uses correctly centered dots, has better spacing around 
the equals sign, and removes the \label (since the equation is
unnumbered).  :-)

You probably already know that emacs can display the rendered math
inline, so in some ways you get the best of both worlds...

Now if lyx was smarter about producing human readable latex,
then I might be convinced to switch...


The ugly macros:

\newcommand{\flr}[1]{\left\lfloor #1 \right\rfloor}

  {\left(\T{#1}{#3} - \T{#1}{\flr{b_{#2}/2}}\right) f_{#1}}


More information about the SciPy-user mailing list