Changeset 9234fb in git for kernel


Ignore:
Timestamp:
Jan 9, 2013, 12:39:10 PM (11 years ago)
Author:
Andreas Steenpass <steenpass@…>
Branches:
(u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', '38dfc5131670d387a89455159ed1e071997eec94')
Children:
c81bf79ced86ab51e160b984ca42699ac44228a0
Parents:
14a45578ff0a670cc8f091fed8b195c50ef51126
git-author:
Andreas Steenpass <steenpass@mathematik.uni-kl.de>2013-01-09 12:39:10+01:00
git-committer:
Oleksandr Motsak <motsak@mathematik.uni-kl.de>2013-02-19 20:27:28+01:00
Message:
add: idKeepFirstK() in ideals.cc

Conflicts:
	Singular/MinorInterface.cc
	kernel/ideals.cc
	kernel/ideals.h
Location:
kernel
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • kernel/ideals.cc

    r14a455 r9234fb  
    25592559*/
    25602560
    2561 
    2562 
     2561/// keeps the first k (>= 1) entries of the given ideal
     2562/// (Note that the kept polynomials may be zero.)
     2563void idKeepFirstK(ideal id, const int k)
     2564{
     2565     for (int i = IDELEMS(id)-1; i >= k; i--)
     2566     {
     2567        if (id->m[i] != NULL) pDelete(&id->m[i]);
     2568     }
     2569     pEnlargeSet(&(id->m), IDELEMS(id), k-IDELEMS(id));
     2570     IDELEMS(id) = k;
     2571}
     2572
  • kernel/ideals.h

    r14a455 r9234fb  
    2424}
    2525
     26void idKeepFirstK(ideal ide, const int k);
     27
    2628/// delete an ideal
    2729inline void idDelete (ideal* h, ring r = currRing)
Note: See TracChangeset for help on using the changeset viewer.