Loading [MathJax]/extensions/tex2jax.js
Parallel numerical verification of the σ_odd problem  October 6, 2018
All Classes Namespaces Files Functions Variables Typedefs Macros
Namespaces | Functions | Variables
primes.cpp File Reference
#include "primes.hpp"
#include "../helper/helper.hpp"
Include dependency graph for primes.cpp:

Go to the source code of this file.

Namespaces

 sigmaodd
 A lot of functions and stuffs to deal the sigma_odd problem and related stuffs.
 

Functions

std::vector< FactorExp > sigmaodd::factorize (nat_type n)
 Return a list of prime factors with their exponents. More...
 
nat_type sigmaodd::factorization_to_n (std::vector< FactorExp > prime_exps)
 Return the number corresponding to the factorization. More...
 
nat_type sigmaodd::factorization_to_nu (std::vector< FactorExp > prime_exps)
 Return the number of all divisors of the number corresponding to the factorization. More...
 
nat_type sigmaodd::factorization_to_nu_odd (std::vector< FactorExp > prime_exps)
 Return the number of odd divisors of the number corresponding to the factorization. More...
 
nat_type sigmaodd::factorization_to_sigma (std::vector< FactorExp > prime_exps)
 Return the sum of all divisors of the number corresponding to the factorization. More...
 
nat_type sigmaodd::factorization_to_sigma_odd (std::vector< FactorExp > prime_exps)
 Return the sum of odd divisors of the number corresponding to the factorization. More...
 
bool sigmaodd::is_prime (nat_type n)
 Return true iff n is a prime number. More...
 
bool sigmaodd::is_prime_in_odd_primes_table (nat_type n)
 Return true iff n is a prime number present in the precalculated table. More...
 
bool sigmaodd::read_primes_table ()
 Read the binary file prime_filename to fill the table with all primes < 2^28. This table must be read from the binary file big_data/prime28.bin. More...
 

Variables

const std::string sigmaodd::prime_filename = "big_data/prime28.bin"
 Default filename for the binary file "big_data/prime28.bin". More...
 
prime_typesigmaodd::array_odd_primes_ = nullptr
 Array of all odd prime numbers < 2^28 with a final 0. (Or < 2^16 if the macro PRIME16 is defined.) More...
 

Detailed Description

(January 5, 2018)

GPLv3 — Copyright (C) 2017, 2018 Olivier Pirson http://www.opimedia.be/

Definition in file primes.cpp.