Uploaded image for project: 'Specification'
  1. SPEC-261

Indicate how accuracy is treated over add/subtract operations in DV_QUANTIFIED types

    Details

    • Type: Change Request
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: Release 1.0.2
    • Component/s: openehr.rm.data_types
    • Labels:
      None
    • Change Description:
      Hide
      The accuracy of an addition or subtraction is the sum of the accuracies of the operands. This is common practice to ensure that the measurement fault in source measurements is propagated into derived values.

      Secondly, to indicate that accuracy was not recorded at all, a special value is used, and a new Boolean function called accuracy_unknown is added, which reports True if the special value occurs. This requires the following changes:

      1. in the class DV_AMOUNT, accuracy_unknown: Boolean is added as a function, and a constant called Unknown_accuracy_value of type Integer, with value = -1 is added. The documentation is changed to indicate that a value of -1, i.e. accuracy = Unknown_accuracy means no accuracy recorded, and the accuracy_unknown function returns True.

      2. The class DV_ABSOLUTE_QUANTITY also has accuracy, but defined as a reference value. The accuracy_unknown function is also implemented in this class, but returns True if accuracy = Void (i.e. null).

      In addition, in the interests of clarifying the modelling, the accuracy and accuracy_unknown features are added to the parent of the two above classes, namely DV_QUANTIFIED. They are defined in this class as abstract, and are only added to indicate logically that the DV_QUANTIFIED concept includes an accuracy concept.
      Show
      The accuracy of an addition or subtraction is the sum of the accuracies of the operands. This is common practice to ensure that the measurement fault in source measurements is propagated into derived values. Secondly, to indicate that accuracy was not recorded at all, a special value is used, and a new Boolean function called accuracy_unknown is added, which reports True if the special value occurs. This requires the following changes: 1. in the class DV_AMOUNT, accuracy_unknown: Boolean is added as a function, and a constant called Unknown_accuracy_value of type Integer, with value = -1 is added. The documentation is changed to indicate that a value of -1, i.e. accuracy = Unknown_accuracy means no accuracy recorded, and the accuracy_unknown function returns True. 2. The class DV_ABSOLUTE_QUANTITY also has accuracy, but defined as a reference value. The accuracy_unknown function is also implemented in this class, but returns True if accuracy = Void (i.e. null). In addition, in the interests of clarifying the modelling, the accuracy and accuracy_unknown features are added to the parent of the two above classes, namely DV_QUANTIFIED. They are defined in this class as abstract, and are only added to indicate logically that the DV_QUANTIFIED concept includes an accuracy concept.
    • Impact Analysis:
      Some small impact on software and XML schemas expected.
    • Approved By:
      ARB

      Description

      Gerke Geurts:
      The DV_AMOUNT and DV_ABSOLUTE_QUANTITY classes contain (optional) accuracy attributes. However the specifications for the outcome of mathematical operations (especially the add/subtract operators) seem to be silent on the accuracy of the results of these operations.

      A further question that then arises, is what to do with values for which the accuracy is +/-0. The OpenEhr spec reserves this values as indicating that the accuracy has not been specified. I take it that the outcome of any mathematical operation on a value with unrecorded/unknown accuracy must have an unrecorded/unknown accuracy itself. However, if that is the case, the calculation of formulas that have constants (which have a true accuracy 0) becomes an issue, because the OpenEhr spec currently does not seem to allow for the representation of values with a +/-0 accuracy.

      Rong:
      While we are on this, maybe we should consider how two precisions (optional attribute of DV_QUANTITY) can be combined as well.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              thomas.beale Thomas Beale
              Raised By:
              Gerke Geurts, Rong Chen
              Analyst:
              (Sam Heard) inactive (Inactive), Rong Chen, Thomas Beale
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Due:
                Created:
                Updated:
                Resolved: