Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Ronan Le Hy <ronan.lehy@gmail.com>
To: caml-list@yquem.inria.fr
Subject: Re: [Caml-list] Errors in Bignum arithmetic?
Date: Tue, 10 Aug 2010 14:52:19 +0200	[thread overview]
Message-ID: <AANLkTikcZQs8_yu1uMCMoFrj8HpxFK7DzyHqQRfONcAY@mail.gmail.com> (raw)
In-Reply-To: <20100810123410.GC16292@vaio.jimpryor.net>

Hello,

2010/8/10 Jim Pryor <lists+caml@jimpryor.net>:
> Fermat's Little Theorem says that when p is prime, then for all 1<=a<p,
> a**(p-1) mod p = 1. [...]
>
> The Carmichael numbers are a series of composites that have the property
> for all choices of a. http://mathworld.wolfram.com/CarmichaelNumber.html

This page says "for every choice of a [...] where a and p are
relatively prime". I believe that explains that your examples below do
not work :

> 3**(561-1) mod 561 = 1
> 5**(1105-1) mod 1105 = 1
> 5**(2465-1) mod 2465 = 1
> 5**(10585-1) mod 10585 = 1

-- 
Ronan


  parent reply	other threads:[~2010-08-10 12:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-10 12:34 Jim Pryor
2010-08-10 12:41 ` [Caml-list] " Thomas Fischbacher
2010-08-10 12:46 ` David House
2010-08-10 13:42   ` Jim Pryor
2010-08-10 12:52 ` Ronan Le Hy [this message]
2010-08-10 13:21 ` Christophe TROESTLER

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=AANLkTikcZQs8_yu1uMCMoFrj8HpxFK7DzyHqQRfONcAY@mail.gmail.com \
    --to=ronan.lehy@gmail.com \
    --cc=caml-list@yquem.inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox