version 1.8, 2020/06/19 10:18:13 |
version 1.10, 2020/07/03 03:37:59 |
|
|
/* $OpenXM: OpenXM_contrib2/asir2018/engine/nd.h,v 1.7 2019/08/21 00:37:47 noro Exp $ */ |
/* $OpenXM: OpenXM_contrib2/asir2018/engine/nd.h,v 1.9 2020/06/30 01:52:17 noro Exp $ */ |
#include "ca.h" |
#include "ca.h" |
#include "parse.h" |
#include "parse.h" |
#include "ox.h" |
#include "ox.h" |
Line 114 typedef struct oNM_ind_pair |
|
Line 114 typedef struct oNM_ind_pair |
|
{ |
{ |
NM mul; |
NM mul; |
int index,sugar; |
int index,sugar; |
|
SIG sig; |
} *NM_ind_pair; |
} *NM_ind_pair; |
|
|
typedef struct oIndArray |
typedef struct oIndArray |
Line 219 if(!(r)){NEWNM(r);(c)=(r);}else{NEWNM(NEXT(c));(c)=NEX |
|
Line 220 if(!(r)){NEWNM(r);(c)=(r);}else{NEWNM(NEXT(c));(c)=NEX |
|
if(!(r)){(c)=(r)=(s);}else{NEXT(c)=(s);(c)=(s);} |
if(!(r)){(c)=(r)=(s);}else{NEXT(c)=(s);(c)=(s);} |
#define NEXTND_pairs(r,c) \ |
#define NEXTND_pairs(r,c) \ |
if(!(r)){NEWND_pairs(r);(c)=(r);}else{NEWND_pairs(NEXT(c));(c)=NEXT(c);} |
if(!(r)){NEWND_pairs(r);(c)=(r);}else{NEWND_pairs(NEXT(c));(c)=NEXT(c);} |
#define MKNM_ind_pair(p,m,i,s) (NEWNM_ind_pair(p),(p)->mul=(m),(p)->index=(i),(p)->sugar = (s)) |
#define MKNM_ind_pair(p,m,i,s,sg)\ |
|
(NEWNM_ind_pair(p),(p)->mul=(m),(p)->index=(i),(p)->sugar = (s),(p)->sig=(sg)) |
|
|
/* deallocators */ |
/* deallocators */ |
#define FREENM(m) NEXT(m)=_nm_free_list; _nm_free_list=(m) |
#define FREENM(m) NEXT(m)=_nm_free_list; _nm_free_list=(m) |
Line 277 NODE nd_f4(int m,int checkonly,int **indp); |
|
Line 279 NODE nd_f4(int m,int checkonly,int **indp); |
|
NODE nd_gb(int m,int ishomo,int checkonly,int gensyz,int **indp); |
NODE nd_gb(int m,int ishomo,int checkonly,int gensyz,int **indp); |
NODE nd_gb_trace(int m,int ishomo,int **indp); |
NODE nd_gb_trace(int m,int ishomo,int **indp); |
NODE nd_f4_trace(int m,int **indp); |
NODE nd_f4_trace(int m,int **indp); |
void nd_sba(LIST f,LIST v,int m,int homo,int retdp,struct order_spec *ord,LIST *rp); |
void nd_sba(LIST f,LIST v,int m,int homo,int retdp,int f4,struct order_spec *ord,LIST *rp); |
|
|
/* ndl functions */ |
/* ndl functions */ |
int ndl_weight(UINT *d); |
int ndl_weight(UINT *d); |
Line 326 void ndp_print(ND_pairs d); |
|
Line 328 void ndp_print(ND_pairs d); |
|
/* setup, reconstruct */ |
/* setup, reconstruct */ |
void nd_init_ord(struct order_spec *spec); |
void nd_init_ord(struct order_spec *spec); |
ND_pairs nd_reconstruct(int trace,ND_pairs ndp); |
ND_pairs nd_reconstruct(int trace,ND_pairs ndp); |
|
void nd_reconstruct_s(int trace,ND_pairs *ndp); |
int ndv_setup(int mod,int trace,NODE f,int dont_sort,int dont_removecont,int sba); |
int ndv_setup(int mod,int trace,NODE f,int dont_sort,int dont_removecont,int sba); |
void nd_setup_parameters(int nvar,int max); |
void nd_setup_parameters(int nvar,int max); |
BlockMask nd_create_blockmask(struct order_spec *ord); |
BlockMask nd_create_blockmask(struct order_spec *ord); |
Line 409 int ndl_ww_lex_compare(UINT *a1,UINT *a2); |
|
Line 412 int ndl_ww_lex_compare(UINT *a1,UINT *a2); |
|
|
|
#if SIZEOF_LONG == 8 |
#if SIZEOF_LONG == 8 |
int nd_to_vect64(int mod,UINT *s0,int n,ND d,mp_limb_t *r); |
int nd_to_vect64(int mod,UINT *s0,int n,ND d,mp_limb_t *r); |
int ndv_reduce_vect64(int m,mp_limb_t *svect,mp_limb_t *cvect,int col,IndArray *imat,NM_ind_pair *rp0,int nred); |
int ndv_reduce_vect64(int m,mp_limb_t *svect,mp_limb_t *cvect,int col,IndArray *imat,NM_ind_pair *rp0,int nred,SIG sig); |
NDV vect64_to_ndv(mp_limb_t *vect,int spcol,int col,int *rhead,UINT *s0vect); |
NDV vect64_to_ndv(mp_limb_t *vect,int spcol,int col,int *rhead,UINT *s0vect); |
void red_by_vect64(int m, mp_limb_t *p,unsigned int *c,mp_limb_t *r,unsigned int hc,int len); |
void red_by_vect64(int m, mp_limb_t *p,unsigned int *c,mp_limb_t *r,unsigned int hc,int len); |
int nd_gauss_elim_mod64(mp_limb_t **mat,int *sugar,ND_pairs *spactive,int row,int col,int md,int *colstat); |
int nd_gauss_elim_mod64(mp_limb_t **mat,int *sugar,ND_pairs *spactive,int row,int col,int md,int *colstat); |