1#![allow(non_camel_case_types)]
2
3use crate::deps::*;
6use crate::fmpq::fmpq;
7use crate::fmpq_poly::fmpq_poly_struct;
8use crate::fmpz::fmpz;
9use crate::fmpz_mat::fmpz_mat_struct;
10use crate::fmpz_poly::fmpz_poly_struct;
11use libc::{c_int, c_uint};
12
13#[repr(C)]
14#[derive(Copy, Clone)]
15pub struct trig_prod_struct {
16 pub n: c_int,
17 pub prefactor: c_int,
18 pub sqrt_p: mp_limb_t,
19 pub sqrt_q: mp_limb_t,
20 pub cos_p: [mp_limb_signed_t; 64usize],
21 pub cos_q: [mp_limb_t; 64usize],
22}
23pub type trig_prod_t = [trig_prod_struct; 1usize];
24
25extern "C" {
26 pub static mut bell_number_tab: [mp_limb_t; 0usize];
27 pub static euler_number_small: [mp_limb_t; 13usize];
28 pub static _bernoulli_numer_small: [mp_limb_signed_t; 18usize];
29 pub static partitions_lookup: [c_uint; 128usize];
30
31 pub fn mpfr_zeta_inv_euler_product(res: *mut __mpfr_struct, s: mp_limb_t, char_4: c_int);
32 pub fn _arith_harmonic_number(num: *mut fmpz, den: *mut fmpz, n: mp_limb_signed_t);
33 pub fn arith_harmonic_number(x: *mut fmpq, n: mp_limb_signed_t);
34 pub fn arith_ramanujan_tau(res: *mut fmpz, n: *mut fmpz);
35 pub fn arith_ramanujan_tau_series(res: *mut fmpz_poly_struct, n: mp_limb_signed_t);
36 pub fn arith_divisors(res: *mut fmpz_poly_struct, n: *mut fmpz);
37 pub fn arith_stirling_number_1u(s: *mut fmpz, n: mp_limb_signed_t, k: mp_limb_signed_t);
38 pub fn arith_stirling_number_1(s: *mut fmpz, n: mp_limb_signed_t, k: mp_limb_signed_t);
39 pub fn arith_stirling_number_2(s: *mut fmpz, n: mp_limb_signed_t, k: mp_limb_signed_t);
40 pub fn arith_stirling_number_1u_vec(
41 row: *mut fmpz,
42 n: mp_limb_signed_t,
43 klen: mp_limb_signed_t,
44 );
45 pub fn arith_stirling_number_1_vec(row: *mut fmpz, n: mp_limb_signed_t, klen: mp_limb_signed_t);
46 pub fn arith_stirling_number_2_vec(row: *mut fmpz, n: mp_limb_signed_t, klen: mp_limb_signed_t);
47 pub fn arith_stirling_number_1u_vec_next(
48 row: *mut fmpz,
49 prev: *const fmpz,
50 n: mp_limb_signed_t,
51 klen: mp_limb_signed_t,
52 );
53 pub fn arith_stirling_number_1_vec_next(
54 row: *mut fmpz,
55 prev: *const fmpz,
56 n: mp_limb_signed_t,
57 klen: mp_limb_signed_t,
58 );
59 pub fn arith_stirling_number_2_vec_next(
60 row: *mut fmpz,
61 prev: *const fmpz,
62 n: mp_limb_signed_t,
63 klen: mp_limb_signed_t,
64 );
65 pub fn arith_stirling_matrix_1u(mat: *mut fmpz_mat_struct);
66 pub fn arith_stirling_matrix_1(mat: *mut fmpz_mat_struct);
67 pub fn arith_stirling_matrix_2(mat: *mut fmpz_mat_struct);
68 pub fn arith_bell_number_size(n: mp_limb_t) -> f64;
69 pub fn arith_bell_number(b: *mut fmpz, n: mp_limb_t);
70 pub fn arith_bell_number_bsplit(res: *mut fmpz, n: mp_limb_t);
71 pub fn arith_bell_number_multi_mod(res: *mut fmpz, n: mp_limb_t);
72 pub fn arith_bell_number_vec(b: *mut fmpz, n: mp_limb_signed_t);
73 pub fn arith_bell_number_vec_recursive(b: *mut fmpz, n: mp_limb_signed_t);
74 pub fn arith_bell_number_vec_multi_mod(b: *mut fmpz, n: mp_limb_signed_t);
75 pub fn arith_euler_number_size(n: mp_limb_t) -> f64;
82 pub fn arith_euler_number_vec(res: *mut fmpz, n: mp_limb_signed_t);
83 pub fn _arith_euler_number_zeta(res: *mut fmpz, n: mp_limb_t);
84 pub fn arith_euler_number(res: *mut fmpz, n: mp_limb_t);
85 pub fn arith_euler_polynomial(poly: *mut fmpq_poly_struct, n: mp_limb_t);
86 pub fn _arith_bernoulli_number(num: *mut fmpz, den: *mut fmpz, n: mp_limb_t);
87 pub fn arith_bernoulli_number(x: *mut fmpq, n: mp_limb_t);
88 pub fn _arith_bernoulli_number_vec(num: *mut fmpz, den: *mut fmpz, n: mp_limb_signed_t);
89 pub fn arith_bernoulli_number_vec(num: *mut fmpq, n: mp_limb_signed_t);
90 pub fn arith_bernoulli_number_denom(den: *mut fmpz, n: mp_limb_t);
91 pub fn arith_bernoulli_number_size(n: mp_limb_t) -> f64;
92 pub fn arith_bernoulli_polynomial(poly: *mut fmpq_poly_struct, n: mp_limb_t);
93 pub fn _arith_bernoulli_number_zeta(num: *mut fmpz, den: *mut fmpz, n: mp_limb_t);
94 pub fn _arith_bernoulli_number_vec_multi_mod(
95 num: *mut fmpz,
96 den: *mut fmpz,
97 n: mp_limb_signed_t,
98 );
99 pub fn _arith_bernoulli_number_vec_recursive(
100 num: *mut fmpz,
101 den: *mut fmpz,
102 n: mp_limb_signed_t,
103 );
104 pub fn _arith_bernoulli_number_vec_zeta(num: *mut fmpz, den: *mut fmpz, n: mp_limb_signed_t);
105 pub fn _arith_cos_minpoly(coeffs: *mut fmpz, d: mp_limb_signed_t, n: mp_limb_t);
106 pub fn arith_cos_minpoly(poly: *mut fmpz_poly_struct, n: mp_limb_t);
107 pub fn arith_landau_function_vec(res: *mut fmpz, len: mp_limb_signed_t);
108 pub fn trig_prod_init(sum: *mut trig_prod_struct);
109 pub fn arith_hrr_expsum_factored(prod: *mut trig_prod_struct, k: mp_limb_t, n: mp_limb_t);
110 pub fn arith_number_of_partitions_vec(res: *mut fmpz, len: mp_limb_signed_t);
112 pub fn arith_number_of_partitions_mpfr(x: *mut __mpfr_struct, n: mp_limb_t);
113 pub fn arith_number_of_partitions(x: *mut fmpz, n: mp_limb_t);
114 pub fn arith_sum_of_squares(r: *mut fmpz, k: mp_limb_t, n: *mut fmpz);
115 pub fn arith_sum_of_squares_vec(r: *mut fmpz, k: mp_limb_t, n: mp_limb_signed_t);
116}