home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!ogicse!das-news.harvard.edu!spdcc!iecc!compilers-sender
- From: fabre@gr.osf.org (Christian Fabre)
- Newsgroups: comp.compilers
- Subject: Modulo n arithmetics
- Keywords: arithmetic, question, comment
- Message-ID: <92-11-029@comp.compilers>
- Date: 6 Nov 92 15:27:01 GMT
- Article-I.D.: comp.92-11-029
- Sender: compilers-sender@iecc.cambridge.ma.us
- Reply-To: Christian Fabre <fabre@gr.osf.org>
- Organization: Compilers Central
- Lines: 32
- Approved: compilers@iecc.cambridge.ma.us
-
- Hello,
-
- I have a question regarding integers arithmetics.
-
- I am wondering if any languages or application heavily rely on
- modulo arithmetics:
-
- Given the range [0,50], the basic operation are
- redefined as follow:
-
- a op b => ( a op b ) % 51
-
- e.g.:
- 27+30 = 57 % 51 = 7
- 12*12 = 144 % 51 = 44
-
- All I can think about is error corection and encryption. Any other purpose ?
-
-
- Any input welcome, please reply by news.
-
- Christian.
- -----
- Christian Fabre, OSF-RI, 2 avenue de Vignate, 38610 Gieres, France.
- fabre@gr.osf.org -- Tel: +33 76.63.48.90
- fabre@ri.osf.fr -- Fax: +33 76.51.05.32
- [There's always the Chinese Remainder Theorem. I gather that people have
- used it do to large integer problems not requiring a lot of division or
- comparison. -John]
- --
- Send compilers articles to compilers@iecc.cambridge.ma.us or
- {ima | spdcc | world}!iecc!compilers. Meta-mail to compilers-request.
-