Uploaded image for project: 'Commons Math'
  1. Commons Math
  2. MATH-754

Additional Fraction Constructor

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Won't Fix
    • 3.0
    • 3.0
    • None
    • All

    Description

      I'm writing some code which outputs fractional measurements meant for human consumption. I need a constructor for Fraction which allows you to restrict the denominators to a finite set. This is necessary due to the fact that real-world tools are only available with certain fractions. For example, it's next to impossible to find a ruler with 1/7 inch marked .

      I'm attaching a patch which implements the functionality. I've attempted to mimic the style of the existing code as much as possible. One caveat: I don't speak French so the french error message is a computer-generated translation and probably very poor.

      Attachments

        1. math.patch
          8 kB
          Travis Hanna

        Activity

          People

            Unassigned Unassigned
            thanna Travis Hanna
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: