W3C home > Mailing lists > Public > www-math@w3.org > March 2006

Re: Formal query about WG role and MathML-FAQ

From: <juanrgonzaleza@canonicalscience.com>
Date: Thu, 16 Mar 2006 10:38:05 -0800 (PST)
Message-ID: <3173.217.124.88.177.1142534285.squirrel@webmail.canonicalscience.com>
To: <www-math@w3.org>


Bruce Miller said:
>
> juanrgonzaleza@canonicalscience.com wrote:
> >
> > I think I have detected some confusion in a topic I consider of maximum
> > importance. For that reason, I would remark the two obvious (related but
> > independent) points of the CanonMath research are being mixed by others:
> >
> > 1) the need for going beyond usual available tools (TeX, MathML,
> > ASCIIMath, etc.) simply because they fail to provide solutions to some
> > real life problems.
>
> "the need" => _your_ need;
> Many people are happy with the above.
> Others are content to extend TeX, ASCIIMath, whatever to solve thier
> real life problems. And yet others construct other tools to solve thiers.
>

I think that both logic and scope of above statements are not correct.

The "=>" appears to be incorrect.

That MathML is not designed to be authored by hand is well-known.
Therefore, one can use either full applications -which are limited- or an
input syntax. The own Math WG recognizes the need for input syntaxes on
the official w3c MathML FAQ.

Ok, then what input syntax?

TeX one? That works in some cases, but does not work for others. Then just
a mathematician (Peter) developed ASCIIMath, which works in some cases but
does not work in others. Both TeX and ASCIIMath are incomplete and therein
the need for the use of both for specific niches. A double approach cannot
be thought to be a final solution even ignoring other scientific fields
where both do not work: TeX/LaTeX is little used in chemistry, for
example.

The need for a new syntax for mathematics is also discussed by Robert
Mayans, in a recent work that I already cited here.

Therefore, the investigation I am doing only can provide benefits (even if
I fail, that can be taken for learn useful lessons from my errors) for all
mathematical/scientific/educative community.

Final language will be initially used by the canonical science community
but, as I already said, language and tools will be openly available to
anyone.

Therefore I would encourage that "the need" => the need;

> As has been said here repeatedly, if the available methods don't solve
your needs,
> nobody is "forcing" you to use them.  You are more than welcome to
> develop your own solution.
>

This has never been the question.

The former (and important) question was: there is a problem, how can we
solve? Here some of my ideas; what you think?

A related question was: The MathML FAQ "promises" assistance from the WG
to develop input syntaxes for MathML; I am doing one, why did my mails and
posts receive zero replies?

> > 2) the final implementation of the notation/syntax chosen. For example,
> >
> > <CanonMath>a <fraction/> b</CanonMath>
> > <CanonMath>a  &fraction; b</CanonMath>
> > <CanonMath>a \fraction b</CanonMath>
> > <CanonMath>a \fraction b</CanonMath>
> > <CanonMath>a <fract/> b</CanonMath>
> > <CanonMath>a <f/> b</CanonMath>
> > ...
>
> You don't need pages and pages of straw-men to convince this forum that,
> at _some_ level of abstraction, these are all equivalent; pretty obvious.
> (BTW: Using HTML as an example of semantic markup doesn't buy too much
> credibility here)
>
> However, you seem to be ignoring _practical_ issues;
> the above expressions _are_ different from DOM and XPath points of view.

I am obtaining lot of problems for understanding several of your positions
and replies. I have submitted here some examples of XSLT templates for
some tree transformations I have in my mind. For example, I have studied
transformations of kind

<mathematics>a \fraction b</mathematics>

to

<math display="block" xmlns="http://www.w3.org/1998/Math/MathML">
	<mi>a</mi>
	<fraction/>
	<mi>b</mi>
</math>

for example, via the next XSLT template

<xsl:template name="ReplaceTeXt">
	<xsl:param name="string"/>
	<xsl:param name="command"/>
	<xsl:param name="TagName"/>
	<xsl:choose>
		<xsl:when test="contains($string,$command)">
			<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
			<mi><xsl:value-of select="substring-before($string,$command)"/></mi>
			<fraction/>
			<mi><xsl:value-of select="substring-after($string,$command)"/></mi>
			</math>
		</xsl:when>
		<xsl:otherwise>
			<xsl:value-of select="$string"/>
		</xsl:otherwise>
	</xsl:choose>
</xsl:template>

<xsl:template match="mathematics">
	<xsl:call-template name="ReplaceTeXt">
		<xsl:with-param name="string" select="text()"/>
		<xsl:with-param name="command" select="'\fraction'"/>
		<xsl:with-param name="TagName" select="'fraction'"/>
	</xsl:call-template>
</xsl:template>

How could I write those templates using XPath for matching without knowing
the XML-tree of document I am transforming? How can you suggest that I am
ignoring trees are different? This just perplexes me!

> I also haven't seen you address grouping and precedence issues, for
example.
> I would helpfully and respectfully suggest that you actually
> _implement_ a parser to make these issues more clear.
> It should be a parser complete enough to parse non-trivial math
> expressions --- using whatever markup you choose ---
> rather than just a fragment that substitutes <sup/> for ^.
>

Again, I feel unable to decipher this.

First)

The Canonical Science Today entry
[http://canonicalscience.blogspot.com/2006/02/choosing-notationsyntax-for-canonmath.html]

and my postings here were about

"Choosing a notation/syntax for CanonMath"

not about what is the best language/script/etc for this transformation.

Second)

a) I already explained here my philosophy about the role of computational
technologies.

b) It is a waste of time to write a parser without fixing first the
markup. The parser for a totally textual markup is deferent from one for a
markup based in XML tags. Begin to write a kind of parser just for just
after change it if the markup changes appears to be not a very intelligent
attitude.

Third)

Some like

<myMarkup>
<mi>a</mi><fraction/><mi>b</mi>
</ myMarkup>

can be transformed to

<math display="block" xmlns="http://www.w3.org/1998/Math/MathML">
<mfract><mi>a</mi><mi>b</mi></mfract>
</math>

via silibing axes in XPath. The logic is as follow

match fraction, then write a mfract tag with first child the 1st silibing
before and second child the 1st silibing after (because orientation of
axes is inverted in XPath). Anyway, details are highly dependant of
language and version used. For example is not the same work with XSLT 2.0
that with XSLT 1.0.

A big difficulty I see now about the use of XSLT is the grouping via { and
} since a simple substitution of characters cannot work due to
XML-completeness of the XSLT. But probably it would be solved via a double
substitution template.

> With that suggestion, I've exhausted my constructiveness and interest
> --- and indeed patience.  Please do not consider the lack of further
> responses as "ignoring you".
>

Thanks by your patient with someone so foolish as I can be sometimes and
excuse me if sometimes I was unable to understand your replies.

Let me repeat again that the point was neither lack of reply nor “ignoring
you”. The question -very different you are delineating- was that the
official MathML FAQ

[http://www.w3.org/Math/mathml-faq.html]

states that WG will provide technical advice to anyone developing input
sintaxes for MathML. I am one of those, and let me repeat again that both
my successive mails and my first posting here was not ***formally***
replied.

As I already said before, a reply such as "Sorry we have no time for your
program" (or no time...) (or no interest...) is very different from no
reply at all, specially when one does an ***official*** request for
assistance after reading the official MathML FAQ:

"The WG will provide technical advice to all those who are involved in the
development of input syntaxes for MathML-aware tools."

I was not asking MathML people as individuals, I was asking them as
members of the official WG, which refer above FAQ entry. Anyone would be
aware of the difference...

> --
> bruce.miller@nist.gov
> http://math.nist.gov/~BMiller/


Juan R.

Center for CANONICAL |SCIENCE)
Received on Thursday, 16 March 2006 18:38:29 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 20 February 2010 06:12:58 GMT