On Wed, Mar 25, 2009 at 12:56 AM, Rob Beezer <goo...@beezer.cotse.net> wrote:
> I frequently use Sage as a sort of equation editor.  If I need a 10 x
> 10 identity matrix in a document, its easier to contruct the matrix in
> Sage and call latex() on it.  Of course, this is not the raison d'etre
> for Sage, but I find its latex support a real plus.  Making some of
> these stylistic decisions configurable globally would make it even
> better.

Here's a concrete proposal on how to arrange style configuration.
Rather than having a global setting in sage which alters the latex
code which is output (e.g. \mathbb{Z}  vs. \mathbf{Z}), define a set
of latex macros which configure the way the latex output is rendered.

For example, the latex output for ZZ could be "\ZZ" or "\sageZZ", etc.
And so on with macros for the different fields and rings, and also
macros to render sage matrices, etc.

Then we can use a package, say "sage.sty", which defines all this
symbols in some way. then the user can configure
the way ZZ is rendered with one of the following options:

1) use \renewcommand for the symbols to be customized, right after
\usepackage{sage}
2) edit sage.sty to suit the desired style
3) implement a sage-local.sty package which imports sage.sty then
redefines some styles
4) there may already be alternate implementations of sage.sty by
different authors, so choose which style to go with.

What is important in this idea is that the actual "latex
representation" of sage objects would be invariant. one could "borrow"
latex objects from one paper to another, even if the papers have
different styles. Writing papers with different coauthors using
different styles would not require changing configuration of sage,
etc.

The only drawback I see is that the latex code won't work standalone,
i.e. unless \usepackage{sage} is included. I don't know if jsmath, for
instance, can be adjusted to this (without hacking it, that is).

Gonzalo

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to 
sage-devel-unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to