* \unit problem with powers of ten.
@ 2012-11-19 22:44 Romain Diss
2012-11-20 13:43 ` Romain Diss
2012-11-22 18:09 ` Hans Hagen
0 siblings, 2 replies; 12+ messages in thread
From: Romain Diss @ 2012-11-19 22:44 UTC (permalink / raw)
To: ConTeXt Mailing List
Hi all,
I got some problems to express powers of ten in the \unit command. See the
strange behaviour with these two minimal examples.
\starttext
\unit{10^2 meter}\\
\unit{10^{-12} second}
\stoptext
However, there is no problem with this one: \unit{1e-4 kilogram}.
Is this a bug or are these expressions not supported?
Thanks.
--
Romain Diss
<romain.diss@yahoo.fr>
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-19 22:44 \unit problem with powers of ten Romain Diss
@ 2012-11-20 13:43 ` Romain Diss
2012-11-22 14:45 ` Romain Diss
2012-11-22 18:09 ` Hans Hagen
1 sibling, 1 reply; 12+ messages in thread
From: Romain Diss @ 2012-11-20 13:43 UTC (permalink / raw)
To: mailing list for ConTeXt users
Le lundi 19 novembre 2012, Romain Diss a écrit :
> I got some problems to express powers of ten in the \unit command. See the
> strange behaviour with these two minimal examples.
>
> \starttext
> \unit{10^2 meter}\\
> \unit{10^{-12} second}
> \stoptext
> Is this a bug or are these expressions not supported?
I'm not an expert neither in TeX nor Lua, but I quickly glance at the source
code (phys-dim.*) and here is what I understand:
— the brackets { } are not recognized (a comment in the lua code mentioned
it), so \unit{10^{-12} second} should be \unit{10^-12 second};
— the hat sign '^' is recognized as 'e' so it means "… times ten to the
power…" instead of "to the power…" as one should expect.
So I come back to my problem. I want to write 10⁻¹² s (ten to the negative
twelfth power second). Actually, I'm typing \math{10^{-12} \unit{second}} but
I'd prefer to type \unit{10^-12 second} (for coherence). Is it possible to
modify phys-dim.lua in that way or is this to much work (I have no idea if
this is a matter of changing one line or a hundred lines in phys-dim.lua.
Maybe also this is a too specific request, I don't know…
Anyway, thank you in advance.
All the best.
--
Romain Diss
<romain.diss@yahoo.fr>
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-20 13:43 ` Romain Diss
@ 2012-11-22 14:45 ` Romain Diss
2012-11-22 14:51 ` luigi scarso
0 siblings, 1 reply; 12+ messages in thread
From: Romain Diss @ 2012-11-22 14:45 UTC (permalink / raw)
To: mailing list for ConTeXt users
Hi all,
Le mardi 20 novembre 2012, Romain Diss a écrit :
> Le lundi 19 novembre 2012, Romain Diss a écrit :
> > I got some problems to express powers of ten in the \unit command. See
> > the strange behaviour with these two minimal examples.
> >
> > \starttext
> > \unit{10^2 meter}\\
> > \unit{10^{-12} second}
> > \stoptext
> > Is this a bug or are these expressions not supported?
>
> I'm not an expert neither in TeX nor Lua, but I quickly glance at the
> source code (phys-dim.*) and here is what I understand:
> — the brackets { } are not recognized (a comment in the lua code mentioned
> it), so \unit{10^{-12} second} should be \unit{10^-12 second};
> — the hat sign '^' is recognized as 'e' so it means "… times ten to the
> power…" instead of "to the power…" as one should expect.
>
> So I come back to my problem. I want to write 10⁻¹² s (ten to the negative
> twelfth power second). Actually, I'm typing \math{10^{-12} \unit{second}}
> but I'd prefer to type \unit{10^-12 second} (for coherence). Is it
> possible to modify phys-dim.lua in that way or is this to much work (I
> have no idea if this is a matter of changing one line or a hundred lines
> in phys-dim.lua. Maybe also this is a too specific request, I don't know…
Nobody seems very enthusiastic concerning this thread so I tried to go further
in the comprehension of the phys-dim.lua code. I now have found an approximate
solution to my problem :
\unit{$10^{-12}$ second}
give the right result. It is not very satisfactory because I'm now used to use
\m{} instead of $ $. In the phys-dim.lua code, the line 64 shows that \m{} can
be used inside \unit{} but this doesn't work for:
\unit{\m{10^{-12}} second}
because the pattern doesn't handle nested curly braces.
Is there any Lua expert to find a pattern to handle exponents?
Thank you.
--
Romain Diss
<romain.diss@yahoo.fr>
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-22 14:45 ` Romain Diss
@ 2012-11-22 14:51 ` luigi scarso
0 siblings, 0 replies; 12+ messages in thread
From: luigi scarso @ 2012-11-22 14:51 UTC (permalink / raw)
To: mailing list for ConTeXt users
[-- Attachment #1.1: Type: text/plain, Size: 2725 bytes --]
At least me have seen your post and tried some solutions, but nothing
useful....
On Thu, Nov 22, 2012 at 3:45 PM, Romain Diss <romain.diss@yahoo.fr> wrote:
> Hi all,
>
> Le mardi 20 novembre 2012, Romain Diss a écrit :
> > Le lundi 19 novembre 2012, Romain Diss a écrit :
> > > I got some problems to express powers of ten in the \unit command. See
> > > the strange behaviour with these two minimal examples.
> > >
> > > \starttext
> > > \unit{10^2 meter}\\
> > > \unit{10^{-12} second}
> > > \stoptext
> > > Is this a bug or are these expressions not supported?
> >
> > I'm not an expert neither in TeX nor Lua, but I quickly glance at the
> > source code (phys-dim.*) and here is what I understand:
> > — the brackets { } are not recognized (a comment in the lua code
> mentioned
> > it), so \unit{10^{-12} second} should be \unit{10^-12 second};
> > — the hat sign '^' is recognized as 'e' so it means "… times ten to the
> > power…" instead of "to the power…" as one should expect.
> >
> > So I come back to my problem. I want to write 10⁻¹² s (ten to the
> negative
> > twelfth power second). Actually, I'm typing \math{10^{-12} \unit{second}}
> > but I'd prefer to type \unit{10^-12 second} (for coherence). Is it
> > possible to modify phys-dim.lua in that way or is this to much work (I
> > have no idea if this is a matter of changing one line or a hundred lines
> > in phys-dim.lua. Maybe also this is a too specific request, I don't know…
>
> Nobody seems very enthusiastic concerning this thread so I tried to go
> further
> in the comprehension of the phys-dim.lua code. I now have found an
> approximate
> solution to my problem :
> \unit{$10^{-12}$ second}
> give the right result. It is not very satisfactory because I'm now used to
> use
> \m{} instead of $ $. In the phys-dim.lua code, the line 64 shows that \m{}
> can
> be used inside \unit{} but this doesn't work for:
> \unit{\m{10^{-12}} second}
> because the pattern doesn't handle nested curly braces.
>
> Is there any Lua expert to find a pattern to handle exponents?
>
> Thank you.
>
> --
> Romain Diss
> <romain.diss@yahoo.fr>
>
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive : http://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
>
> ___________________________________________________________________________________
>
--
luigi
[-- Attachment #1.2: Type: text/html, Size: 3732 bytes --]
[-- Attachment #2: Type: text/plain, Size: 485 bytes --]
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-19 22:44 \unit problem with powers of ten Romain Diss
2012-11-20 13:43 ` Romain Diss
@ 2012-11-22 18:09 ` Hans Hagen
2012-11-23 13:44 ` Sietse Brouwer
2012-11-23 19:25 ` Romain Diss
1 sibling, 2 replies; 12+ messages in thread
From: Hans Hagen @ 2012-11-22 18:09 UTC (permalink / raw)
To: mailing list for ConTeXt users
On 11/19/2012 11:44 PM, Romain Diss wrote:
> Hi all,
>
> I got some problems to express powers of ten in the \unit command. See the
> strange behaviour with these two minimal examples.
>
> \starttext
> \unit{10^2 meter}\\
> \unit{10^{-12} second}
> \stoptext
>
> However, there is no problem with this one: \unit{1e-4 kilogram}.
>
> Is this a bug or are these expressions not supported?
not supported .. i've added it to the upcoming beta:
\starttext
\startlines
\unit{10^12 meter}
\unit{10^{-12} second}
\unit{10^{12} second}
\unit{10e12 meter}
\unit{10e{-12} second}
\unit{10e{12} second}
\stoplines
\stoptext
needs testing as usual (and wiki adaption as well)
Hans
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-22 18:09 ` Hans Hagen
@ 2012-11-23 13:44 ` Sietse Brouwer
2012-11-23 19:25 ` Romain Diss
1 sibling, 0 replies; 12+ messages in thread
From: Sietse Brouwer @ 2012-11-23 13:44 UTC (permalink / raw)
To: mailing list for ConTeXt users
> needs testing as usual (and wiki adaption as well)
http://wiki.contextgarden.net/Command/unit
Wiki: adapted. (Page created, actually, as there was none.) Using the
fancy-schmancy {{since|2012|text=nov 2012}} template, which (1) marks
this as a recent feature, and as such not in the stable yet, and
(2) sticks it in the hidden categories [Since] and [Since 2012], so
that we may review (and remove) those tags when the new stable comes
out next year.
--Sietse
On Thu, Nov 22, 2012 at 7:09 PM, Hans Hagen <pragma@wxs.nl> wrote:
> On 11/19/2012 11:44 PM, Romain Diss wrote:
>>
>> Hi all,
>>
>> I got some problems to express powers of ten in the \unit command. See the
>> strange behaviour with these two minimal examples.
>>
>> \starttext
>> \unit{10^2 meter}\\
>> \unit{10^{-12} second}
>> \stoptext
>>
>> However, there is no problem with this one: \unit{1e-4 kilogram}.
>>
>> Is this a bug or are these expressions not supported?
>
>
> not supported .. i've added it to the upcoming beta:
>
> \starttext
>
> \startlines
> \unit{10^12 meter}
> \unit{10^{-12} second}
> \unit{10^{12} second}
> \unit{10e12 meter}
> \unit{10e{-12} second}
> \unit{10e{12} second}
> \stoplines
>
> \stoptext
>
> needs testing as usual (and wiki adaption as well)
>
> Hans
>
>
> -----------------------------------------------------------------
> Hans Hagen | PRAGMA ADE
> Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
> | www.pragma-pod.nl
> -----------------------------------------------------------------
>
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive : http://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___________________________________________________________________________________
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-22 18:09 ` Hans Hagen
2012-11-23 13:44 ` Sietse Brouwer
@ 2012-11-23 19:25 ` Romain Diss
2012-11-23 22:51 ` Hans Hagen
1 sibling, 1 reply; 12+ messages in thread
From: Romain Diss @ 2012-11-23 19:25 UTC (permalink / raw)
To: Hans Hagen; +Cc: mailing list for ConTeXt users
Hi,
Le jeudi 22 novembre 2012, Hans Hagen a écrit :
> On 11/19/2012 11:44 PM, Romain Diss wrote:
> > Hi all,
> >
> > I got some problems to express powers of ten in the \unit command. See
> > the strange behaviour with these two minimal examples.
> >
> > \starttext
> > \unit{10^2 meter}\\
> > \unit{10^{-12} second}
> > \stoptext
> > Is this a bug or are these expressions not supported?
>
> not supported .. i've added it to the upcoming beta:
Thank you very much.
> needs testing as usual (and wiki adaption as well)
I have upgraded my context version few minutes ago:
$ context --version
mtx-context | ConTeXt Process Management 0.60
mtx-context | current version: 2012.11.23 17:35
but your following code doesn't work completely:
> \starttext
>
> \startlines
> \unit{10^12 meter}
> \unit{10^{-12} second}
> \unit{10^{12} second}
> \unit{10e12 meter}
> \unit{10e{-12} second}
> \unit{10e{12} second}
> \stoplines
>
> \stoptext
The '^' and 'e' all print a '10 ×' at the begining. It's what is expected for
'e' but not for '^'. Did I miss something?
--
Romain Diss
<romain.diss@yahoo.fr>
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-23 19:25 ` Romain Diss
@ 2012-11-23 22:51 ` Hans Hagen
2012-11-24 0:48 ` Sietse Brouwer
0 siblings, 1 reply; 12+ messages in thread
From: Hans Hagen @ 2012-11-23 22:51 UTC (permalink / raw)
To: Romain Diss; +Cc: mailing list for ConTeXt users
On 11/23/2012 8:25 PM, Romain Diss wrote:
> Hi,
>
> Le jeudi 22 novembre 2012, Hans Hagen a écrit :
>> On 11/19/2012 11:44 PM, Romain Diss wrote:
>>> Hi all,
>>>
>>> I got some problems to express powers of ten in the \unit command. See
>>> the strange behaviour with these two minimal examples.
>>>
>>> \starttext
>>> \unit{10^2 meter}\\
>>> \unit{10^{-12} second}
>>> \stoptext
>>> Is this a bug or are these expressions not supported?
>>
>> not supported .. i've added it to the upcoming beta:
> Thank you very much.
>
>> needs testing as usual (and wiki adaption as well)
> I have upgraded my context version few minutes ago:
> $ context --version
> mtx-context | ConTeXt Process Management 0.60
> mtx-context | current version: 2012.11.23 17:35
>
> but your following code doesn't work completely:
>
>> \starttext
>>
>> \startlines
>> \unit{10^12 meter}
>> \unit{10^{-12} second}
>> \unit{10^{12} second}
>> \unit{10e12 meter}
>> \unit{10e{-12} second}
>> \unit{10e{12} second}
>> \stoplines
>>
>> \stoptext
>
> The '^' and 'e' all print a '10 ×' at the begining. It's what is expected for
> 'e' but not for '^'. Did I miss something?
well, until now ^ and e were equivalent so if that has to change (say ^
no 10) then there need to be agreement about this as it's an
incompatible change
i only added support for {..}
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-23 22:51 ` Hans Hagen
@ 2012-11-24 0:48 ` Sietse Brouwer
2012-11-24 7:39 ` Romain Diss
2012-11-24 9:59 ` Hans Hagen
0 siblings, 2 replies; 12+ messages in thread
From: Sietse Brouwer @ 2012-11-24 0:48 UTC (permalink / raw)
To: mailing list for ConTeXt users
>> The '^' and 'e' all print a '10 ×' at the begining. It's what is expected
>> for
>> 'e' but not for '^'. Did I miss something?
>
>
> well, until now ^ and e were equivalent so if that has to change (say ^ no
> 10) then there need to be agreement about this as it's an incompatible
> change
I, for one, would expect 2^3 to mean '2 cubed', not 2x10^3. So I'd be
in favour of this change. Then again, I have no code that depends on
the old meaning...
--Sietse
P.s. Isn't MkIV known to be unstable? I thought the official advice
was "If you want stability, use (a) MkII, or (b) a stable version of
MkIV, or (c) a dedicated standalone install that you do not update.
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-24 0:48 ` Sietse Brouwer
@ 2012-11-24 7:39 ` Romain Diss
2012-11-24 9:59 ` Hans Hagen
1 sibling, 0 replies; 12+ messages in thread
From: Romain Diss @ 2012-11-24 7:39 UTC (permalink / raw)
To: mailing list for ConTeXt users
Le samedi 24 novembre 2012, Sietse Brouwer a écrit :
> > > The '^' and 'e' all print a '10 ×' at the begining. It's what is
> > > expected for
> > > 'e' but not for '^'.
> >
> > well, until now ^ and e were equivalent so if that has to change (say ^
> > no 10) then there need to be agreement about this as it's an
> > incompatible change
>
> I, for one, would expect 2^3 to mean '2 cubed', not 2x10^3. So I'd be
> in favour of this change. Then again, I have no code that depends on
> the old meaning...
Of course, I'm also in favour of 2^3 to mean '2 cubed'.
--
Romain Diss
<romain.diss@yahoo.fr>
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-24 0:48 ` Sietse Brouwer
2012-11-24 7:39 ` Romain Diss
@ 2012-11-24 9:59 ` Hans Hagen
2012-11-24 10:15 ` Romain Diss
1 sibling, 1 reply; 12+ messages in thread
From: Hans Hagen @ 2012-11-24 9:59 UTC (permalink / raw)
To: mailing list for ConTeXt users
On 11/24/2012 1:48 AM, Sietse Brouwer wrote:
>>> The '^' and 'e' all print a '10 ×' at the begining. It's what is expected
>>> for
>>> 'e' but not for '^'. Did I miss something?
>>
>>
>> well, until now ^ and e were equivalent so if that has to change (say ^ no
>> 10) then there need to be agreement about this as it's an incompatible
>> change
>
> I, for one, would expect 2^3 to mean '2 cubed', not 2x10^3. So I'd be
> in favour of this change. Then again, I have no code that depends on
> the old meaning...
interesting so then we need a list of more ^2 ^3 ^4 ^5 ... and what
about ^1.2
then, what will be the escape for the texlike 2^3? maybe $2^3$, so $
will leave scanning mode
the 2^3 is probably not used that much
> --Sietse
>
> P.s. Isn't MkIV known to be unstable? I thought the official advice
> was "If you want stability, use (a) MkII, or (b) a stable version of
> MkIV, or (c) a dedicated standalone install that you do not update.
so you want instability to be a leading design principle ... i'll think
about it
Hans
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: \unit problem with powers of ten.
2012-11-24 9:59 ` Hans Hagen
@ 2012-11-24 10:15 ` Romain Diss
0 siblings, 0 replies; 12+ messages in thread
From: Romain Diss @ 2012-11-24 10:15 UTC (permalink / raw)
To: ntg-context
Le samedi 24 novembre 2012, Hans Hagen a écrit :
> On 11/24/2012 1:48 AM, Sietse Brouwer wrote:
> >>> The '^' and 'e' all print a '10 ×' at the begining. It's what is
> >>> expected for
> >>> 'e' but not for '^'. Did I miss something?
> >>
> >> well, until now ^ and e were equivalent so if that has to change (say ^
> >> no 10) then there need to be agreement about this as it's an
> >> incompatible change
> >
> > I, for one, would expect 2^3 to mean '2 cubed', not 2x10^3. So I'd be
> > in favour of this change. Then again, I have no code that depends on
> > the old meaning...
>
> interesting so then we need a list of more ^2 ^3 ^4 ^5 ... and what
> about ^1.2
I don't know everyone's use of \units but for physicists I think that the only
case where it should be usefull is for 10^something (like \unit{10^-12 second}
;). Maybe the informaticians need 2^something… The other cases are probably
marginals.
> then, what will be the escape for the texlike 2^3? maybe $2^3$, so $
> will leave scanning mode
That's already working and this should be the way when one need something
unusual. Maybe a support for \m{} should be usefull for those who do not use
$...$ anymore. For the moment nested curly brackets aren't supported inside a
\m{} which himself is inside a \unit{}.
All the best.
--
Romain Diss
<romain.diss@yahoo.fr>
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2012-11-24 10:15 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-11-19 22:44 \unit problem with powers of ten Romain Diss
2012-11-20 13:43 ` Romain Diss
2012-11-22 14:45 ` Romain Diss
2012-11-22 14:51 ` luigi scarso
2012-11-22 18:09 ` Hans Hagen
2012-11-23 13:44 ` Sietse Brouwer
2012-11-23 19:25 ` Romain Diss
2012-11-23 22:51 ` Hans Hagen
2012-11-24 0:48 ` Sietse Brouwer
2012-11-24 7:39 ` Romain Diss
2012-11-24 9:59 ` Hans Hagen
2012-11-24 10:15 ` Romain Diss
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).