Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Normalisation #5

Open
atmoos opened this issue Apr 23, 2023 · 0 comments
Open

Add Normalisation #5

atmoos opened this issue Apr 23, 2023 · 0 comments
Labels
enhancement New feature or request help wanted Extra attention is needed question Further information is requested

Comments

@atmoos
Copy link
Owner

atmoos commented Apr 23, 2023

Add a Normalise(): String method.

Scenario: Say you have a length instance of 78'167 μm. This is an unwieldy representation for humans to read. More natural forms of the same length would be 78.167 mm or 7.817 cm, where the latter value has been rounded.

Tasks:

  • Find a good name for that method ("Normalised", "DisplayValue", "HumanReadable", etc. could be other names)
  • Decide whether the value should or should not be rounded to max. three digits
  • Find an implementation that efficiently computes the normalization for values in the metric system
  • For the imperial system decide whether:
    • To not implement this functionality
    • To convert the value to a metric value that can be normalised
    • To convert the value to the "best" representation within the same system (This may open up a can of worms...)

Note also the example in the readme: 3'456 Km/d => 40 m/s

  • Is that a good normalization? (people are more used to Km/h)
  • Compound Quantities will be hard to reasonably normalise...
@atmoos atmoos added enhancement New feature or request help wanted Extra attention is needed question Further information is requested labels Apr 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant