1 /* -*- mode:C++ ; compile-command: "g++-3.4 -Wall -I.. -g -c cocoa.cc" -*- */ 2 /* Copyright (C) 2000,2014 B. Parisse, Institut Fourier, 38402 St Martin d'Heres 3 * 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License as published by 6 * the Free Software Foundation; either version 3 of the License, or 7 * (at your option) any later version. 8 * 9 * This program is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 * GNU General Public License for more details. 13 * 14 * You should have received a copy of the GNU General Public License 15 * along with this program. If not, see <http://www.gnu.org/licenses/>. 16 */ 17 18 #ifndef _GIAC_COCOA_H_ 19 #define _GIAC_COCOA_H_ 20 #include "first.h" 21 #include "gausspol.h" 22 #include "gen.h" 23 #include "solve.h" 24 // GIAC_64VARS is currently compatible with GROEBNER_VARS 15 only 25 // special code for polynomial up to 11 variables (max deg<32768) 26 //#define GROEBNER_VARS 11 27 #define GROEBNER_VARS 15 28 #define GIAC_REDUCEMODULO // reduce initial input only at modular step 29 30 #ifndef NO_NAMESPACE_GIAC 31 namespace giac { 32 #endif // ndef NO_NAMESPACE_GIAC 33 34 bool f5(vectpoly &,const gen & order); 35 bool cocoa_gbasis(vectpoly &,const gen & order); 36 vecteur cocoa_in_ideal(const vectpoly & g,const vectpoly & v,const gen & ordre); 37 bool cocoa_greduce(const vectpoly & r,const vectpoly & v,const gen & order,vectpoly & res); 38 39 #if !defined CAS38_DISABLED && !defined FXCG 40 // giac code for poly (fast up to 15 variables) 41 struct order_t { 42 short o; 43 unsigned char dim; 44 unsigned char lex; 45 }; 46 47 bool gbasis8(const vectpoly & v,order_t & order,vectpoly & res,environment * env,bool modularalgo,bool modularcheck,int & rur,GIAC_CONTEXT,gbasis_param_t gbasis_param); 48 bool greduce8(const vectpoly & v,const vectpoly & G,order_t & order,vectpoly & res,environment * env,GIAC_CONTEXT); 49 longlong memory_usage(); 50 #endif 51 52 #ifndef NO_NAMESPACE_GIAC 53 } // namespace giac 54 #endif // NO_NAMESPACE_GIAC 55 56 #endif // _GIAC_COCOA_H 57