easy_factor.H File Reference

contains declaration of the simpler factoring algorithms More...

#include <gmp.h>
#include <string>
#include "utils.H"
#include "mpz_wrapper.H"

Include dependency graph for easy_factor.H:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void pollard (const int runden)
 Pollard-rho method.
bool try_memorized_factors (mpz_t n, const std::string &memfilename)
 trial division by some factors given in a file...
bool Potenztest (const mpz_t n)
 check for perfect powers
void fermat_like_method ()
 factoring method similar to fermat
void phimat (mpz_t n)
 factoring methods something between fermat and phi
void phimat2 ()
void easy_factor ()
 trial division and a combination of other methods

Variables

bool SkipFermat
bool UsePhimat
bool SkipPhi
bool SkipFibonacci
bool SkipEasyECM
bool SkipECM
int rho_Phase
int phi_Phase1
double phi_Phase2
double elcu_Phase1
double elcu_Phase2
int elcu_Kurven


Detailed Description

contains declaration of the simpler factoring algorithms

Definition in file easy_factor.H.


Function Documentation

void easy_factor (  ) 

trial division and a combination of other methods

Definition at line 184 of file easy_factor.cc.

References cerr, compiled_IS_STANDALONE(), cout, endl(), exit(), exp(), fermat_like_method(), fibonacci_ppm1, std::basic_ofstream< _CharT, _Traits >::flush(), elliptic_curves::go(), MAL(), MARK, mpz_cmp_ui(), mpz_divexact_ui(), mpz_divisible_ui_p(), mpz_probab_prime_p(), mpz_set_ui(), mpz_sizeinbase(), n, phi_Phase1, phi_Phase2, phimat2(), pollard(), pollard_phi, Potenztest(), my_mpz_wrapper::probab_prime_checks, rho_Phase, SkipEasyECM, SkipFermat, SkipFibonacci, SkipPhi, ExitManager::StopFactorization(), try_memorized_factors(), tune_parameters(), and UsePhimat.

Referenced by main().

Here is the call graph for this function:

void fermat_like_method (  ) 

factoring method similar to fermat

Definition at line 7 of file fermat.cc.

References cout, endl(), Factorization_to_file, fermat_like_method(), flush(), MAL(), mpz_add(), mpz_add_ui(), mpz_clear(), mpz_cmp_ui(), mpz_divexact(), mpz_gcd(), mpz_init(), mpz_mul(), mpz_mul_ui(), mpz_perfect_square_p(), mpz_pow_ui(), mpz_probab_prime_p(), my_mpz_wrapper::mpz_remainder_ui(), mpz_set_ui(), mpz_sizeinbase(), mpz_sqrt(), mpz_sub(), mpz_swap(), n, Potenztest(), and my_mpz_wrapper::probab_prime_checks.

Referenced by easy_factor(), and fermat_like_method().

Here is the call graph for this function:

void phimat ( mpz_t  n  ) 

factoring methods something between fermat and phi

Definition at line 711 of file fermat.cc.

References cout, endl(), Factorization_to_file, flush(), MAL(), mpz_add(), mpz_add_ui(), mpz_clear(), mpz_cmp(), mpz_cmp_ui(), mpz_init(), mpz_mul(), mpz_mul_ui(), mpz_powm(), mpz_probab_prime_p(), mpz_scan1(), mpz_set_ui(), mpz_sqrt(), mpz_sub(), mpz_tdiv_q_2exp(), and my_mpz_wrapper::probab_prime_checks.

Here is the call graph for this function:

void phimat2 (  ) 

Definition at line 536 of file fermat.cc.

References allowed_memory_usage_KB(), entry::Base, cerr, cout, lambda_delta::Delta_by_ratio(), endl(), exit(), Factorization_to_file, flush(), phimahashvecs::found(), phimahashvecs::Intervalsize(), MAL(), phimahashvecs::max_size(), MIN(), mpz_add(), mpz_add_ui(), mpz_clear(), mpz_cmp(), mpz_cmp_ui(), mpz_divexact(), mpz_gcd(), mpz_init(), mpz_init_set(), mpz_init_set_ui(), mpz_invert(), mpz_mod(), mpz_mul(), mpz_mul_ui(), mpz_powm(), mpz_powm_ui(), mpz_probab_prime_p(), my_mpz_wrapper::mpz_remainder_ui(), mpz_set(), mpz_set_ui(), mpz_sqrt(), mpz_sub(), mpz_sub_ui(), n, Potenztest(), phimahashvecs::prepare(), and my_mpz_wrapper::probab_prime_checks.

Referenced by easy_factor().

Here is the call graph for this function:

void pollard ( const int  runden  ) 

Pollard-rho method.

Definition at line 38 of file easy_factor.cc.

References cout, endl(), exp(), flush(), Cusr_signal_proxy::got_SIGUSR1(), Cusr_signal_proxy::got_SIGUSR2(), MAL(), mpz_add_ui(), mpz_clear(), mpz_cmp(), mpz_cmp_ui(), mpz_gcd(), mpz_init(), mpz_mod(), mpz_mul(), mpz_probab_prime_p(), mpz_remove(), mpz_set(), mpz_set_ui(), mpz_sub(), n, and my_mpz_wrapper::probab_prime_checks.

Referenced by easy_factor().

Here is the call graph for this function:

bool Potenztest ( const mpz_t  n  ) 

check for perfect powers

Definition at line 153 of file easy_factor.cc.

References cout, endl(), flush(), MAL(), mpz_clear(), mpz_init(), mpz_probab_prime_p(), mpz_root(), mpz_sizeinbase(), and my_mpz_wrapper::probab_prime_checks.

Referenced by CRelation::ComputeQuadraticCongruence(), easy_factor(), fermat_like_method(), phimat2(), Cprocess_clients::process_data_stream(), Cprocess_clients::process_data_stream_ecm(), and process_ecm().

Here is the call graph for this function:

bool try_memorized_factors ( mpz_t  n,
const std::string memfilename 
)

trial division by some factors given in a file...

Definition at line 88 of file easy_factor.cc.

References std::basic_string< _CharT, _Traits, _Alloc >::c_str(), cerr, cout, endl(), flush(), isspace(), MAL(), mpz_clear(), mpz_cmp(), mpz_divexact(), mpz_divisible_p(), mpz_init(), mpz_probab_prime_p(), and my_mpz_wrapper::probab_prime_checks.

Referenced by easy_factor().

Here is the call graph for this function:


Variable Documentation

int elcu_Kurven

Definition at line 27 of file ConfigFile.cc.

Referenced by Cprocess_clients::process_data_stream_ecm(), process_ecm(), tune_parameters(), and statistical_data::XML_StatusReport().

double elcu_Phase1

Definition at line 25 of file ConfigFile.cc.

Referenced by main(), Cprocess_clients::process_data_stream_ecm(), process_ecm(), tune_parameters(), and statistical_data::XML_StatusReport().

double elcu_Phase2

Definition at line 26 of file ConfigFile.cc.

Referenced by main(), Cprocess_clients::process_data_stream_ecm(), process_ecm(), tune_parameters(), and statistical_data::XML_StatusReport().

int phi_Phase1

Definition at line 23 of file ConfigFile.cc.

Referenced by easy_factor(), and tune_parameters().

double phi_Phase2

Definition at line 24 of file ConfigFile.cc.

Referenced by easy_factor(), and tune_parameters().

int rho_Phase

Definition at line 22 of file ConfigFile.cc.

Referenced by easy_factor(), and tune_parameters().

bool SkipEasyECM

Definition at line 19 of file ConfigFile.cc.

Referenced by easy_factor(), and Read_ConfigFile().

bool SkipECM

Definition at line 20 of file ConfigFile.cc.

Referenced by main(), and Read_ConfigFile().

bool SkipFermat

Definition at line 15 of file ConfigFile.cc.

Referenced by easy_factor(), and Read_ConfigFile().

bool SkipFibonacci

Definition at line 18 of file ConfigFile.cc.

Referenced by easy_factor(), and Read_ConfigFile().

bool SkipPhi

Definition at line 17 of file ConfigFile.cc.

Referenced by easy_factor(), and Read_ConfigFile().

bool UsePhimat

Definition at line 16 of file ConfigFile.cc.

Referenced by easy_factor(), and Read_ConfigFile().


Generated on Wed Nov 7 23:29:47 2007 for Qsieve by  doxygen 1.5.4