Skip to content

Commit fd4ec4e

Browse files
committed
More fixes
1 parent 126e60f commit fd4ec4e

9 files changed

Lines changed: 6 additions & 70 deletions

File tree

doc/source/flintxx_functions.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -782,7 +782,7 @@ Modular gaussian elimination
782782

783783
.. cpp:function:: slong Fmpz_mat_target::set_rref_mod(Fmpz_expr n, permxx* perm = 0)
784784

785-
See ``fmpz_mat_rref_mod``.
785+
See ``fmpz_mod_mat_rref``.
786786

787787
Nullspace
788788
-------------------------------------------------------------------------------

src/flintxx/doc/flintxx.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -871,7 +871,7 @@ Ltuple<slong, fmpz_matxx, fmpzxx>_expr rref(Fmpz_mat_expr A)
871871

872872
slong Fmpz_mat_target::set_rref_mod(Fmpz_expr n, permxx* perm = 0)
873873

874-
See \code{fmpz_mat_rref_mod}.
874+
See \code{fmpz_mod_mat_rref}.
875875

876876
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
877877
Nullspace

src/flintxx/test/t-arithxx.cpp

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,6 @@ test_stirling()
2626
fmpz_vecxx v1(func##_vec(n, k).evaluate() /* test temporary alloc */); \
2727
for(slong i = 0;i < v1.size();++i) \
2828
tassert(v1[i] == func(n, i)); \
29-
tassert(func##_vec_next(func##_vec(n, k), n+1).size() == k); \
30-
fmpz_vecxx v2(func##_vec_next(v1, n+1)); \
31-
for(slong i = 0;i < v2.size();++i) \
32-
tassert(v2[i] == func(n+1, i)); \
33-
fmpz_vecxx v3(func##_vec(n, n+1)); \
34-
fmpz_vecxx v4(func##_vec_next(v3, n+1)); \
35-
tassert(v4.size() == n+2 && v3.size() == n+1); \
36-
for(slong i = 0;i < v4.size();++i) \
37-
tassert(v4[i] == func(n+1, i)); \
3829
tassert(matfunc(n, k).rows() == n && matfunc(n, k).cols() == k); \
3930
fmpz_matxx M(matfunc(n, k).evaluate() /* test temporaries */); \
4031
for(slong i = 0;i < M.rows();++i) \

src/flintxx/test/t-fmpz_matxx.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include <string>
1515

1616
#include "fmpz_matxx.h"
17+
#include "fmpz_mod_matxx.h"
1718
#include "fmpz_vecxx.h"
1819
#include "flintxx/test/helpers.h"
1920

@@ -258,7 +259,7 @@ test_row_reduction()
258259
fmpz_matxx B(A);
259260
fmpzxx n(1031);
260261
A.set_rref_mod(n, &p1);
261-
fmpz_mat_rref_mod(p2._data(), B._mat(), n._fmpz());
262+
fmpz_mod_mat_rref(p2._data(), B._mat(), n._fmpz());
262263
tassert(A == B && p1 == p2);
263264
}
264265

src/flintxx/test/t-fmpz_polyxx.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include <string>
1515

1616
#include "fmpz_polyxx.h"
17+
#include "fmpz_poly_factorxx.h"
1718
#include "nmod_polyxx.h"
1819

1920
#include "flintxx/test/helpers.h"

src/flintxx_public/arithxx.h

Lines changed: 0 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,6 @@ ARITHXX_DEFINE_BINOP(stirling_number_2, fmpzxx, at::slong, at::slong)
8181
ARITHXX_DEFINE_BINOP(stirling_number_1u_vec, fmpz_vecxx, at::slong, at::slong)
8282
ARITHXX_DEFINE_BINOP(stirling_number_1_vec, fmpz_vecxx, at::slong, at::slong)
8383
ARITHXX_DEFINE_BINOP(stirling_number_2_vec, fmpz_vecxx, at::slong, at::slong)
84-
FLINT_DEFINE_BINOP(stirling_number_1u_vec_next)
85-
FLINT_DEFINE_BINOP(stirling_number_1_vec_next)
86-
FLINT_DEFINE_BINOP(stirling_number_2_vec_next)
8784
FLINT_DEFINE_BINOP(stirling_matrix_1u)
8885
FLINT_DEFINE_BINOP(stirling_matrix_1)
8986
FLINT_DEFINE_BINOP(stirling_matrix_2)
@@ -99,23 +96,6 @@ template<> struct outsize<operations::stirling_number_1_vec_op>
9996
: outsize<operations::stirling_number_1u_vec_op> { };
10097
template<> struct outsize<operations::stirling_number_2_vec_op>
10198
: outsize<operations::stirling_number_1u_vec_op> { };
102-
103-
template<>
104-
struct outsize<operations::stirling_number_1u_vec_next_op>
105-
{
106-
template<class Expr>
107-
static unsigned get(const Expr& e)
108-
{
109-
slong r = e._data().first().size();
110-
if(r == e._data().second())
111-
return r + 1;
112-
return r;
113-
}
114-
};
115-
template<> struct outsize<operations::stirling_number_1_vec_next_op>
116-
: outsize<operations::stirling_number_1u_vec_next_op> { };
117-
template<> struct outsize<operations::stirling_number_2_vec_next_op>
118-
: outsize<operations::stirling_number_1u_vec_next_op> { };
11999
} // vectors
120100

121101
namespace matrices {
@@ -134,19 +114,6 @@ template<> struct outsize<operations::stirling_matrix_2_op>
134114
} // matrices
135115

136116
namespace rules {
137-
FLINT_DEFINE_BINARY_EXPR_COND2(stirling_number_1u_vec_next_op, fmpz_vecxx,
138-
FMPZ_VECXX_COND_S, at::slong,
139-
arith_stirling_number_1u_vec_next(to._array(), e1._array(), e2,
140-
e1.size() + (e1.size() == e2)))
141-
FLINT_DEFINE_BINARY_EXPR_COND2(stirling_number_1_vec_next_op, fmpz_vecxx,
142-
FMPZ_VECXX_COND_S, at::slong,
143-
arith_stirling_number_1_vec_next(to._array(), e1._array(), e2,
144-
e1.size() + (e1.size() == e2)))
145-
FLINT_DEFINE_BINARY_EXPR_COND2(stirling_number_2_vec_next_op, fmpz_vecxx,
146-
FMPZ_VECXX_COND_S, at::slong,
147-
arith_stirling_number_2_vec_next(to._array(), e1._array(), e2,
148-
e1.size() + (e1.size() == e2)))
149-
150117
FLINT_DEFINE_BINARY_EXPR_COND2(stirling_matrix_1u_op, fmpz_matxx,
151118
at::slong, at::slong, arith_stirling_matrix_1u(to._mat()))
152119
FLINT_DEFINE_BINARY_EXPR_COND2(stirling_matrix_1_op, fmpz_matxx,

src/flintxx_public/fmpz_matxx.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ class fmpz_matxx_expression
226226
slong set_rref_mod(const Fmpz& p, permxx* perm = 0,
227227
typename mp::enable_if<traits::is_fmpzxx<Fmpz> >::type* = 0)
228228
{
229-
return fmpz_mat_rref_mod(maybe_perm_data(perm), _mat(), p.evaluate()._fmpz());
229+
return fmpz_mod_mat_rref(maybe_perm_data(perm), _mat(), p.evaluate()._fmpz());
230230
}
231231

232232
// these cause evaluation

src/flintxx_public/fmpz_mod_polyxx.h

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -628,28 +628,12 @@ FLINT_DEFINE_BINARY_EXPR_COND2(divrem_basecase_op, rdetail::fmpz_mod_polyxx_pair
628628
to.template get<0>()._poly(), to.template get<1>()._poly(),
629629
e1._poly(), e2._poly(), e1._ctx()))
630630

631-
FLINT_DEFINE_BINARY_EXPR_COND2(divrem_divconquer_op, rdetail::fmpz_mod_polyxx_pair,
632-
FMPZ_MOD_POLYXX_COND_S, FMPZ_MOD_POLYXX_COND_S,
633-
fmpz_mod_poly_divrem_divconquer(
634-
to.template get<0>()._poly(), to.template get<1>()._poly(),
635-
e1._poly(), e2._poly(), e1._ctx()))
636-
637-
FLINT_DEFINE_BINARY_EXPR_COND2(divrem_op, rdetail::fmpz_mod_polyxx_pair,
638-
FMPZ_MOD_POLYXX_COND_S, FMPZ_MOD_POLYXX_COND_S,
639-
fmpz_mod_poly_divrem_divconquer(
640-
to.template get<0>()._poly(), to.template get<1>()._poly(),
641-
e1._poly(), e2._poly(), e1._ctx()))
642-
643631
FLINT_DEFINE_BINARY_EXPR_COND2(divrem_f_op, rdetail::fmpz_mod_poly_divrem_f_rt,
644632
FMPZ_MOD_POLYXX_COND_S, FMPZ_MOD_POLYXX_COND_S,
645633
fmpz_mod_poly_divrem_f(
646634
to.template get<0>()._fmpz(), to.template get<1>()._poly(),
647635
to.template get<2>()._poly(), e1._poly(), e2._poly(), e1._ctx()))
648636

649-
FLINT_DEFINE_BINARY_EXPR_COND2(div_basecase_op, fmpz_mod_polyxx,
650-
FMPZ_MOD_POLYXX_COND_S, FMPZ_MOD_POLYXX_COND_S,
651-
fmpz_mod_poly_div_basecase(to._poly(), e1._poly(), e2._poly(), to._ctx()))
652-
653637
FLINT_DEFINE_BINARY_EXPR_COND2(rem_basecase_op, fmpz_mod_polyxx,
654638
FMPZ_MOD_POLYXX_COND_S, FMPZ_MOD_POLYXX_COND_S,
655639
fmpz_mod_poly_rem_basecase(to._poly(), e1._poly(), e2._poly(), to._ctx()))
@@ -662,10 +646,6 @@ FLINT_DEFINE_BINARY_EXPR_COND2(gcd_op, fmpz_mod_polyxx,
662646
FMPZ_MOD_POLYXX_COND_S, FMPZ_MOD_POLYXX_COND_S,
663647
fmpz_mod_poly_gcd(to._poly(), e1._poly(), e2._poly(), to._ctx()))
664648

665-
FLINT_DEFINE_BINARY_EXPR_COND2(gcd_euclidean_op, fmpz_mod_polyxx,
666-
FMPZ_MOD_POLYXX_COND_S, FMPZ_MOD_POLYXX_COND_S,
667-
fmpz_mod_poly_gcd_euclidean(to._poly(), e1._poly(), e2._poly(), to._ctx()))
668-
669649
namespace rdetail {
670650
typedef make_ltuple<mp::make_tuple<
671651
fmpz_mod_polyxx, fmpz_mod_polyxx, fmpz_mod_polyxx>::type>::type

src/flintxx_public/nmod_polyxx.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -757,10 +757,6 @@ NMOD_POLYXX_DEFINE_SERIES_F(sinh)
757757
NMOD_POLYXX_DEFINE_SERIES_F(cosh)
758758
NMOD_POLYXX_DEFINE_SERIES_F(tanh)
759759

760-
FLINT_DEFINE_BINARY_EXPR_COND2(exp_series_basecase_op, nmod_polyxx,
761-
NMOD_POLYXX_COND_S, traits::fits_into_slong,
762-
nmod_poly_exp_series_basecase(to._poly(), e1._poly(), e2))
763-
764760
FLINT_DEFINE_THREEARY_EXPR_COND3(log_series_monomial_op, nmod_polyxx,
765761
NMODXX_COND_S, traits::is_unsigned_integer, traits::fits_into_slong,
766762
nmod_poly_log_series_monomial_ui(to._poly(), e1._limb(), e2, e3))

0 commit comments

Comments
 (0)