Open mkoeppe opened 2 years ago
Description changed:
---
+++
@@ -2,3 +2,4 @@
We make this method available for `CombinatorialFreeModule` too via `ModulesWithBasis`.
+For ambient modules, `dict` and `monomial_coefficients` give the same result. We enforce this with a `_test_...` method.
Description changed:
---
+++
@@ -2,4 +2,4 @@
We make this method available for `CombinatorialFreeModule` too via `ModulesWithBasis`.
-For ambient modules, `dict` and `monomial_coefficients` give the same result. We enforce this with a `_test_...` method.
+For ambient modules, `dict`, `items`, and `monomial_coefficients` give the same result. We enforce this with a `_test_...` method.
Description changed:
---
+++
@@ -2,4 +2,6 @@
We make this method available for `CombinatorialFreeModule` too via `ModulesWithBasis`.
+Add a method `items`, with the same semantics as for sparse vectors from `sage.modules`, and matrices and tensor components after #29619. If `self` is a submodule, they refer to the ambient module (see #34455).
+
For ambient modules, `dict`, `items`, and `monomial_coefficients` give the same result. We enforce this with a `_test_...` method.
Description changed:
---
+++
@@ -3,5 +3,7 @@
We make this method available for `CombinatorialFreeModule` too via `ModulesWithBasis`.
Add a method `items`, with the same semantics as for sparse vectors from `sage.modules`, and matrices and tensor components after #29619. If `self` is a submodule, they refer to the ambient module (see #34455).
+Likewise `nonzero_positions`, which gives the indices only.
-For ambient modules, `dict`, `items`, and `monomial_coefficients` give the same result. We enforce this with a `_test_...` method.
+For ambient modules, `dict`, `items`, and `monomial_coefficients` give the same result, and `support` and `nonzero_positions` are the same. We enforce this with a `_test_...` method.
+
Removed branch from issue description; replaced by PR #37524.
FreeModule
(fromsage.modules
) has a methodis_ambient
for distinguishing ambient modules from submodules.We make this method available for
CombinatorialFreeModule
too viaModulesWithBasis
.Add a method
items
, with the same semantics as for sparse vectors fromsage.modules
, and matrices and tensor components after #29619. Ifself
is a submodule, they refer to the ambient module (see #34455). Likewisenonzero_positions
, which gives the indices only.For ambient modules,
dict
,items
, andmonomial_coefficients
give the same result, andsupport
andnonzero_positions
are the same. We enforce this with a_test_...
method.CC: @tscrim
Component: linear algebra
Issue created by migration from https://trac.sagemath.org/ticket/34511