Re: i18n and check printing and Europe (fwd), Re: i18n and check printing and Europe (fwd)

2000-03-28 Thread Christopher Browne

> > 
> > > Even in English we have, in many dialects, "five hundreds of
> > > dollars" (as opposed to "five hundred dollars") not to mention
> > > "threescore dollars and twelve". I believe my grandfather wrote
> > > "Seventy-Five Pounds and 26/100", but "Seventy-Five Pounds Only";
> > > yet "One Hundred Pounds Exactly".
> > 
> > Bear in mind here that we don't need to be able to parse all of the
> > possible valid constructions in a given language, we just need to be
> > able to output *one* valid construction for each language, which is a
> > much simpler problem.
> 
> Yes, parsing is harder than determinstic generation.
> But:
> 
> Some constructions are allowable in English (but not mandatory).
> Such constructions are within the gamut of the language center
> of the human brain.  Virtually any natural-language syntactic
> construction that can be processed by the human brain turns out
> to be mandatory in some language, somewhere.  Indeed, given the thousands
> of languages of astonishing variability that exist, it would be
> astonishing if this were not so.
> 
> So chances are that some language or culture, somewhere, will require
> a construction like this.  If our formalism for describing number
> notations can handle it, people will be able to do their own
> linguistic customization.  (and contribute the results to our
> internationalization library, natch).
> 
> Whether we want to do all this now, instead of just letting everyone
> program their own number code in Scheme, is another matter, or course.
> But Stephen's ad-hoc notation may indicate regularities that could simplify
> our code in the long run.

Remember:

What is *mandatory* is to have text which will be recognized as acceptable to 
the bank clearing-houses of the world.

It would be *nice* to have grammatical correctness, but if some irregularities 
of grammar persist, but which are things that the bank clearing-houses won't 
care about, that is not a _severe_ problem.
--
"Any sufficiently complicated C or Fortran program contains an ad hoc
informally-specified bug-ridden slow implementation of half of Common
Lisp."  -- Philip Greenspun
[EMAIL PROTECTED] - 



--
Gnucash Developer's List 
To unsubscribe send empty email to: [EMAIL PROTECTED]





Re: i18n and check printing and Europe (fwd)

2000-03-25 Thread Ben Stanley

I sent this to my wife, who is a fluent French speaker, to verify. She
says:

I would put commas in after every trillion, billiard, billion, milliard,
million, mille...
Remember also that the decimal point in French is in fact a comma,
"virgule", and the comma separators used in
English for large numbers are decimal points.

Hope this helps.

Otherwise, they seem to have it right.


Ben Stanley.



--
Gnucash Developer's List 
To unsubscribe send empty email to: [EMAIL PROTECTED]





Re: i18n and check printing and Europe (fwd), Re: i18n and check printing and Europe (fwd)

2000-03-24 Thread Rob Browning


> Even in English we have, in many dialects, "five hundreds of
> dollars" (as opposed to "five hundred dollars") not to mention
> "threescore dollars and twelve". I believe my grandfather wrote
> "Seventy-Five Pounds and 26/100", but "Seventy-Five Pounds Only";
> yet "One Hundred Pounds Exactly".

Bear in mind here that we don't need to be able to parse all of the
possible valid constructions in a given language, we just need to be
able to output *one* valid construction for each language, which is a
much simpler problem.

-- 
Rob Browning <[EMAIL PROTECTED]> PGP=E80E0D04F521A094 532B97F5D64E3930

--
Gnucash Developer's List 
To unsubscribe send empty email to: [EMAIL PROTECTED]





Re: i18n and check printing and Europe (fwd), Re: i18n and check printingand Europe (fwd)

2000-03-23 Thread Hendrik Boom

> 
> > Even in English we have, in many dialects, "five hundreds of
> > dollars" (as opposed to "five hundred dollars") not to mention
> > "threescore dollars and twelve". I believe my grandfather wrote
> > "Seventy-Five Pounds and 26/100", but "Seventy-Five Pounds Only";
> > yet "One Hundred Pounds Exactly".
> 
> Bear in mind here that we don't need to be able to parse all of the
> possible valid constructions in a given language, we just need to be
> able to output *one* valid construction for each language, which is a
> much simpler problem.

Yes, parsing is harder than determinstic generation.
But:

Some constructions are allowable in English (but not mandatory).
Such constructions are within the gamut of the language center
of the human brain.  Virtually any natural-language syntactic
construction that can be processed by the human brain turns out
to be mandatory in some language, somewhere.  Indeed, given the thousands
of languages of astonishing variability that exist, it would be
astonishing if this were not so.

So chances are that some language or culture, somewhere, will require
a construction like this.  If our formalism for describing number
notations can handle it, people will be able to do their own
linguistic customization.  (and contribute the results to our
internationalization library, natch).

Whether we want to do all this now, instead of just letting everyone
program their own number code in Scheme, is another matter, or course.
But Stephen's ad-hoc notation may indicate regularities that could simplify
our code in the long run.

> 
> -- 
> Rob Browning <[EMAIL PROTECTED]> PGP=E80E0D04F521A094 532B97F5D64E3930
> 

-- hendrik.

--
Gnucash Developer's List 
To unsubscribe send empty email to: [EMAIL PROTECTED]





Re: i18n and check printing and Europe (fwd)

2000-03-23 Thread Hendrik Boom

I passed the number formatting problem on to a friend of mine
who happens to be a linguist as well as a computer hacker.
(there I go again, using a word in an older, this time respectable,  meaning)
He replied as follows:

-- hendrik

- Forwarded message from stephen p spackman -

>From [EMAIL PROTECTED]  Wed Mar 22 15:35:40 2000
Message-ID: <[EMAIL PROTECTED]>
Date: Wed, 22 Mar 2000 15:48:42 -0500
From: stephen p spackman <[EMAIL PROTECTED]>
Organization: pooq.com
X-Mailer: Mozilla 4.7 [en] (Win98; U)
X-Accept-Language: en-GB,en,fr,de
To: Hendrik Boom <[EMAIL PROTECTED]>
Subject: Re: i18n and check printing and Europe (fwd)
References: <[EMAIL PROTECTED]>

[Hendrik: forward to the group if you deem appropriate]

Even in English we have, in many dialects, "five hundreds of dollars" (as opposed to 
"five
hundred dollars") not to mention "threescore dollars and twelve". I believe my 
grandfather
wrote "Seventy-Five Pounds and 26/100", but "Seventy-Five Pounds Only"; yet "One 
Hundred Pounds
Exactly".

French (in France and Quebec) expresses 71 as 60+11 and 91 as 4*20+11, of course. Other
variants of French have words for 70 and 90.

And it is of not to be forgotten that the U.S. "one hundred ten" is "one hundred and 
ten" for
the rest of us.

Evidently european languages differ in whether a  is more or less than a 
.
Britain is currently in flux as to whether a billion is a thousand million (following 
the U.S.
and the "billionaire's" ego) or a million million (following tradition, logic, and the 
rest of
the world). Fortunately the thousand million/million million formulations themselves 
are
unambiguous and acceptable. There also seem to be variants of English that use 
milliard and
billiard; I don't know where these are spoken, though.

It gets worse: some languages - I think Japanese among them, could be wrong - use 
different
number series for counting different things (much as eggs come in dozens and shoes 
come in
pairs, but much, much worse), so if you care about more than just dollar values on 
cheques
there are. You might need to worry about gender agreements as well.

The moral: you need a methodology before you start making tables. The tables need to be
editable, and they need to take the form of ordered rules with number theoretical 
guards on the
left and grammatical productions on the right. Attribute grammars for maths.

In the following, (x ! y) is (x - x % y); ~0 means "nonzero"; $ is the quantity we're 
encoding.
An empty lhs matches anything. We use e3 etc. as an abbreviation for 1000.

Sorry for all the _notation_ being ad hoc; I've already spent too long thinking about 
the
content :-).

--> one variant of english

eng.UK.centAmount:
0:  nothing
~0 % 100: [dollarAmount $ / 100] and [number $ % 100] cents
~0 % e4: [dollarAmount $ / 100] only
:  [dollarAmount $ / 100] exactly

eng.UK.dollarAmount:
0:  no dollars
1:  one dollar
:  [number $] dollars

eng.UK.number:
0:  zero
1:  one
2:  two
3:  three
4:  four
5:  five
6:  six
7:  seven
8:  eight
9:  nine
10:  ten
11:  eleven
12:  twelve
13:  thirteen
15:  fifteen
<20:  [$ % 10]teen
20:  twenty
30:  thirty
40:  forty
50:  fifty
<100 & 0%10: [$/10]ty
<100:  [$ ! 10]-[$ % 10]
~0 % 100: [$ ! 100] and [$ % 100]
 e.g.

[centAmount 1234567890123456789044]
[dollarAmount 12345678901234567890] and [number 44] cents
[number 12345678901234567890] dollars and [number 40]-[number 4] cents
[number 12345678901234567800] and [number 90] dollars and forty-four cents
[number 12345678901234567000] [number 8] hundred and [number 9]ty dollars...
[number 1234567890123400] [number 567] thousand eight hundred and ninety ...
[big(million) 12345678901234] [number 500] and [number 67] thousand eight ...
[big(million million) 12345678] [big(million) 901234] [number 5] hundred and [number
60]-[number 7] thousand ...
[big(million million million) 12] [big(million million) 345678] [number 901234] 
million five
hundred and [number 6]ty-seven thousand ...
[number 12] million million million [number 345678] million million [number 901200] 
and [number
34] million five hundred and sixty-seven thousand ...
twelve million million million [number 345600] and [number 78] million million [number 
901000]
[number 200] and [number 30]-[number 4] million five ...
twelve million million million [number 345000] [number 600] and [number 70]-[number 8] 
million
million [number 901] thousand [number 2] hundred and thirty-four million five ...
twelve million million million [number 345] thousand [number 6] hundred and [number 
7]ty-eight
million million [number 900] and [number 1] thousand two hundred ...
twelve million million million [number 300] and [number 45] thousand six hundred and
seventy-eight million million [number 9] hundred and one thousand ...
twelve million million million [number 3] hundred and [numb