{
"$type": "site.standard.document",
"bskyPostRef": {
"cid": "bafyreigzugbnzirqmyubcrz2kofa3oajjzifkpn224gn7ilta22iu3f3ta",
"uri": "at://did:plc:pi6woz4d47bkuws673w2il2r/app.bsky.feed.post/3mgysbfxesmf2"
},
"path": "/t/sneak-peek-bolt-math/13766#post_14",
"publishedAt": "2026-03-13T17:35:46.000Z",
"site": "https://discourse.haskell.org",
"textContent": "I guess I’m not entirely convinced by your argument that you need a heterogeneous foundation? Many of the mathematical structures we work with are homogenous, with a few exceptions. And we usually describe non-homoegeonous operations as actions! I think `numhask` does it quite nicely: `Additive` is homogeneous, and for the non-homogeneous case you have `AdditiveAction`.\n\nTo give an example, we work a lot with typed unit values using the `units` package, which are ultimately newtypes over `Double`. A typed quantity like `Length` is additive, but has a `MultiplicativeAction` with `Double`, so you can do `mm 2 *. 4` and so on. And in the same way we can use `linear` and give vectors actions over `Double` and so on. It works pretty well in practice.\n\nI’d be interested to see an example of where you need non-homogeneousness that _isn’t_ cleanly describable as an action?",
"title": "Sneak Peek: Bolt Math"
}