{
"$type": "site.standard.document",
"bskyPostRef": {
"cid": "bafyreigrumhvnt66dijjkq5h32l2mwxi5qtjecajdzovnvkzh36iy7jr3y",
"uri": "at://did:plc:pi6woz4d47bkuws673w2il2r/app.bsky.feed.post/3mltjy7ixmee2"
},
"path": "/t/knownnat-indexed-vectors/14099?page=2#post_24",
"publishedAt": "2026-05-14T19:00:09.000Z",
"site": "https://discourse.haskell.org",
"tags": [
"comfort-array"
],
"textContent": "mixphix:\n\n> Are there `Num` instances for any of these Finite types?\n\nIs the product of two rings a ring? If not, there should not be such an instance in general. `Finite n` can be a field if `n` is prime, if I am not mistaken. But why would you want a `Num` instance on the index set anyways?\n\nmixphix:\n\n> This approach has the advantage that it doesn’t “segfault” if indexing past the length\n\nIf you are not striving for type-safe indexing, why pursue this approach at all?\n\nI forgot to mention Henning Thielemann’s linear algebra ecosystem with lapack, comfort-array and its shapes.",
"title": "KnownNat-indexed vectors"
}