too much stored in cache tables?
Nobody has claimed this yet.
- Dominant language
- Macaulay2
- Stars
- 435
- Forks
- 297
- Avg merge
- 4d 20h
- Merged PRs (30d)
- 11
Description
David Eisenbud has pointed out that in some respects M2 is not as close to a functional language as it could be:
i1 : M = ZZ^1 ++ ZZ^2
3
o1 = ZZ
o1 : ZZ-module, free
i2 : N = ZZ^2 ++ ZZ^1
3
o2 = ZZ
o2 : ZZ-module, free
i3 : M===N
o3 = true
i4 : M^[1]===N^[1]
o4 = false
i5 : M^[1]==N^[1]
o5 = false
i6 : M^[1]
o6 = | 0 1 0 |
| 0 0 1 |
2 3
o6 : Matrix ZZ <--- ZZ
i7 : N^[1]
o7 = | 0 0 1 |
1 3
o7 : Matrix ZZ <--- ZZ
The issue is what information should enter into determining whether X===Y
in general. If we want to get as close as possible to a functional language, then for
any function f, we'd prefer X===Y to imply f X===f Y. The failure of that was what was
surprising for David, and the function "memoize" is built on that principle.
Should we audit everything in all cacheTables, and move items that affect behavior not related to timing of computations outside of them?
If adopted, it would mean, for example, that Hom(R^1,M)===M is false but Hom(R^1,M)==M is true.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No source files or tests are named. Start by reproducing the M2 examples involving M, N, ===, ==, and memoize, then inventory the referenced cacheTables and determine which stored values affect behavior beyond computation timing. Done requires an agreed rule for cache contents and a defined audit scope.
Written by the indexing model from the issue text.
Assessment
- Domain
- tooling
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100