
Go to the source code of this file.
Functions | |
| OCTAVE_EXPORT octave_value_list | F__isprimelarge__ (const octave_value_list &args, int) |
| bool | isprimescalar (uint64_t n) |
| bool | millerrabin (uint64_t div, uint64_t d, uint64_t r, uint64_t n) |
| OCTAVE_NAMESPACE_BEGIN uint64_t | safemultiply (uint64_t a, uint64_t b, uint64_t modulus) |
| uint64_t | safepower (uint64_t a, uint64_t b, uint64_t modulus) |
| OCTAVE_EXPORT octave_value_list F__isprimelarge__ | ( | const octave_value_list & | args, |
| int | |||
| ) |
Definition at line 163 of file __isprimelarge__.cc.
References Array< T, Alloc >::dims(), isprimescalar(), Array< T, Alloc >::numel(), ovl(), and print_usage().
| bool isprimescalar | ( | uint64_t | n | ) |
Definition at line 99 of file __isprimelarge__.cc.
References d, and millerrabin().
Referenced by F__isprimelarge__().
| bool millerrabin | ( | uint64_t | div, |
| uint64_t | d, | ||
| uint64_t | r, | ||
| uint64_t | n | ||
| ) |
Definition at line 81 of file __isprimelarge__.cc.
References d, safemultiply(), safepower(), and x.
Referenced by isprimescalar().
| OCTAVE_NAMESPACE_BEGIN uint64_t safemultiply | ( | uint64_t | a, |
| uint64_t | b, | ||
| uint64_t | modulus | ||
| ) |
Definition at line 40 of file __isprimelarge__.cc.
References safemultiply().
Referenced by millerrabin(), safemultiply(), and safepower().
| uint64_t safepower | ( | uint64_t | a, |
| uint64_t | b, | ||
| uint64_t | modulus | ||
| ) |
Definition at line 65 of file __isprimelarge__.cc.
References safemultiply().
Referenced by millerrabin().