You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by Ross Gardler <rg...@apache.org> on 2004/02/05 15:57:07 UTC

How do I proceed (WAS Re: Forrest and Mathematics)

Reinhard Poetz wrote:
> From: Paul Smith [mailto:googoodolls_uk@yahoo.com] 
 >
> As I have never done anything similar I can't really help you with this
> but there was a similar discussion on user@cocoon.apache.org. See
> http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=107593758419194&w=2
> for details.

 From this link I got to http://jeuclid.sourceforge.net/

Where it says:

"The project is a component for the Apache Cocoon 
project(xml.apache.org). This component converts MathML documents to GIF 
images or SVG. So the user can easy write documents with embedding 
MathML fragments, and the component create in situ the GIF images. The 
SVG converter is used to create documents with embedding SVG fragments 
for e.g. the FOP to create PDF, or what else, documents."

This is under the APL but the project appears to be pretty dormant. 
There are screenshots of it working, but it may require some work to 
bring it up to date (originally maintainer has asked for someone to take 
over - see news section)

Ross


RE: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Conal Tuohy <co...@paradise.net.nz>.
Open Office Math is good for editing MathML. WYSIWYG.

> -----Original Message-----
> From: Justus H. Piater [mailto:Justus.Piater@ULg.ac.be]
> Sent: Monday, 9 February 2004 22:56
> To: forrest-dev@xml.apache.org
> Subject: Re: How do I proceed (WAS Re: Forrest and Mathematics)
> 
> 
> Stephan Michels <st...@apache.org> wrote on Sat, 07 Feb 2004
> 15:11:10 +0100:
> 
> > If you write more than just one equation, you will make a 
> difference,
> > for sure ;-) If you have a document with dozens of equations, MathML
> > makes it unmaintainable.
> 
> I find MathML tedious to code by hand, and hard to read too for
> non-trivial formulas. I have a setup that allows me to code all my
> math in LaTeX syntax, and a Makefile setup that uses an external Perl
> script and Ian Hutchinson's TTM to convert inlined LaTeX code to
> external MathML files that are then XIncluded. This allows me to
> hand-code math conveniently in LaTeX (which is processed directly by
> PassiveTeX until there is a FO processor that can render MathML), and
> convert it to MathML for the Web.
> 
> This gets me the best of both worlds: Easy coding and reading in
> LaTeX, and Web math in MathML without cluttering up my (validated) XML
> source files.


Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by "Justus H. Piater" <Ju...@ULg.ac.be>.
Stephan Michels <st...@apache.org> wrote on Sat, 07 Feb 2004
15:11:10 +0100:

> If you write more than just one equation, you will make a difference,
> for sure ;-) If you have a document with dozens of equations, MathML
> makes it unmaintainable.

I find MathML tedious to code by hand, and hard to read too for
non-trivial formulas. I have a setup that allows me to code all my
math in LaTeX syntax, and a Makefile setup that uses an external Perl
script and Ian Hutchinson's TTM to convert inlined LaTeX code to
external MathML files that are then XIncluded. This allows me to
hand-code math conveniently in LaTeX (which is processed directly by
PassiveTeX until there is a FO processor that can render MathML), and
convert it to MathML for the Web.

This gets me the best of both worlds: Easy coding and reading in
LaTeX, and Web math in MathML without cluttering up my (validated) XML
source files.

Justus

-- 
Justus H. Piater, Ph.D.         http://www.montefiore.ulg.ac.be/~piater/
Institut Montefiore, B28        Phone: +32-4-366-2279
Université de Liège, Belgium    Fax:   +32-4-366-2620


Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Stephan Michels <st...@apache.org>.
Am Fr, den 06.02.2004 schrieb Paul Smith um 16:57:
> > > Does this solution handle *all* TeX markup? 
> > 
> > Of course not all markup. This is impossible and unnecessary.
> > But most of core and the math environment work.
> 
> [edited necessary to unnecessary as I believe you meant]

Oops, I mean unnecessary, of course.

> What kind of thigs are missing?  Why are they unnecessary?

There are nearly thousands of commands. In the real world, you only use
a subset of them.

> > > If it does (and you are 
> > > willing to let us have the necessary configs) then the problem is 
> > > already solved!
> > 
> > Which problem? If I get it right you want that Forrest renders MathML
> > for you, or do you want to use Forrest with TeX as input?!
> 
> I want to use Forrest to display 'Maths'.  I personally don't care
> whether it uses MathML or Tex, or somehow uses a kind of stylesheet to
> transform one into the other - I just want to be able to put equations
> in my Forrest docs to be able to type up my lecture notes and have them
> available on the web.

If you write more than just one equation, you will make a difference,
for sure ;-) If you have a document with dozens of equations, MathML
makes it unmaintainable.

> The reason I don't care whether it's MathML or TeX is that I haven't
> learnt how to write either yet - I'm going to have to learn one of them
> though!  I'm willing to learn whichever Forrest will support.

XML is a very bad format for editors knowing from experience(We
have thousands of documents with equations in our project). But this is
a different chapter...

> > BTW, you can also use the math enviroment within Wiki, for example:
> > 
> > -----------------------
> > !Math equations
> > 
> > $\frac{2 \cdot x}{x^2} = y$
> > 
> > And the result is ....
> > -----------------------
> > 
> 
> Is this in your own setup or already possible in Forrest?

Not now, but can easily done by adding some additional transformers to
the cwiki. 

cwiki --> xdoc + mathml ---> html + gif images (or mathml)

But first things first. You should first start to get MathML running.
I can help if there problems occur...

Stephan.


Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Paul Smith <go...@yahoo.com>.
> > Does this solution handle *all* TeX markup? 
> 
> Of course not all markup. This is impossible and unnecessary.
> But most of core and the math environment work.

[edited necessary to unnecessary as I believe you meant]

What kind of thigs are missing?  Why are they unnecessary?

> > If it does (and you are 
> > willing to let us have the necessary configs) then the problem is 
> > already solved!
> 
> Which problem? If I get it right you want that Forrest renders MathML
> for you, or do you want to use Forrest with TeX as input?!
> 

I want to use Forrest to display 'Maths'.  I personally don't care
whether it uses MathML or Tex, or somehow uses a kind of stylesheet to
transform one into the other - I just want to be able to put equations
in my Forrest docs to be able to type up my lecture notes and have them
available on the web.

The reason I don't care whether it's MathML or TeX is that I haven't
learnt how to write either yet - I'm going to have to learn one of them
though!  I'm willing to learn whichever Forrest will support.

> BTW, you can also use the math enviroment within Wiki, for example:
> 
> -----------------------
> !Math equations
> 
> $\frac{2 \cdot x}{x^2} = y$
> 
> And the result is ....
> -----------------------
> 

Is this in your own setup or already possible in Forrest?

=====
Paul Smith
Postgraduate Student
Department of Mathematics
School of Engineering, Computer Science,
                            and Mathematics
University of Exeter
(Laver building room C96, Tel X3990)


	
	
		
___________________________________________________________
BT Yahoo! Broadband - Free modem offer, sign up online today and save £80 http://btyahoo.yahoo.co.uk

Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Stephan Michels <st...@apache.org>.
Am Fr, den 06.02.2004 schrieb Ross Gardler um 15:14:
> Paul Smith wrote:
> >  --- Nicola Ken Barozzi <ni...@apache.org> wrote: > Stephan Michels
> > wrote:
> >>
> >>>Yes, TeX is great. This is the reason, why we produce only TeX
> >>files,
> >>>parse them with Chaperon, process them into whatever with Cocoon,
> >>of
> >>>course ;-)
> 
> Does this solution handle *all* TeX markup? 

Of course not all markup. This is impossible and necessary.
But most of core and the math environment work.

> If it does (and you are 
> willing to let us have the necessary configs) then the problem is 
> already solved!

Which problem? If I get it right you want that Forrest renders MathML
for you, or do you want to use Forrest with TeX as input?!

BTW, you can also use the math enviroment within Wiki, for example:

-----------------------
!Math equations

$\frac{2 \cdot x}{x^2} = y$

And the result is ....
-----------------------

Stephan.


Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Ross Gardler <rg...@apache.org>.
Paul Smith wrote:
>  --- Nicola Ken Barozzi <ni...@apache.org> wrote: > Stephan Michels
> wrote:
> 
>>...
>>
>>>Yes, TeX is great. This is the reason, why we produce only TeX
>>
>>files,
>>
>>>parse them with Chaperon, process them into whatever with Cocoon,
>>
>>of
>>
>>>course ;-)

Does this solution handle *all* TeX markup? If it does (and you are 
willing to let us have the necessary configs) then the problem is 
already solved!

Ross


Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Paul Smith <go...@yahoo.com>.
 --- Nicola Ken Barozzi <ni...@apache.org> wrote: > Stephan Michels
wrote:
> ...
> > Yes, TeX is great. This is the reason, why we produce only TeX
> files,
> > parse them with Chaperon, process them into whatever with Cocoon,
> of
> > course ;-)
> 
> See, it's not so hard. ;-))
> 

It does seem to be standard - all the people curently writing up their
theses are using it here.  I did find some programs that convert from
TeX or LaTeX to MathML though, so if Forrest can handle one or the
other I think we'll be set.

I'll have to check out this Chaperon and find out exactly what that
does...

> -- 
> Nicola Ken Barozzi                   nicolaken@apache.org
>              - verba volant, scripta manent -
>     (discussions get forgotten, just code remains)
> ---------------------------------------------------------------------
>  

=====
Paul Smith
Postgraduate Student
Department of Mathematics
School of Engineering, Computer Science,
                            and Mathematics
University of Exeter
(Laver building room C96, Tel X3990)


	
	
		
___________________________________________________________
BT Yahoo! Broadband - Free modem offer, sign up online today and save £80 http://btyahoo.yahoo.co.uk

Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Nicola Ken Barozzi <ni...@apache.org>.
Stephan Michels wrote:
...
> Yes, TeX is great. This is the reason, why we produce only TeX files,
> parse them with Chaperon, process them into whatever with Cocoon, of
> course ;-)

See, it's not so hard. ;-))

-- 
Nicola Ken Barozzi                   nicolaken@apache.org
             - verba volant, scripta manent -
    (discussions get forgotten, just code remains)
---------------------------------------------------------------------


Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Stephan Michels <st...@apache.org>.
Am Do, den 05.02.2004 schrieb Nicola Ken Barozzi um 22:58:
> J.Pietschmann wrote:
> ...
> > It's C code, tightly integrated into the Gecko rendering engine.
> > I'd be surprised if anybody managed to make it accessible, short
> > of providing a JNI to Gecko as a HTML+MathML rendering widget.
> > Not that this would be useless, quite the contrary.
> > 
> > The MozMathML people plundered TeX for algorithms on how to render
> > equations. I think I've heard of a project providing a Java
> > interface to TeX (or even a Java port), which could render to GIF
> > among other things.
> 
> TeX is *the* king of math rendering, no doubt about that. It's funny how 
> I was reading yesterday the homepage of the LaTeX author... In any case 
> it should be not too hard to also output TeX, which is the standard for 
> printing math books, at least it is at the Universities I visited.

Yes, TeX is great. This is the reason, why we produce only TeX files,
parse them with Chaperon, process them into whatever with Cocoon, of
course ;-)

I got a little screenshot from a workmate to show how mathml can look
like.
http://vern.chem.tu-berlin.de/~stephan/mathml.png

Stephan.


Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Nicola Ken Barozzi <ni...@apache.org>.
J.Pietschmann wrote:
...
> It's C code, tightly integrated into the Gecko rendering engine.
> I'd be surprised if anybody managed to make it accessible, short
> of providing a JNI to Gecko as a HTML+MathML rendering widget.
> Not that this would be useless, quite the contrary.
> 
> The MozMathML people plundered TeX for algorithms on how to render
> equations. I think I've heard of a project providing a Java
> interface to TeX (or even a Java port), which could render to GIF
> among other things.

TeX is *the* king of math rendering, no doubt about that. It's funny how 
I was reading yesterday the homepage of the LaTeX author... In any case 
it should be not too hard to also output TeX, which is the standard for 
printing math books, at least it is at the Universities I visited.

http://www.ctan.org/tex-archive/help/Catalogue/catalogue.html
http://www.tug.org/tex-archive/systems/java/javatex/README.javaTeX
http://www.maths.tcd.ie/~tim/TeX/javaTeX/
http://www-sfb288.math.tu-berlin.de/jdvi/home.html

It seems that most are Gnu-licensed...

Anyway, IMHO extending JEuclid seems to be the best bet here, and 
eventually also make a stylesheet to output of Forrest pages to LaTeX.

-- 
Nicola Ken Barozzi                   nicolaken@apache.org
             - verba volant, scripta manent -
    (discussions get forgotten, just code remains)
---------------------------------------------------------------------


Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by "J.Pietschmann" <j3...@yahoo.de>.
Dave Brondsema wrote:
> The Mozilla MathML project at http://www.mozilla.org/projects/mathml/
> seems pretty complete.  The demo pages work pretty good in Firebird.  I
> don't know how their code is structured, etc, etc.  It may be difficult to
> take their functionality out and put it into an optional jar,

It's C code, tightly integrated into the Gecko rendering engine.
I'd be surprised if anybody managed to make it accessible, short
of providing a JNI to Gecko as a HTML+MathML rendering widget.
Not that this would be useless, quite the contrary.

The MozMathML people plundered TeX for algorithms on how to render
equations. I think I've heard of a project providing a Java
interface to TeX (or even a Java port), which could render to GIF
among other things.

J.Pietschmann


Re: How do I proceed (WAS Re: Forrest and Mathematics)

Posted by Dave Brondsema <da...@brondsema.net>.
On Thu, 5 Feb 2004, Ross Gardler wrote:

> Reinhard Poetz wrote:
> > From: Paul Smith [mailto:googoodolls_uk@yahoo.com]
>  >
> > As I have never done anything similar I can't really help you with this
> > but there was a similar discussion on user@cocoon.apache.org. See
> > http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=107593758419194&w=2
> > for details.
>
>  From this link I got to http://jeuclid.sourceforge.net/
>
> Where it says:
>
> "The project is a component for the Apache Cocoon
> project(xml.apache.org). This component converts MathML documents to GIF
> images or SVG. So the user can easy write documents with embedding
> MathML fragments, and the component create in situ the GIF images. The
> SVG converter is used to create documents with embedding SVG fragments
> for e.g. the FOP to create PDF, or what else, documents."
>
> This is under the APL but the project appears to be pretty dormant.
> There are screenshots of it working, but it may require some work to
> bring it up to date (originally maintainer has asked for someone to take
> over - see news section)
>
> Ross
>

The Mozilla MathML project at http://www.mozilla.org/projects/mathml/
seems pretty complete.  The demo pages work pretty good in Firebird.  I
don't know how their code is structured, etc, etc.  It may be difficult to
take their functionality out and put it into an optional jar, but it might
be even more difficult to make jeuclid complete (depending of course on
how far it is already)

-- 
Dave Brondsema
dave@brondsema.net
http://www.brondsema.net - personal
http://www.splike.com - programming
http://csx.calvin.edu - Calvin club