Changeset 7c53a72 in git for Singular/ring.cc


Ignore:
Timestamp:
Jan 30, 2001, 2:37:04 PM (23 years ago)
Author:
Hans Schönemann <hannes@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
150dc889f015f345eeda915fcc0b97aa94ab2116
Parents:
ac3da3f3a9cb4825dbea5479b2db55fb3d7c09a2
Message:
* hannes: second par for real-field


git-svn-id: file:///usr/local/Singular/svn/trunk@5139 2c84dea3-7e68-4137-9b89-c4e89433aadc
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Singular/ring.cc

    rac3da3 r7c53a72  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: ring.cc,v 1.154 2001-01-20 11:40:14 Singular Exp $ */
     4/* $Id: ring.cc,v 1.155 2001-01-30 13:37:02 Singular Exp $ */
    55
    66/*
     
    7777//  if (r->ch== -1)
    7878//  {
    79 //    if (r->ch_flags==(short)0) return TRUE;
     79//    if (r->float_len==(short)0) return TRUE;
    8080//  }
    8181//  return FALSE;
     
    473473  int ch;
    474474  int float_len=0;
     475  int float_len2=0;
    475476  ring R = NULL;
    476477  idhdl tmp = NULL;
     
    495496      float_len=(int)pn->next->Data();
    496497      pn=pn->next;
     498      if ((pn->next!=NULL) && (pn->next->Typ()==INT_CMD))
     499      {
     500        float_len2=(int)pn->next->Data();
     501        pn=pn->next;
     502      }
    497503    }
    498504    if ((pn->next==NULL) && complex_flag)
     
    514520
    515521  /* characteristic -----------------------------------------------*/
    516   /* input: 0 ch=0 : Q     parameter=NULL    ffChar=FALSE   ch_flags
     522  /* input: 0 ch=0 : Q     parameter=NULL    ffChar=FALSE   float_len
    517523   *         0    1 : Q(a,...)        *names         FALSE
    518524   *         0   -1 : R               NULL           FALSE  0
     
    553559  if (ch == -1)
    554560  {
    555     R->ch_flags= min(float_len,32767);
     561    if (float_len2==0) float_len2=float_len;
     562    R->float_len= min(float_len,32767);
     563    R->float_len2= min(float_len2,32767);
    556564  }
    557565
     
    584592  if ((R->ch == - 1)
    585593  && (R->parameter !=NULL)
    586   && (R->ch_flags < SHORT_REAL_LENGTH))
    587     R->ch_flags = SHORT_REAL_LENGTH;
     594  && (R->float_len < SHORT_REAL_LENGTH))
     595    R->float_len = SHORT_REAL_LENGTH;
    588596
    589597  /* names and number of variables-------------------------------------*/
     
    698706    if ( rField_is_R(r) )             PrintS("0 (real)\n");  /* R */
    699707    else if ( rField_is_long_R(r) )
    700       Print("0 (real:%d digits)\n",r->ch_flags);  /* long R */
     708      Print("0 (real:%d digits, additional %d digits)\n",
     709             r->float_len,r->float_len2);  /* long R */
    701710    else if ( rField_is_long_C(r) )
    702       Print("0 (complex:%d digits)\n",r->ch_flags);  /* long C */
     711      Print("0 (complex:%d digits, , additional %d digits)\n",
     712             r->float_len, r->float_len2);  /* long C */
    703713    else
    704714      Print ("%d\n",rChar(r)); /* Fp(a) */
     
    18071817
    18081818  if ((rInternalChar(r1) != rInternalChar(r2))
    1809   || (r1->ch_flags != r2->ch_flags)
     1819  || (r1->float_len != r2->float_len)
     1820  || (r1->float_len2 != r2->float_len2)
    18101821  || (r1->N != r2->N)
    18111822  || (r1->OrdSgn != r2->OrdSgn)
Note: See TracChangeset for help on using the changeset viewer.