W3C home > Mailing lists > Public > public-i18n-bidi@w3.org > July to September 2010

Re: [html-bidi] Any bidi requirements for MathML (or MathMl in HTML)?

From: Aharon (Vladimir) Lanin <aharon@google.com>
Date: Wed, 18 Aug 2010 10:08:06 +0300
Message-ID: <AANLkTi=bxj1Vh0X4r8VDcesaHnX++zVpwmc0GCjn=odj@mail.gmail.com>
To: ntounsi@emi.ac.ma
Cc: CE Whitehead <cewcathar@hotmail.com>, ehsan@mozilla.com, addison@lab126.com, bert@w3.org, public-i18n-bidi@w3.org
> Some mathematicians still need to write formulas with Arabic letters, e.g.
for publications.

What happens when a formula, intended to be displayed left-to-right happens
to have two RTL variable names around an operator? For example, in HTML,

<div dir=ltr>(A - B) * 3 = C</div>

(where capitals are RTL text, once again), the display will be garbled to:

(C = 3 * (B - A

So, in HTML, ubi (the new name for bdi) would indeed be useful if RTL
variable names are used in formulas:

<div dir=ltr>(<span ubi>A</span> - <span ubi>B</span>) * 3 = <span
ubi>C</span></div>

will be displayed correctly as:

(A - B) * 3 = C

Of course, when a formula has all-RTL variable names, the reader may not be
sure if it is supposed to be read RTL (unless it has inherent directional
hints like roots or exponents). For this reason I would imagine that Hebrew
authors will stick with Latin and Greek letters for the variables.

Aharon


On Wed, Aug 18, 2010 at 5:40 AM, Najib Tounsi <ntounsi@gmail.com> wrote:

> In Morocco, mathematic formulas, at least in school books, and written with
> Latin letters and thus are LTR, although mathematics are teached  in Arabic.
> Some mathematicians still need to write formulas with Arabic letters, e.g.
> for publications.
>
> I think Arabic "requirements" in MathML were mentioned in a W3C note:
> Arabic mathematical notation, W3C Interest Group Note 31 January 2006 (
> http://www.w3.org/Math/Group/Notes/draft-notes/arabic.xhtml)
>
> This Note has allowed clarification of the relationship with bidirectional
> text.
>
> The Note is also mentionned in MathML 3.0 specification, where the section
>  "3.1.5 Directionality " is devoted to RTL issues in general. (
> http://www.w3.org/TR/2010/PR-MathML3-20100810/chapter3.html#presm.bidi)
>
> This said, Bert Boss may be right:  a BDI attribute should not be  needed.
>
> Regards, Najib
>
>
>
>
> CE Whitehead wrote:
>
>> Hi, Ehsan, Aharon, all:
>>
>>
>>> From: ehsan@mozilla.com
>>> Date: Tue, 17 Aug 2010 18:06:09 -0400
>>> To: aharon@google.com
>>> CC: addison@lab126.com; bert@w3.org; public-i18n-bidi@w3.org
>>> Subject: Re: [html-bidi] Any bidi requirements for MathML (or MathMl in
>>> HTML)?
>>>
>>> The situation is exactly the same for Persian: math formulas are
>>> written from left-to-right. I suspect that the same is true for
>>> Arabic as well, but I'll defer the final confirmation to a native
>>> speaker.
>>>
>>> --
>>> Ehsan
>>>
>>>
>>
>> Arabic digits were discussed in a thread at internationalization:
>> http://lists.w3.org/Archives/Public/www-international/2009AprJun/0081.html
>>  Apparenty phone numbers are written left to right and numbers have their
>> most significant digit on the left; not sure that they are always typed left
>> to right however.
>>  I should wait to see if Najib has anything to add to this since this was
>> a 2009 thread.
>>  Best,
>>  C. E. Whitehead
>> cewcathar@hotmail.clom
>>
>>
>>
>>>
>>>
>>> On Tue, Aug 17, 2010 at 4:28 PM, Aharon (Vladimir) Lanin
>>> wrote:
>>>
>>>
>>>> Traditionally, formulas in Hebrew mathematical publications are always
>>>> written left-to-right. The Israel Standards Institute is in the midst of
>>>> considering the question of whether to break with his tradition.
>>>> Although a
>>>> final decision has not yet been made, it looks like the answer will
>>>> basically be no: math will continue to be written left-to-right.
>>>>
>>>> For Arabic, on the other hand, the answer may be quite different, but I
>>>> know
>>>> little about it.
>>>>
>>>> Aharon
>>>>
>>>> On Tue, Aug 17, 2010 at 5:52 PM, Phillips, Addison
>>>> wrote:
>>>>
>>>>
>>>>> Hi Bert,
>>>>>
>>>>> Thanks for the note. I have added this to our WG agenda for this week.
>>>>>
>>>>> Addison
>>>>>
>>>>> Addison Phillips
>>>>> Globalization Architect (Lab126)
>>>>> Chair (W3C I18N, IETF IRI WGs)
>>>>>
>>>>> Internationalization is not a feature.
>>>>> It is an architecture.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>> -----Original Message-----
>>>>>> From: public-i18n-bidi-request@w3.org [mailto:public-i18n-bidi-
>>>>>> request@w3.org] On Behalf Of Bert Bos
>>>>>> Sent: Tuesday, August 17, 2010 6:33 AM
>>>>>> To: public-i18n-bidi@w3.org
>>>>>> Subject: [html-bidi] Any bidi requirements for MathML (or MathMl in
>>>>>> HTML)?
>>>>>>
>>>>>> This is a somewhat vague question, and also rather late, given that
>>>>>> MathML3 is as good as finished (it's a Proposed Recommendation),
>>>>>> but I
>>>>>> just wondered if anybody has thought about math...
>>>>>>
>>>>>> The html-bidi[1] draft talks about requirements on HTML and CSS. It
>>>>>> doesn't mention MathML, although the current MathML also has bidi
>>>>>> support. And in the current plans for HTML5, MathML will be an
>>>>>> integral
>>>>>> part of the HTML language.
>>>>>>
>>>>>> Are there no additional requirements on MathML?
>>>>>>
>>>>>>
>>>>>> The problem of bidi isolation at least doesn't seem to occur in
>>>>>> MathML:
>>>>>>
>>>>>> Section 3.1.5[2] of MathML3 describes the bidi features of MathML.
>>>>>> It is
>>>>>> possible to set the overall direction of a formula as well as the
>>>>>> base
>>>>>> direction of individual tokens.
>>>>>>
>>>>>> Changing the overall direction acts almost like a mirror, e.g., "a
>>>>>> + b"
>>>>>> is written as "b + a" and superscripts (a²) are written on the left
>>>>>> of
>>>>>> their base (²a).
>>>>>>
>>>>>> Tokens are symbols (+, =), numbers (12, 0.5), letters (x, y), words
>>>>>> (sin, cos), or phrases ("such that," "theorem 1"). Setting a
>>>>>> direction
>>>>>> on tokens should rarely be needed, the inherited direction and the
>>>>>> Unicode bidi algorithm are usually enough.
>>>>>>
>>>>>> Unlike in HTML, each token is "directionally isolated" (in the
>>>>>> terms of
>>>>>> html-bidi WD), so a BDI attribute is not needed.
>>>>>>
>>>>>>
>>>>>> [1] http://www.w3.org/TR/2010/WD-html-bidi-20100304/
>>>>>> [2] http://www.w3.org/TR/MathML3/chapter3.html#presm.bidi
>>>>>>
>>>>>>
>>>>>>
>>>>>> Bert
>>>>>> --
>>>>>> Bert Bos ( W 3 C )
>>>>>> http://www.w3.org/
>>>>>> http://www.w3.org/people/bos
>>>>>> W3C/ERCIM
>>>>>> bert@w3.org 2004 Rt des Lucioles / BP
>>>>>> 93
>>>>>> +33 (0)4 92 38 76 92 06902 Sophia Antipolis Cedex,
>>>>>> France
>>>>>>
>>>>>>
>>>>>
> --
> Najib TOUNSI (tounsi at w3.org)
> W3C Office in Morocco (http://www.w3c.org.ma/)
> Ecole Mohammadia d'Ingénieurs, BP. 765 Agdal-RABAT Morocco
> Phone : +212 (0) 537 68 71 50  Fax : +212 (0) 537 77 88 53
> Mobile: +212 (0) 661 22 00 30
>
>
>
Received on Wednesday, 18 August 2010 07:08:59 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 18 August 2010 07:09:00 GMT