Uploaded image for project: 'FHIR Specification Feedback'
  1. FHIR Specification Feedback
  2. FHIR-35915

Clairfy interval computation semantics with open null boundaries

    XMLWordPrintableJSON

Details

    • Icon: Technical Correction Technical Correction
    • Resolution: Persuasive
    • Icon: Medium Medium
    • Clinical Quality Language (FHIR)
    • 1.5
    • Clinical Decision Support
    • Language Semantics
    • Hide

      Agreed, apply clarification as suggested.

      In addition, clarify in the description of interval open boundaries that:

      • When the low boundary is open and null, it represents the uncertain range from the minimum value for the point type to the high boundary (inclusive).
      • When the high boundary is open and null, it represents the uncertain range from the low boundary (inclusive) to the maximum value for the point type.

      In addition, correct this test:

      <test name="TestMeetsAfterNull">

        <expression>Interval(null, 5] meets after Interval[11, null)</expression>

        <output>null</output>

      </test>

      To result in "false"

      Show
      Agreed, apply clarification as suggested. In addition, clarify in the description of interval open boundaries that: When the low boundary is open and null, it represents the uncertain range from the minimum value for the point type to the high boundary (inclusive). When the high boundary is open and null, it represents the uncertain range from the low boundary (inclusive) to the maximum value for the point type. In addition, correct this test: <test name="TestMeetsAfterNull">   <expression>Interval(null, 5] meets after Interval[11, null)</expression>   <output>null</output> </test> To result in "false"
    • Correction
    • Non-substantive

    Description

      Clarify that interval computations involving open null boundaries can also make use of uncertainty, by adding the following to the Interval Operators section of Language Semantics:

       


      Note that open null boundaries of intervals are treated as uncertainties for the purposes of interval computation. For example:

          intersect Interval[1, 10] intersect Interval[5 null)

      This results in an interval that begins at 5, and ends at some value between 5 and 10. Implementations can accomplish this by normalizing open intervals to closed intervals with uncertain boundaries:

          If interval.low is null then interval.low = Uncertainty(minimumValue, interval.high)
          If interval.high is null then interval.high = Uncertainty(interval.low, maximumValue)


       

      Add examples and test cases to validate the behavior:

      These should both evaluate to true:

          define TestIntervalNull1: end of (Interval[1, 10] intersect Interval[5, null)) <= 10
          define TestIntervalNull2: end of (Interval[1, 10] intersect Interval[5, null)) >= 5

      And these should both evaluate to false:

          define TestIntervalNull3: end of (Interval[1, 10] intersect Interval[5, null)) > 10
          define TestIntervalNull4: end of (Interval[1, 10] intersect Interval[5, null)) < 5

       

      This is a technical correction on the grounds that the JavaScript reference implementation already behaves this way.

      Attachments

        Activity

          People

            Unassigned Unassigned
            bryn.rhodes Bryn Rhodes
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: