Changeset 1cbb1f4 in git for Singular/iparith.cc


Ignore:
Timestamp:
Jan 6, 2012, 9:13:51 PM (12 years ago)
Author:
Oleksandr Motsak <motsak@…>
Branches:
(u'spielwiese', '8e0ad00ce244dfd0756200662572aef8402f13d5')
Children:
79020f1e7903b16af027b1e0a1240dd1b386a87a
Parents:
0a3fa32bcd8b202183dc9d54b4f82cb6d069f087
git-author:
Oleksandr Motsak <motsak@mathematik.uni-kl.de>2012-01-06 21:13:51+01:00
git-committer:
Oleksandr Motsak <motsak@mathematik.uni-kl.de>2012-01-06 21:59:37+01:00
Message:
(Trac Ticket #389) transfer denominator() and numerator() from poly.lib to the Singular kernel

ADD: new kernel functions denominator& numerator: number -> number
CHG: removed denominator& numerator from poly.lib
ADD: added documentation for these new kernel functions
FIX: updated tests (Manual/listvar.tst)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Singular/iparith.cc

    r0a3fa3 r1cbb1f4  
    8181#include <kernel/timer.h>
    8282
     83#include <polys/coeffrings.h>
    8384
    8485lists rDecompose(const ring r); ring rCompose(const lists  L);
     
    37033704  return FALSE;
    37043705}
     3706
     3707/// Return the denominator of the input number
     3708/// NOTE: the input number is normalized as a side effect
     3709static BOOLEAN jjDENOMINATOR(leftv res, leftv v)
     3710{
     3711  number n = reinterpret_cast<number>(v->Data());
     3712  res->data = reinterpret_cast<void*>(n_GetDenom(n, currRing));
     3713  return FALSE;
     3714}
     3715
     3716/// Return the numerator of the input number
     3717/// NOTE: the input number is normalized as a side effect
     3718static BOOLEAN jjNUMERATOR(leftv res, leftv v)
     3719{
     3720  number n = reinterpret_cast<number>(v->Data());
     3721  res->data = reinterpret_cast<void*>(n_GetNumerator(n, currRing));
     3722  return FALSE;
     3723}
     3724
     3725
     3726
     3727
    37053728#ifdef HAVE_FACTORY
    37063729static BOOLEAN jjDET(leftv res, leftv v)
Note: See TracChangeset for help on using the changeset viewer.