Project

General

Profile

Feature #1235

FreeModule: get canonical basis

Added by John Abbott over 5 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Normal
Category:
New Function
Target version:
Start date:
11 Dec 2018
Due date:
% Done:

100%

Estimated time:
1.75 h
Spent time:

Description

It would be helpful to have a function which produces a standard basis for a FreeModule (in the expected order).

History

#1 Updated by John Abbott over 5 years ago

The function gens for a submodule of a freemodule produces a set of generators (but with no special guarantees).
There should also be a function which produces a list of module elements being the standard basis for a freemodule.

It should be fairly trivial to implement.

#2 Updated by Anna Maria Bigatti over 5 years ago

Two ideas:
1 - basis(FM);
2 - gens(FM); (with a comment in the manual saying that, for a FreeModule, returns the standard basis)

#3 Updated by John Abbott over 4 years ago

  • Target version changed from CoCoALib-0.99650 November 2019 to CoCoALib-0.99700

#4 Updated by John Abbott over 4 years ago

  • Target version changed from CoCoALib-0.99700 to CoCoALib-0.99800

#5 Updated by John Abbott over 2 years ago

If we want a special fn for getting the standard/canonical basis for a free module then it could be called CanonicalBasis; this fn would throw if the arg is not a free module.

Probably gens applied to a free module should return the canonical basis, but I'm unsure whether we should state this in the documentation.

An advantage of a new special fn is that whoever is reading the code knows that the arg should/must be a free module; whereas if the code calls gens then whoever is reading the code cannot "clearly assume" that the arg is a free module (at least, not based on this fn call).

#6 Updated by John Abbott over 2 years ago

  • Subject changed from FreeModule: get a standard basis to FreeModule: get canonical basis
  • Status changed from New to In Progress
  • % Done changed from 0 to 20

Agreed: the proposal in comment 5 is accepted.

To clarify the order of the elements in the canonical basis should be as expected: namely, (1,0,0,0,...), (0,1,0,0,...), etc

Arg type should be FreeModule (const ref, probably)

#7 Updated by Anna Maria Bigatti over 2 years ago

  • Assignee set to Anna Maria Bigatti

#8 Updated by John Abbott about 2 years ago

  • Status changed from In Progress to Resolved
  • % Done changed from 20 to 80

I have made a trivial impl (& written short doc).
Must also make available from CoCoA-5 (with doc).

#9 Updated by John Abbott about 2 years ago

  • Status changed from Resolved to Closed
  • % Done changed from 80 to 100
  • Estimated time set to 1.75 h

All done. Closing.

Also available in: Atom PDF