You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A few months ago I've created a new package to provide physical constants: https://github.com/JuliaPhysics/PhysicalConstants.jl This package uses Unitful.jl and defines a new type which is mostly based on my proposal at #81. In order to be able to automatically use a Constant object in mathematical operations, I think it would be great to have an AbstractQuantity type here, that can be subclassed by PhysicalConstants.jl (see JuliaPhysics/PhysicalConstants.jl#2). Quantity would be another concrete subtype of AbstractQuantity. I don't think the change would be very disruptive, it'd only be necessary to define the interface of AbstractQuantity and use it throughout this package (rather than accessing named fields).
The text was updated successfully, but these errors were encountered:
It'd be good to have a getter function for the val field just as a nicer interface than a.val. This function would be semantically different from ustrip, and probably won't be exported, I don't expect users to need it.
Apart from this, I think this ticket can be closed.
A few months ago I've created a new package to provide physical constants: https://github.com/JuliaPhysics/PhysicalConstants.jl This package uses
Unitful.jl
and defines a new type which is mostly based on my proposal at #81. In order to be able to automatically use aConstant
object in mathematical operations, I think it would be great to have anAbstractQuantity
type here, that can be subclassed byPhysicalConstants.jl
(see JuliaPhysics/PhysicalConstants.jl#2).Quantity
would be another concrete subtype ofAbstractQuantity
. I don't think the change would be very disruptive, it'd only be necessary to define the interface ofAbstractQuantity
and use it throughout this package (rather than accessing named fields).The text was updated successfully, but these errors were encountered: