flint-sys 0.9.0

Bindings to the FLINT C library
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
/* automatically generated by rust-bindgen 0.70.1 */

use libc::*;
use crate::deps::*;
use crate::acb_types::*;
use crate::ca_types::*;
use crate::fexpr::*;
use crate::flint::*;
use crate::fmpq_types::*;
use crate::fmpz_types::*;
use crate::gr_types::*;
use crate::mpoly_types::*;
use crate::qqbar::*;


pub const CA_TRIG_DIRECT: u32 = 0;
pub const CA_TRIG_EXPONENTIAL: u32 = 1;
pub const CA_TRIG_SINE_COSINE: u32 = 2;
pub const CA_TRIG_TANGENT: u32 = 3;
pub const CA_FEXPR_SERIALIZATION: u32 = 1;
pub const CA_FACTOR_ZZ_NONE: u32 = 0;
pub const CA_FACTOR_ZZ_SMOOTH: u32 = 2;
pub const CA_FACTOR_ZZ_FULL: u32 = 4;
pub const CA_FACTOR_POLY_NONE: u32 = 0;
pub const CA_FACTOR_POLY_CONTENT: u32 = 64;
pub const CA_FACTOR_POLY_SQF: u32 = 128;
pub const CA_FACTOR_POLY_FULL: u32 = 256;
pub const CA_OPT_VERBOSE: _bindgen_ty_4 = 0;
pub const CA_OPT_PRINT_FLAGS: _bindgen_ty_4 = 1;
pub const CA_OPT_MPOLY_ORD: _bindgen_ty_4 = 2;
pub const CA_OPT_PREC_LIMIT: _bindgen_ty_4 = 3;
pub const CA_OPT_QQBAR_DEG_LIMIT: _bindgen_ty_4 = 4;
pub const CA_OPT_LOW_PREC: _bindgen_ty_4 = 5;
pub const CA_OPT_SMOOTH_LIMIT: _bindgen_ty_4 = 6;
pub const CA_OPT_LLL_PREC: _bindgen_ty_4 = 7;
pub const CA_OPT_POW_LIMIT: _bindgen_ty_4 = 8;
pub const CA_OPT_USE_GROEBNER: _bindgen_ty_4 = 9;
pub const CA_OPT_GROEBNER_LENGTH_LIMIT: _bindgen_ty_4 = 10;
pub const CA_OPT_GROEBNER_POLY_LENGTH_LIMIT: _bindgen_ty_4 = 11;
pub const CA_OPT_GROEBNER_POLY_BITS_LIMIT: _bindgen_ty_4 = 12;
pub const CA_OPT_VIETA_LIMIT: _bindgen_ty_4 = 13;
pub const CA_OPT_TRIG_FORM: _bindgen_ty_4 = 14;
pub const CA_OPT_NUM_OPTIONS: _bindgen_ty_4 = 15;
pub type _bindgen_ty_4 = libc::c_uint;
extern "C" {
    pub fn ca_ctx_init(ctx: *mut ca_ctx_struct);
    pub fn ca_ctx_clear(ctx: *mut ca_ctx_struct);
    pub fn ca_ctx_print(ctx: *mut ca_ctx_struct);
    #[link_name = "ca_ctx_get_option__extern"]
    pub fn ca_ctx_get_option(ctx: *mut ca_ctx_struct, i: slong) -> slong;
    #[link_name = "ca_ctx_set_option__extern"]
    pub fn ca_ctx_set_option(ctx: *mut ca_ctx_struct, i: slong, value: slong);
    pub fn _ca_ctx_get_field_const(
        ctx: *mut ca_ctx_struct,
        func: calcium_func_code,
    ) -> ca_field_ptr;
    pub fn _ca_ctx_get_field_fx(
        ctx: *mut ca_ctx_struct,
        func: calcium_func_code,
        x: *const ca_struct,
    ) -> ca_field_ptr;
    pub fn _ca_ctx_get_field_fxy(
        ctx: *mut ca_ctx_struct,
        func: calcium_func_code,
        x: *const ca_struct,
        y: *const ca_struct,
    ) -> ca_field_ptr;
    pub fn ca_init(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_clear(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_swap(x: *mut ca_struct, y: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn _ca_make_field_element(
        x: *mut ca_struct,
        field: ca_field_srcptr,
        ctx: *mut ca_ctx_struct,
    );
    #[link_name = "_ca_make_fmpq__extern"]
    pub fn _ca_make_fmpq(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    #[link_name = "_ca_function_fx__extern"]
    pub fn _ca_function_fx(
        res: *mut ca_struct,
        func: calcium_func_code,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    #[link_name = "_ca_function_fxy__extern"]
    pub fn _ca_function_fxy(
        res: *mut ca_struct,
        func: calcium_func_code,
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_set(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_transfer(
        res: *mut ca_struct,
        res_ctx: *mut ca_ctx_struct,
        src: *const ca_struct,
        src_ctx: *mut ca_ctx_struct,
    );
    pub fn ca_zero(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_one(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_neg_one(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_set_si(x: *mut ca_struct, v: slong, ctx: *mut ca_ctx_struct);
    pub fn ca_set_ui(x: *mut ca_struct, v: ulong, ctx: *mut ca_ctx_struct);
    pub fn ca_set_fmpz(x: *mut ca_struct, v: *const fmpz, ctx: *mut ca_ctx_struct);
    pub fn ca_set_fmpq(x: *mut ca_struct, v: *const fmpq, ctx: *mut ca_ctx_struct);
    pub fn ca_set_d(res: *mut ca_struct, x: f64, ctx: *mut ca_ctx_struct);
    pub fn ca_set_d_d(res: *mut ca_struct, x: f64, y: f64, ctx: *mut ca_ctx_struct);
    pub fn ca_i(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_neg_i(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_pi(res: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_pi_i(res: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_euler(res: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_unknown(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_undefined(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_uinf(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_pos_inf(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_neg_inf(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_pos_i_inf(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_neg_i_inf(x: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_set_qqbar(res: *mut ca_struct, x: *const qqbar_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_can_evaluate_qqbar(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> libc::c_int;
    pub fn ca_get_qqbar(
        res: *mut qqbar_struct,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    ) -> libc::c_int;
    pub fn ca_get_fmpq(res: *mut fmpq, x: *const ca_struct, ctx: *mut ca_ctx_struct)
        -> libc::c_int;
    pub fn ca_get_fmpz(res: *mut fmpz, x: *const ca_struct, ctx: *mut ca_ctx_struct)
        -> libc::c_int;
    pub fn ca_get_fexpr(
        res: *mut fexpr_struct,
        x: *const ca_struct,
        flags: ulong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_set_fexpr(
        res: *mut ca_struct,
        expr: *const fexpr_struct,
        ctx: *mut ca_ctx_struct,
    ) -> libc::c_int;
    pub fn ca_fprint(fp: *mut FILE, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_print(x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_printn(x: *const ca_struct, n: slong, ctx: *mut ca_ctx_struct);
    pub fn ca_get_str(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> *mut libc::c_char;
    pub fn ca_randtest_same_nf(
        res: *mut ca_struct,
        state: *mut flint_rand_struct,
        x: *const ca_struct,
        bits: slong,
        den_bits: slong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_randtest_rational(
        res: *mut ca_struct,
        state: *mut flint_rand_struct,
        bits: slong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_randtest(
        res: *mut ca_struct,
        state: *mut flint_rand_struct,
        depth: slong,
        bits: slong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_randtest_special(
        res: *mut ca_struct,
        state: *mut flint_rand_struct,
        depth: slong,
        bits: slong,
        ctx: *mut ca_ctx_struct,
    );
    #[link_name = "ca_is_special__extern"]
    pub fn ca_is_special(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> libc::c_int;
    #[link_name = "ca_is_unknown__extern"]
    pub fn ca_is_unknown(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> libc::c_int;
    #[link_name = "ca_is_qq_elem__extern"]
    pub fn ca_is_qq_elem(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> libc::c_int;
    #[link_name = "ca_is_qq_elem_zero__extern"]
    pub fn ca_is_qq_elem_zero(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> libc::c_int;
    #[link_name = "ca_is_qq_elem_one__extern"]
    pub fn ca_is_qq_elem_one(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> libc::c_int;
    #[link_name = "ca_is_qq_elem_integer__extern"]
    pub fn ca_is_qq_elem_integer(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> libc::c_int;
    #[link_name = "ca_is_nf_elem__extern"]
    pub fn ca_is_nf_elem(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> libc::c_int;
    #[link_name = "ca_is_generic_elem__extern"]
    pub fn ca_is_generic_elem(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> libc::c_int;
    pub fn ca_is_cyclotomic_nf_elem(
        p: *mut slong,
        q: *mut ulong,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    ) -> libc::c_int;
    pub fn ca_is_zero_check_fast(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_number(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_zero(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_one(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_neg_one(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_i(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_neg_i(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_algebraic(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_rational(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_integer(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_real(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_negative_real(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_imaginary(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_undefined(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_infinity(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_uinf(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_signed_inf(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_pos_inf(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_neg_inf(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_pos_i_inf(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_is_neg_i_inf(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> truth_t;
    pub fn ca_check_equal(
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    ) -> truth_t;
    pub fn ca_check_lt(
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    ) -> truth_t;
    pub fn ca_check_le(
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    ) -> truth_t;
    pub fn ca_check_gt(
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    ) -> truth_t;
    pub fn ca_check_ge(
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    ) -> truth_t;
    pub fn ca_equal_repr(
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    ) -> libc::c_int;
    pub fn ca_cmp_repr(
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    ) -> libc::c_int;
    pub fn ca_hash_repr(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> ulong;
    pub fn ca_merge_fields(
        resx: *mut ca_struct,
        resy: *mut ca_struct,
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_condense_field(res: *mut ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_is_gen_as_ext(x: *const ca_struct, ctx: *mut ca_ctx_struct) -> ca_ext_ptr;
    pub fn _ca_mpoly_q_reduce_ideal(
        res: *mut fmpz_mpoly_q_struct,
        field: ca_field_srcptr,
        ctx: *mut ca_ctx_struct,
    );
    pub fn _ca_mpoly_q_simplify_fraction_ideal(
        res: *mut fmpz_mpoly_q_struct,
        field: ca_field_srcptr,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_neg(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_add_fmpq(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpq,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_add_fmpz(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpz,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_add_ui(res: *mut ca_struct, x: *const ca_struct, y: ulong, ctx: *mut ca_ctx_struct);
    pub fn ca_add_si(res: *mut ca_struct, x: *const ca_struct, y: slong, ctx: *mut ca_ctx_struct);
    pub fn ca_add(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sub_fmpq(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpq,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sub_fmpz(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpz,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sub_ui(res: *mut ca_struct, x: *const ca_struct, y: ulong, ctx: *mut ca_ctx_struct);
    pub fn ca_sub_si(res: *mut ca_struct, x: *const ca_struct, y: slong, ctx: *mut ca_ctx_struct);
    pub fn ca_fmpq_sub(
        res: *mut ca_struct,
        x: *const fmpq,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_fmpz_sub(
        res: *mut ca_struct,
        x: *const fmpz,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_ui_sub(res: *mut ca_struct, x: ulong, y: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_si_sub(res: *mut ca_struct, x: slong, y: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_sub(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_mul_fmpq(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpq,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_mul_fmpz(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpz,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_mul_ui(res: *mut ca_struct, x: *const ca_struct, y: ulong, ctx: *mut ca_ctx_struct);
    pub fn ca_mul_si(res: *mut ca_struct, x: *const ca_struct, y: slong, ctx: *mut ca_ctx_struct);
    pub fn ca_mul(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_inv(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_fmpq_div(
        res: *mut ca_struct,
        x: *const fmpq,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_fmpz_div(
        res: *mut ca_struct,
        x: *const fmpz,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_ui_div(res: *mut ca_struct, x: ulong, y: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_si_div(res: *mut ca_struct, x: slong, y: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_div_fmpq(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpq,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_div_fmpz(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpz,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_div_ui(res: *mut ca_struct, x: *const ca_struct, y: ulong, ctx: *mut ca_ctx_struct);
    pub fn ca_div_si(res: *mut ca_struct, x: *const ca_struct, y: slong, ctx: *mut ca_ctx_struct);
    pub fn ca_div(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_dot(
        res: *mut ca_struct,
        initial: *const ca_struct,
        subtract: libc::c_int,
        x: ca_srcptr,
        xstep: slong,
        y: ca_srcptr,
        ystep: slong,
        len: slong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_fmpz_poly_evaluate(
        res: *mut ca_struct,
        poly: *const fmpz_poly_struct,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_fmpq_poly_evaluate(
        res: *mut ca_struct,
        poly: *const fmpq_poly_struct,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_fmpz_mpoly_evaluate_horner(
        res: *mut ca_struct,
        f: *const fmpz_mpoly_struct,
        x: ca_srcptr,
        mctx: *const fmpz_mpoly_ctx_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_fmpz_mpoly_evaluate_iter(
        res: *mut ca_struct,
        f: *const fmpz_mpoly_struct,
        x: ca_srcptr,
        mctx: *const fmpz_mpoly_ctx_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_fmpz_mpoly_evaluate(
        res: *mut ca_struct,
        f: *const fmpz_mpoly_struct,
        x: ca_srcptr,
        mctx: *const fmpz_mpoly_ctx_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_fmpz_mpoly_q_evaluate(
        res: *mut ca_struct,
        f: *const fmpz_mpoly_q_struct,
        x: ca_srcptr,
        mctx: *const fmpz_mpoly_ctx_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_fmpz_mpoly_q_evaluate_no_division_by_zero(
        res: *mut ca_struct,
        f: *const fmpz_mpoly_q_struct,
        x: ca_srcptr,
        mctx: *const fmpz_mpoly_ctx_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_inv_no_division_by_zero(
        res: *mut ca_struct,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    #[link_name = "ca_sqr__extern"]
    pub fn ca_sqr(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_pow_fmpq(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpq,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_pow_fmpz(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const fmpz,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_pow_ui(res: *mut ca_struct, x: *const ca_struct, y: ulong, ctx: *mut ca_ctx_struct);
    pub fn ca_pow_si(res: *mut ca_struct, x: *const ca_struct, y: slong, ctx: *mut ca_ctx_struct);
    pub fn ca_pow(
        res: *mut ca_struct,
        x: *const ca_struct,
        y: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_pow_si_arithmetic(
        res: *mut ca_struct,
        x: *const ca_struct,
        n: slong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sqrt_inert(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_sqrt_nofactor(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_sqrt_factor(
        res: *mut ca_struct,
        x: *const ca_struct,
        flags: ulong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sqrt(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    #[link_name = "ca_sqrt_ui__extern"]
    pub fn ca_sqrt_ui(res: *mut ca_struct, n: ulong, ctx: *mut ca_ctx_struct);
    pub fn ca_conj_shallow(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_conj_deep(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_conj(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_abs(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_sgn(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_csgn(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_arg(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_re(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_im(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_floor(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_ceil(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_exp(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_log(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_sin_cos_exponential(
        res1: *mut ca_struct,
        res2: *mut ca_struct,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sin_cos_direct_exp_hack(
        res1: *mut ca_struct,
        res2: *mut ca_struct,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sin_cos_direct(
        res1: *mut ca_struct,
        res2: *mut ca_struct,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sin_cos_tangent(
        res1: *mut ca_struct,
        res2: *mut ca_struct,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sin_cos(
        res1: *mut ca_struct,
        res2: *mut ca_struct,
        x: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_sin(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_cos(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_tan_sine_cosine(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_tan_exponential(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_tan_direct(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_tan(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_cot(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_atan_logarithm(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_atan_direct(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_atan(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_asin_logarithm(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_asin_direct(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_asin(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_acos_logarithm(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_acos_direct(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_acos(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_erf(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_erfc(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_erfi(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_gamma(res: *mut ca_struct, x: *const ca_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_get_acb_raw(
        res: *mut acb_struct,
        x: *const ca_struct,
        prec: slong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_get_acb(
        res: *mut acb_struct,
        x: *const ca_struct,
        prec: slong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_get_acb_accurate_parts(
        res: *mut acb_struct,
        x: *const ca_struct,
        prec: slong,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_get_decimal_str(
        x: *const ca_struct,
        digits: slong,
        flags: ulong,
        ctx: *mut ca_ctx_struct,
    ) -> *mut libc::c_char;
    pub fn ca_factor_init(fac: *mut ca_factor_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_factor_clear(fac: *mut ca_factor_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_factor_one(fac: *mut ca_factor_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_factor_print(fac: *const ca_factor_struct, ctx: *mut ca_ctx_struct);
    pub fn ca_factor_insert(
        fac: *mut ca_factor_struct,
        base: *const ca_struct,
        exp: *const ca_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_factor_get_ca(
        res: *mut ca_struct,
        fac: *const ca_factor_struct,
        ctx: *mut ca_ctx_struct,
    );
    pub fn ca_factor(
        res: *mut ca_factor_struct,
        x: *const ca_struct,
        flags: ulong,
        ctx: *mut ca_ctx_struct,
    );
}