MCPcopy Create free account
hub / github.com/Singular/Singular / DefRingParlp

Function DefRingParlp

Singular/walk.cc:2989–3039  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2987}
2988
2989static void DefRingParlp(void)
2990{
2991 int nv = currRing->N;
2992
2993 ring r=rCopy0(currRing,FALSE,FALSE);
2994
2995 int nb = rBlocks(currRing) + 1;
2996
2997 /*weights: entries for 3 blocks: NULL Made:???*/
2998
2999 r->wvhdl = (int **)omAlloc0(nb * sizeof(int_ptr));
3000
3001 /* order: lp,C,0 */
3002 r->order = (rRingOrder_t *) omAlloc(nb * sizeof(rRingOrder_t *));
3003 r->block0 = (int *)omAlloc0(nb * sizeof(int *));
3004 r->block1 = (int *)omAlloc0(nb * sizeof(int *));
3005
3006 /* ringorder lp for the first block: var 1..nv */
3007 r->order[0] = ringorder_lp;
3008 r->block0[0] = 1;
3009 r->block1[0] = nv;
3010
3011 /* ringorder C for the second block */
3012 r->order[1] = ringorder_C;
3013
3014 /* the last block: everything is 0 */
3015 r->order[2] = (rRingOrder_t)0;
3016
3017 /*polynomial ring*/
3018 r->OrdSgn = 1;
3019
3020
3021// if (rParameter(currRing)!=NULL)
3022// {
3023// r->cf->extRing->qideal->m[0]=p_Copy(currRing->cf->extRing->qideal->m[0], currRing->cf->extRing);
3024// int l=rPar(currRing);
3025// r->cf->extRing->names=(char **)omAlloc(l*sizeof(char_ptr));
3026//
3027// for(int i=l-1;i>=0;i--)
3028// {
3029// rParameter(r)[i]=omStrDup(rParameter(currRing)[i]);
3030// }
3031// }
3032
3033 // complete ring intializations
3034
3035 rComplete(r);
3036
3037 // execute the created ring
3038 rChangeCurrRing(r);
3039}
3040
3041/*************************************************************
3042 * check whether one or more components of a vector are zero *

Callers 8

LastGBFunction · 0.85
Rec_LastGBFunction · 0.85
MprwalkFunction · 0.85
MfwalkFunction · 0.85
MfrwalkFunction · 0.85
TranMImprovwalkFunction · 0.85
walk.ccFile · 0.85
Mpwalk_MAltwalk1Function · 0.85

Calls 5

rCopy0Function · 0.85
rBlocksFunction · 0.85
omAlloc0Function · 0.85
rCompleteFunction · 0.85
rChangeCurrRingFunction · 0.85

Tested by

no test coverage detected