- Timestamp:
- Nov 19, 2011, 2:47:32 AM (12 years ago)
- Branches:
- (u'spielwiese', '4a9821a93ffdc22a6696668bd4f6b8c9de3e6c5f')
- Children:
- 80c102e75622524947cd27fb319c231bc62c9233
- Parents:
- 615ca847eb54f53d0896364932b51cc9074dffda
- git-author:
- Oleksandr Motsak <motsak@mathematik.uni-kl.de>2011-11-19 02:47:32+01:00
- git-committer:
- Oleksandr Motsak <motsak@mathematik.uni-kl.de>2011-11-19 03:27:47+01:00
- Location:
- kernel
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/Makefile.am
r615ca8 reb0708 38 38 fglmzero.cc fglmvec.cc fglmgauss.cc fglmhom.cc fglmcomb.cc \ 39 39 kspoly.cc kpolys.cc \ 40 semic.cc \41 40 syz.cc syz0.cc syz1.cc syz2.cc syz3.cc \ 42 41 timer.cc \ -
kernel/kutil.cc
r615ca8 reb0708 6662 6662 void enterSMoraNF (LObject p,int atS,kStrategy strat, int atR=-1); 6663 6663 // ../Singular/misc.cc: 6664 char * showOption();6664 extern char * showOption(); 6665 6665 6666 6666 void kDebugPrint(kStrategy strat) -
kernel/semic.cc
r615ca8 reb0708 8 8 #define SEMIC_CC 9 9 10 #include "mod2.h"10 #include "mod2.h" 11 11 12 12 #ifdef HAVE_SPECTRUM … … 14 14 #ifdef SEMIC_PRINT 15 15 #ifndef SEMIC_IOSTREAM 16 #include <stdio.h>16 #include <stdio.h> 17 17 #else 18 #include <iostream.h>18 #include <iostream.h> 19 19 #endif 20 20 #endif 21 21 22 #include<string.h> 22 #include <string.h> 23 23 24 #ifndef ix86_Win 24 25 //#include<values.h> 25 26 #endif 26 27 27 #include<misc/intvec.h> 28 #include<misc/mylimits.h> 29 #include"GMPrat.h" 30 #include"semic.h" 31 32 // ---------------------------------------------------------------------------- 33 // Delete the memory of a spectrum 34 // ---------------------------------------------------------------------------- 35 36 inline void spectrum::copy_delete( void ) 37 { 38 if( s != (Rational*)NULL && n > 0 ) delete [] s; 39 if( w != (int*)NULL && n > 0 ) delete [] w; 40 copy_zero( ); 28 #include <misc/intvec.h> 29 #include <misc/mylimits.h> 30 #include "GMPrat.h" 31 #include "semic.h" 32 33 // ---------------------------------------------------------------------------- 34 // Copy constructor for spectrum 35 // ---------------------------------------------------------------------------- 36 37 spectrum::spectrum( const spectrum &spec ) 38 { 39 copy_deep( spec ); 40 } 41 42 // ---------------------------------------------------------------------------- 43 // Destructor for spectrum 44 // ---------------------------------------------------------------------------- 45 46 spectrum::~spectrum( ) 47 { 48 copy_delete( ); 41 49 } 42 50 … … 110 118 111 119 // ---------------------------------------------------------------------------- 112 // Copy constructor for spectrum113 // ----------------------------------------------------------------------------114 115 spectrum::spectrum( const spectrum &spec )116 {117 copy_deep( spec );118 }119 120 // ----------------------------------------------------------------------------121 // Destructor for spectrum122 // ----------------------------------------------------------------------------123 124 spectrum::~spectrum( )125 {126 copy_delete( );127 }128 129 130 // ----------------------------------------------------------------------------131 120 // operator = for spectrum 132 121 // ---------------------------------------------------------------------------- -
kernel/semic.h
r615ca8 reb0708 12 12 #ifndef SEMIC_H 13 13 #define SEMIC_H 14 15 #ifdef HAVE_SPECTRUM 16 14 17 15 18 #include <kernel/GMPrat.h> … … 68 71 int *w; // multiplicities 69 72 70 spectrum( ); 71 spectrum( const spectrum& ); 73 // spectrum( ); 72 74 // spectrum( lists ); 73 75 76 /// Zero constructor 77 spectrum( ) 78 { 79 copy_zero( ); 80 } 81 82 spectrum( const spectrum& ); 83 74 84 ~spectrum( ); 75 85 … … 85 95 86 96 void copy_new ( int ); 87 void copy_delete ( void ); 88 void copy_zero ( void ); 97 // void copy_delete ( void ); 89 98 90 void copy_shallow( spectrum& ); 99 /// Delete the memory of a spectrum 100 inline void copy_delete( void ) 101 { 102 if( s != (Rational*)NULL && n > 0 ) delete [] s; 103 if( w != (int*)NULL && n > 0 ) delete [] w; 104 copy_zero( ); 105 } 106 107 /// Initialize with zero 108 inline void copy_zero( void ) 109 { 110 mu = 0; 111 pg = 0; 112 n = 0; 113 s = (Rational*)NULL; 114 w = (int*)NULL; 115 } 116 117 /// Initialize shallow from another spectrum 118 inline void copy_shallow( spectrum &spec ) 119 { 120 mu = spec.mu; 121 pg = spec.pg; 122 n = spec.n; 123 s = spec.s; 124 w = spec.w; 125 } 126 91 127 void copy_deep ( const spectrum& ); 92 128 // void copy_deep ( lists ); … … 105 141 }; 106 142 107 108 // ---------------------------------------------------------------------------- 109 // Initialize with zero 110 // ---------------------------------------------------------------------------- 111 112 inline void spectrum::copy_zero( void ) 113 { 114 mu = 0; 115 pg = 0; 116 n = 0; 117 s = (Rational*)NULL; 118 w = (int*)NULL; 119 } 120 121 // ---------------------------------------------------------------------------- 122 // Initialize shallow from another spectrum 123 // ---------------------------------------------------------------------------- 124 125 inline void spectrum::copy_shallow( spectrum &spec ) 126 { 127 mu = spec.mu; 128 pg = spec.pg; 129 n = spec.n; 130 s = spec.s; 131 w = spec.w; 132 } 133 134 // ---------------------------------------------------------------------------- 135 // Zero constructor 136 // ---------------------------------------------------------------------------- 137 138 inline spectrum::spectrum( ) 139 { 140 copy_zero( ); 141 } 142 143 #endif /*HAVE_SPECTRUM*/ 143 144 // ---------------------------------------------------------------------------- 144 145 // semic.h -
kernel/test.cc
r615ca8 reb0708 55 55 int mmInit(void) {return 1; } 56 56 #endif 57 58 // // TODO: DUE to the use of HALT in npolygon.cc :((( 59 extern "C" {void m2_end(int i){exit(i);}} 60 61 // // TODO: DUE to its use in kutil.cc :((( 62 char * showOption(){return NULL;} 63 64 // // TODO: DUE to its use in feread.cc :((( 65 char *iiArithGetCmd(int nPos){return NULL; } 57 66 58 67
Note: See TracChangeset
for help on using the changeset viewer.