Changeset f5da37 in git
- Timestamp:
- Aug 13, 2009, 7:24:45 PM (14 years ago)
- Branches:
- (u'spielwiese', '0d6b7fcd9813a1ca1ed4220cfa2b104b97a0a003')
- Children:
- 7d9b62a1308b2363fd7fd805a4689167ce92ccaa
- Parents:
- 64a88ed9bbe06816b964e301999e88484a0abab6
- Location:
- Singular
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/extra.cc
r64a88e rf5da37 2 2 * Computer Algebra System SINGULAR * 3 3 *****************************************/ 4 /* $Id: extra.cc,v 1.31 2 2009-08-06 10:18:00 SingularExp $ */4 /* $Id: extra.cc,v 1.313 2009-08-13 17:24:45 motsak Exp $ */ 5 5 /* 6 6 * ABSTRACT: general interface to internals of Singular ("system" command) … … 753 753 754 754 /// Returns old SyzCompLimit, can set new limit 755 if(strcmp(sys_cmd,"SetI SReferrence")==0)756 { 757 extern void rSetISReference(const ideal F, const int l, const int p, const intvec * componentWeights, const ring r);755 if(strcmp(sys_cmd,"SetInducedReferrence")==0) 756 { 757 extern void rSetISReference(const ideal F, const int rank, const int p, const intvec * componentWeights, const ring r); 758 758 759 759 if ((h!=NULL) && ( (h->Typ()==IDEAL_CMD) || (h->Typ()==MODUL_CMD))) 760 760 { 761 761 intvec * componentWeights = (intvec *)atGet(h,"isHomog",INTVEC_CMD); // No copy?! 762 762 763 const ideal F = (ideal)h->Data(); ; // No copy! 763 764 h=h->next; 764 765 765 int l = 0; // Starting syz-comp (1st: i+1)766 int rank = idRankFreeModule(F, currRing, currRing); // Starting syz-comp (1st: i+1) 766 767 767 768 if ((h!=NULL) && (h->Typ()==INT_CMD)) 768 769 { 769 l= (int)((long)(h->Data())); h=h->next;770 rank = (int)((long)(h->Data())); h=h->next; 770 771 } 771 772 … … 778 779 779 780 // F & componentWeights belong to that ordering block of currRing now: 780 rSetISReference(F, l, p, componentWeights, currRing); // F and componentWeights will be copied!781 rSetISReference(F, rank, p, componentWeights, currRing); // F and componentWeights will be copied! 781 782 } 782 783 else … … 787 788 return FALSE; 788 789 } 790 791 792 // F = system("ISUpdateComponents", F, V, MIN ); 793 // // replace gen(i) -> gen(MIN + V[i-MIN]) for all i > MIN in all terms from F! 794 // extern void pISUpdateComponents(ideal F, const intvec *const V, const int MIN, const ring r); 795 if(strcmp(sys_cmd,"ISUpdateComponents")==0) 796 { 797 798 PrintS("ISUpdateComponents:.... \n"); 799 800 if ((h!=NULL) && (h->Typ()==MODUL_CMD)) 801 { 802 ideal F = (ideal)h->Data(); ; // No copy! 803 h=h->next; 804 805 if ((h!=NULL) && (h->Typ()==INTVEC_CMD)) 806 { 807 const intvec* const V = (const intvec* const) h->Data(); 808 h=h->next; 809 810 if ((h!=NULL) && (h->Typ()==INT_CMD)) 811 { 812 const int MIN = (int)((long)(h->Data())); 813 814 extern void pISUpdateComponents(ideal F, const intvec *const V, const int MIN, const ring r); 815 pISUpdateComponents(F, V, MIN, currRing); 816 return FALSE; 817 } 818 } 819 } 820 821 WerrorS("`system(\"ISUpdateComponents\",<module>, intvec, int)` expected"); 822 return TRUE; 823 } 824 789 825 790 826 … … 2059 2095 #endif 2060 2096 /*==================== generic debug ==================================*/ 2061 #ifdef PDEBUG 2062 if(strcmp(sys_cmd,"DebugPrint")==0) 2063 { 2097 //#ifdef PDEBUG 2098 if(strcmp(sys_cmd,"DetailedPrint")==0) 2099 { 2100 if( h == NULL ) 2101 { 2102 WarnS("DetailedPrint needs arguments..."); 2103 return TRUE; 2104 } 2105 2064 2106 if( h->Typ() == RING_CMD) 2065 2107 { … … 2081 2123 if( h->Typ() == IDEAL_CMD || h->Typ() == MODUL_CMD) 2082 2124 { 2083 const int nTerms = 3;2084 2125 const ideal id = (const ideal)h->Data(); 2126 2127 h = h->Next(); 2128 2129 int nTerms = 3; 2130 2131 if( h!= NULL && h->Typ() == INT_CMD ) 2132 { 2133 int n = (int)(long)(h->Data()); 2134 if( n < 0 ) 2135 { 2136 Warn("Negative int argument: %d", n); 2137 } 2138 else 2139 nTerms = n; 2140 } 2141 2085 2142 idShow(id, currRing, currRing, nTerms); 2086 2143 } … … 2089 2146 } 2090 2147 else 2091 #endif2148 //#endif 2092 2149 /*==================== mtrack ==================================*/ 2093 2150 if(strcmp(sys_cmd,"mtrack")==0) … … 2104 2161 fd = fopen((char*) h->Data(), "w"); 2105 2162 if (fd == NULL) 2106 Warn("Can not open %s for writing og mtrack. Using stdout"); 2163 Warn("Can not open %s for writing og mtrack. Using stdout"); // %s ??? 2107 2164 } 2108 2165 if (h->Typ() == INT_CMD) -
Singular/iparith.cc
r64a88e rf5da37 2 2 * Computer Algebra System SINGULAR * 3 3 ****************************************/ 4 /* $Id: iparith.cc,v 1.51 2 2009-07-28 14:18:34 SingularExp $ */4 /* $Id: iparith.cc,v 1.513 2009-08-13 17:24:45 motsak Exp $ */ 5 5 6 6 /* … … 2593 2593 static BOOLEAN jjPlural_num_poly(leftv res, leftv a, leftv b) 2594 2594 { 2595 if( currRing->qideal != NULL ) 2596 { 2597 WerrorS("basering must NOT be a qring!"); 2598 return TRUE; 2599 } 2600 2595 2601 if (iiOp==NCALGEBRA_CMD) 2596 2602 { … … 2608 2614 static BOOLEAN jjPlural_num_mat(leftv res, leftv a, leftv b) 2609 2615 { 2616 if( currRing->qideal != NULL ) 2617 { 2618 WerrorS("basering must NOT be a qring!"); 2619 return TRUE; 2620 } 2621 2610 2622 if (iiOp==NCALGEBRA_CMD) 2611 2623 { … … 2623 2635 static BOOLEAN jjPlural_mat_poly(leftv res, leftv a, leftv b) 2624 2636 { 2637 if( currRing->qideal != NULL ) 2638 { 2639 WerrorS("basering must NOT be a qring!"); 2640 return TRUE; 2641 } 2642 2625 2643 if (iiOp==NCALGEBRA_CMD) 2626 2644 { … … 2638 2656 static BOOLEAN jjPlural_mat_mat(leftv res, leftv a, leftv b) 2639 2657 { 2658 if( currRing->qideal != NULL ) 2659 { 2660 WerrorS("basering must NOT be a qring!"); 2661 return TRUE; 2662 } 2663 2640 2664 if (iiOp==NCALGEBRA_CMD) 2641 2665 { -
Singular/mod2.h.in
r64a88e rf5da37 6 6 * DO NOT EDIT! 7 7 * 8 * Version: $Id: mod2.h.in,v 1.14 7 2009-07-28 14:18:35 SingularExp $8 * Version: $Id: mod2.h.in,v 1.148 2009-08-13 17:24:45 motsak Exp $ 9 9 *******************************************************************/ 10 10 #ifndef MOD2_H … … 109 109 #undef HAVE_SIGINTERRUPT 110 110 /* define for boost includes and lib */ 111 #undef HAVE_BOOST_DYNAMIC_BITSET_HPP111 //////////////////////// #undef HAVE_BOOST_DYNAMIC_BITSET_HPP 112 112 /* define for std:vector includes */ 113 113 #undef USE_STDVECBOOL
Note: See TracChangeset
for help on using the changeset viewer.