Is there a package for numerical physical constants?

Hi, I am looking for a package that defines common physical constants like the velocity of light, the Boltzmann constant etc. by their numerical value, e.g.,

#let c = 299792458

Does something like that exist already?

Would having all the constants in a json file be sufficient? You could then export the constants from scipy.constants and load them into a dictionary in your Typst project.

It’s rather a reusable solution that I was looking for − to be able to name the constants instead of copy-pasting their value (and maybe messing something up). I only need one or the other from time to time.

This could be a good and pretty simple package if someone wants to make one.

I can’t think of an existing package that would be a good fit for including this. At best physica – Typst Universe, but this one is concerned with displaying things, not scripting.

It would make sense to add this to a units package. Directly being able to display the value, uncertainty and unit (or just one of those) of all the CODATA constants sounds neat. Also having access to the “raw” constants would be easy if they are already in the package anyway.

Do you need the numerical values of the constants to compute something or are you only looking to display the values? Your initial question suggests that you want the speed of light as a numerical value, right?

Yes that’s right, I am just looking for the numerical values (for example to transform data or quickly compute simple quantities). That’s also why I thought it might not fit a package that only deals with displaying things otherwise.