Skip to content

Reconcile IPhysicalQuantity / PhysicalQuantity surface with strategy doc and CLAUDE.md #59

@matt-edmondson

Description

@matt-edmondson

Summary

IPhysicalQuantity.cs and PhysicalQuantity.cs are minimal: a Value property and an IsPhysicallyValid shape, with no per-dimension validation, no dimension/base-unit metadata accessors, no In(unit) conversion, and no uncertainty support. Several pieces of documentation imply more.

Evidence

  • Semantics.Quantities/IPhysicalQuantity.cs:1-27 — minimal interface.
  • Semantics.Quantities/PhysicalQuantity.cs:16-32 — exposes Value; no validation hook.
  • docs/design-semantic-quantities.md and docs/strategy-unified-vector-quantities.md reference Dimension, BaseUnit, In(unit), IsPhysicallyValid, WithUncertainty, Magnitude() (the latter is actually emitted on Vector1+).
  • CLAUDE.md mentions a polished public API including PhysicalConstants.Generic.*<T>() and dimensional analysis on operators.

Suggested next step

Decide which surface is canonical for the unified-vector branch:

  1. Trim docs back to match the slim runtime interface, or
  2. Extend IPhysicalQuantity / PhysicalQuantity with the documented members (Dimension metadata, In(unit) conversion, validation hook), backed by tests.

Either way, write down the resulting contract in docs/architecture.md so the generator templates can target it deterministically.

Area / Severity

Quantities / Docs · incomplete

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions