Opened 2 years ago

Closed 2 years ago

#30254 closed enhancement (fixed)

TensorFreeModule._an_element_: Create a default basis in the base module if necessary

Reported by: Matthias Köppe Owned by:
Priority: major Milestone: sage-9.2
Component: linear algebra Keywords:
Cc: Eric Gourgoulhon, Travis Scrimshaw, Michael Jung Merged in:
Authors: Matthias Koeppe Reviewers: Eric Gourgoulhon
Report Upstream: N/A Work issues:
Branch: eec19fd (Commits, GitHub, GitLab) Commit: eec19fd6d722ebc27f0f559b1d473f4409c09d72
Dependencies: Stopgaps:

Status badges

Description

Likewise for ExtPowerFreeModule etc.

The current code creates an element without components if the base module has no default basis. Such elements are not useful for running the test suite because adding them gives a "no common basis" error.

That currently all tests work depends in a subtle way on the order in which modules are created.

In this ticket, we propose to change the _an_element_ method to create a default basis in the base module if none already exists -- this matches what FiniteRankFreeModule._an_element_ already does.

This will simplify further refactoring of the code, such as the identification of modules discussed in #30241.

Change History (7)

comment:1 Changed 2 years ago by Matthias Köppe

Branch: u/mkoeppe/tensorfreemodule__an_element___create_a_default_basis_in_the_base_module_if_necessary

comment:2 Changed 2 years ago by git

Commit: d2d7f425ee4a33c9030d9bc8b08228762e042886

Branch pushed to git repo; I updated commit sha1. New commits:

d2d7f42ExtPowerDualFreeModule._an_element_: Make sure a default basis is available

comment:3 Changed 2 years ago by git

Commit: d2d7f425ee4a33c9030d9bc8b08228762e042886eec19fd6d722ebc27f0f559b1d473f4409c09d72

Branch pushed to git repo; I updated commit sha1. New commits:

9e739e5FreeModuleLinearGroup._an_element_: Make sure a default basis is available
eec19fdTensorFreeModule._an_element_: Make sure a default basis is available

comment:4 Changed 2 years ago by Matthias Köppe

Authors: Matthias Koeppe
Status: newneeds_review

comment:5 Changed 2 years ago by Eric Gourgoulhon

Reviewers: Eric Gourgoulhon
Status: needs_reviewpositive_review

Thanks for fixing this!

comment:6 Changed 2 years ago by Matthias Köppe

Thanks!

comment:7 Changed 2 years ago by Volker Braun

Branch: u/mkoeppe/tensorfreemodule__an_element___create_a_default_basis_in_the_base_module_if_necessaryeec19fd6d722ebc27f0f559b1d473f4409c09d72
Resolution: fixed
Status: positive_reviewclosed
Note: See TracTickets for help on using tickets.