Changeset bf5bec1 in git for libpolys


Ignore:
Timestamp:
Jul 5, 2017, 1:53:50 PM (7 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', '2a584933abf2a2d3082034c7586d38bb6de1a30a')
Children:
32c5f947e5ea873df3119173b8d179ad7fb4197767f9e8e1fc9856b995aae2d27c9a3848419e3d138226f6e95990941b4d0fb1d572d060df2c38db62
Parents:
e93b00355896c3f6635d8c010d17067b1f821ea7
Message:
introduce crossprod(.....) for coeffs

- Float(..) for n_R, n_long_R to construct coeffs
- ntupel.*: implementation for n_nTupel
Location:
libpolys/coeffs
Files:
2 added
5 edited

Legend:

Unmodified
Added
Removed
  • libpolys/coeffs/Makefile.am

    re93b00 rbf5bec1  
    1616  numbers.cc rintegers.cc rmodulo2m.cc rmodulon.cc shortfl.cc \
    1717  gnumpc.cc gnumpfl.cc longrat.cc longrat0.cc ffields.cc \
    18   modulop.cc mpr_complex.cc \
     18  modulop.cc mpr_complex.cc ntupel.cc \
    1919  bigintmat.cc  AE.cc OPAE.cc AEp.cc OPAEp.cc AEQ.cc OPAEQ.cc \
    2020  flintcf_Q.cc flintcf_Zn.cc
     
    2525libcoeffs_la_include_HEADERS = \
    2626  coeffs.h numbers.h si_gmp.h gnumpc.h gnumpfl.h longrat.h modulop.h ffields.h rintegers.h rmodulo2m.h rmodulon.h \
    27   shortfl.h mpr_complex.h mpr_global.h numstats.h \
     27  shortfl.h mpr_complex.h mpr_global.h numstats.h ntupel.h \
    2828  bigintmat.h Enumerator.h AE.h OPAE.h AEp.h OPAEp.h AEQ.h OPAEQ.h \
    2929  flintcf_Q.h flintcf_Zn.h
  • libpolys/coeffs/coeffs.h

    re93b00 rbf5bec1  
    4141                  is transcendental */
    4242  n_long_C, /**< complex floating point (GMP) numbers */
     43  n_nTupel, /**< n-tupel of cf: ZZ/p1,... ZZ/pn, R, long_R */
    4344  n_Z, /**< only used if HAVE_RINGS is defined  */
    4445  n_Zn, /**< only used if HAVE_RINGS is defined */
  • libpolys/coeffs/gnumpfl.cc

    re93b00 rbf5bec1  
    403403static char* ngfCoeffString(const coeffs r)
    404404{
    405   char *s=(char*)omAlloc(27);
    406   snprintf(s,27,"real,%d,%d",r->float_len,r->float_len2);
     405  char *s=(char*)omAlloc(30);
     406  snprintf(s,30,"Float(%d,%d)",r->float_len,r->float_len2);
    407407  return s;
    408408}
     
    410410static char* ngfCoeffName(const coeffs r)
    411411{
    412   static char ngfCoeffName_buf[27];
    413   snprintf(ngfCoeffName_buf,27,"RR(%d,%d)",r->float_len,r->float_len2);
     412  static char ngfCoeffName_buf[30];
     413  snprintf(ngfCoeffName_buf,30,"Float(%d,%d)",r->float_len,r->float_len2);
    414414  return ngfCoeffName_buf;
    415415}
     
    503503static void ngfCoeffWrite  (const coeffs r, BOOLEAN /*details*/)
    504504{
    505   Print("real:%d digits, additional %d digits",
    506                r->float_len,r->float_len2);  /* long R */
     505  Print("Float(%d,%d)", r->float_len,r->float_len2);  /* long R */
    507506}
    508507
  • libpolys/coeffs/numbers.cc

    re93b00 rbf5bec1  
    2525#include "coeffs/ffields.h"
    2626#include "coeffs/shortfl.h"
     27#include "coeffs/ntupel.h"
    2728
    2829#ifdef HAVE_RINGS
     
    322323 #endif
    323324 ngcInitChar,  /* n_long_C */
     325 nnInitChar,   /* n_nTupel */
    324326 #ifdef HAVE_RINGS
    325327 nrzInitChar,  /* n_Z */
  • libpolys/coeffs/shortfl.cc

    re93b00 rbf5bec1  
    6464{
    6565  assume( getCoeffType(r) == n_R );
    66   PrintS("real");  /* R */
     66  PrintS("Float()");  /* R */
    6767}
    6868
     
    263263  assume( getCoeffType(r) == n_R );
    264264
    265   #if SIZEOF_DOUBLE == SIZEOF_LONG
    266   char ch[16];
    267   int n = sprintf(ch,"%12.6e", nf(a).F());
    268   #else
     265  //#if SIZEOF_DOUBLE == SIZEOF_LONG
     266  //char ch[16];
     267  //int n = sprintf(ch,"%12.6e", nf(a).F());
     268  //#else
    269269  char ch[11];
    270270  int n = sprintf(ch,"%9.3e", nf(a).F());
    271   #endif
     271  //#endif
    272272  if (ch[0] == '-')
    273273  {
     
    712712static char* nrCoeffString(const coeffs r)
    713713{
    714   return omStrDup("real");
     714  return omStrDup("Float()");
    715715}
    716716
    717717static char* nrCoeffName(const coeffs r)
    718718{
    719   return (char*)"real";
     719  return (char*)"Float()";
    720720}
    721721
Note: See TracChangeset for help on using the changeset viewer.