LATEX-L Archives

Mailing list for the LaTeX3 project


Options: Use Forum View

Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Bruno Le Floch <[log in to unmask]>
Reply To:
Mailing list for the LaTeX3 project <[log in to unmask]>
Tue, 15 Jul 2014 10:00:07 -0400
text/plain (43 lines)
On 7/12/14, aparsloe <[log in to unmask]> wrote:
> On 12/07/2014 3:13 p.m., Bruno Le Floch wrote:
>> Can you expand on that one exception?  I don't see what it is.
> I found myself on occasion wanting to substitute a number in expressions
> where  pi is followed by other terms. For instance the fine structure
> constant is 2pi e^2/hc (where e is the electronic charge in this case)
> but direct substitution of values for e etc. simply provokes an
> "Undefined control sequence" message. Since numbers are not (as far as I
> understand) elements of control sequences, this felt like an unnecessary
> limitation. (But I'm not familiar with the underlying constraints. Hence
> the "perhaps".)

Not sure what you mean here.  Doing \fp_show:n { 2pi e^2/hc } gives two errors:

    \LaTeX3 error: Unknown fp word pie.
    \LaTeX3 error: Unknown fp word hc.


    \fp_const:Nn \c_aparsloe_e_fp { 1.60217657e-19 }
    \fp_const:Nn \c_aparsloe_h_fp { 6.62606957e-34 }
    \fp_const:Nn \c_aparsloe_c_fp { 299 792 458 }
    \fp_show:n { 2pi \c_aparsloe_e_fp ^2 / ( \c_aparsloe_h_fp
\c_aparsloe_c_fp ) }

works (except that since I've used values in SI units for e, h, c, the
formula for the fine structure constant is missing a factor of

> As I've tried to indicate, I've come to realise that what matters is
> clarity in what the rules are and the rigour of their application. My
> concern was with people who might, at present, use a (clunky?) package
> like calc, or fp, coming across l3fp, being seduced (like me) and coming
> a cropper (as I did). The proposed change will certainly reduce that
> possibility.

I'm not sure what change you propose (besides the precedence of
juxtaposition, which will change soonish), and it will be helpful if
you clarify.