Support #290
Which functions are defined in CoCoALibSupplement?
Description
Note for AMBigatti: explain the philosophy of what goes where.
Related issues
History
#1 Updated by Anna Maria Bigatti about 11 years ago
- Subject changed from Witch functions are defined in CoCoALibSupplement? to Which functions are defined in CoCoALibSupplement?
#2 Updated by Anna Maria Bigatti about 11 years ago
- Project changed from CoCoALib to CoCoA-5
- Category deleted (
Documentation) - Target version deleted (
CoCoALib-0.99534 Seoul14)
#3 Updated by Anna Maria Bigatti about 11 years ago
- Category set to Parser/Interpreter
- in BuiltinOneLiner.C only functions using the "one-line" definition
This also includes the functions likeDECLARE_COCOALIBFORC5_FUNCTION1(BlahBlah,..)
callingBlahBlah_forC5
defined in CoCoALibSupplement
- in BuiltinFunctions.C just the minimal interface from interpreter to CoCoALib, no mathematics
- in CoCoALibSupplement what "is missing" in CoCoALib to be called from BuiltinFunctions or BuiltinOneLiners
Example: we want SetEntry in CoCoA-5 to be almost the same as SetEntry in CoCoALib, except:
- in CoCoALib (as in C++) indexing start from 0, in CoCoA-5 (as in CoCoA-4) from 1
- in CoCoALib indexes are long, in CoCoA-5 are INT (BigInt)
See SetEntry in BuiltinFunctions.C and SetEntry_forC5 in CoCoALibSupplements.C
#4 Updated by Anna Maria Bigatti about 10 years ago
- Target version set to CoCoA-5.1.0 Easter14
#5 Updated by John Abbott about 10 years ago
- Target version changed from CoCoA-5.1.0 Easter14 to CoCoA-5.1.1 Seoul14
#6 Updated by Anna Maria Bigatti over 9 years ago
- Status changed from New to In Progress
- Target version changed from CoCoA-5.1.1 Seoul14 to CoCoA-5.?.?
- % Done changed from 0 to 20
#7 Updated by Anna Maria Bigatti about 9 years ago
Part of the definition of IsFactorClosed in BuiltInFunctions should be moved into CoCoALibSupplement (I will do it soon)
#8 Updated by Anna Maria Bigatti over 7 years ago
Many functions in CoCoALibSupplement are just there because they need conversion from BigInt to long (or vector of BigInt to vector of long). Now there are functions to do this directly (VectorLong, VectorLongDecr1,...) in BuiltinFunctions, so CoCoALibSupplement could be made lighter.
#9 Updated by Anna Maria Bigatti over 7 years ago
- Related to Design #929: Clean up CoCoALibSupplement added
#10 Updated by Anna Maria Bigatti about 5 years ago
CoCoALibSupplement
currently contains some functions for external libraries, e.g.
#ifdef CoCoA_WITH_NORMALIZ long NmzVerbosityLevel_forC5(); matrix NmzHilbertBasis_forC5(ConstMatrixView M); std::vector<RingElem> NmzNormalToricRing_forC5(const std::vector<RingElem>& ppv); std::vector<RingElem> NmzIntClosureToricRing_forC5(const std::vector<RingElem>& ppv); std::vector<RingElem> NmzIntClosureMonIdeal_forC5(const std::vector<RingElem>& ppv); #endif // CoCoA_WITH_NORMALIZ
This was indeed an idea of mine, but I now believe those functions should be defined directly in
BuiltInFunctions-Normaliz.C
, reducing the number of files to modify when adding an external library, and the files to include in BuiltInFunctions-XXX.C
.#11 Updated by Anna Maria Bigatti about 5 years ago
Anna Maria Bigatti wrote:
CoCoALibSupplement
currently contains some functions for external libraries, e.g.
[...]
This was indeed an idea of mine, but I now believe those functions should be defined directly inBuiltInFunctions-Normaliz.C
, reducing the number of files to modify when adding an external library, and the files to include inBuiltInFunctions-XXX.C
.
Done, tested, works. I like it.