Toward a metrology-information layer for digital systems ACTA IMEKO ISSN: 2221-870X March 2023, Volume 12, Number 1, 1 - 4 ACTA IMEKO | www.imeko.org March 2023 | Volume 12 | Number 1 | 1 Toward a metrology-information layer for digital systems Mark J. Kuster1 1 Independent Researcher and Consultant, Dumas, Texas, USA Section: RESEARCH PAPER Keywords: M-Layer; quantities; measurement units; measurement information infrastructure (MII); digital metrology Citation: Mark J. Kuster, Toward a metrology-information layer for digital systems, Acta IMEKO, vol. 12, no. 1, article 18, March 2023, identifier: IMEKO- ACTA-12 (2023)-01-18 Section Editor: Daniel Hutzschenreuter, PTB, Germany Received November 21, 2022; In final form January 7, 2023; Published March 2023 Copyright: This is an open-access article distributed under the terms of the Creative Commons Attribution 3.0 License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original author and source are credited. Corresponding author: Mark J. Kuster, e-mail: mjk@ieee.org 1. INTRODUCTION The international system of units and quantities [1], [2] and documents such as [3] define the basic references and nomenclature that supports most world measurements and quantitative specifications. This system, though not comprehensive, has served science and commerce well. Metrology’s digital transformation, as BIPM has recognized [4], requires a digital system to represent quantities and units. Simple digitization, however, does not suffice for digital transformation. To digitize, digitalize, and transform, metrology should rethink its practices from the ground up in order to identify and eliminate the suboptimum pragmatic elements that, if propagated into automated systems, undercut the full gains that digital transformation promises. Quantities and units lie at the ground level so we start there. Digital quantity-unit systems face multiple realities—that if accounted for in the beginning will smooth and enhance digital transformation—including 1. both SI and non-SI measurement units, 2. exceptional measurement scales, 3. measurand ambiguity that challenges automated data consumption, 4. nonlinear unit conversions, 5. restricted operations by scale type. In [5], the authors proposed a metrology-information layer (an M-Layer), to standardize a universal digital quantities and units system without altering the human systems in use. Conceptually, the M-Layer generalizes measurement “unit” (and the VIM’s “reference” [6]) to “scale” and similarly generalizes “quantity” to “aspect” as denoted in [7]. The M-Layer would allow any measurement unit (reality 1) on any scale (reality 2), introduce an aspect identifier <q> to disambiguate quantities and facilitate machine-actionable (MA) documents (reality 3), provide for arbitrary conversion functions between scales (reality 4), and capture the meaningful operations among scales (reality 5). This generalization unites all digital measurement data under a single methodology. Without such innovations, metrology laboratories and other measurement producers and consumers will inevitably encounter measurements that require some ad hoc data in digital documents that their customers’ software may or may not consume automatically, not to mention the rest of the world. Subsequent work [8] has sketched an M-Layer structure but published no detailed models. This paper presents work on an M-Layer prototype model in Section 2. Section 3 discusses some results with example applications and Section 4 concludes with a summary and indicates prospective future work. 2. M-LAYER MODELING In human-readable documents, quantity values appear with two components: q, the numeric value, and [Q], the unit symbol, as in 2.446 mm, for say, an outside diameter. People rely on a textual quantity description or the context to determine the actual measurand. Because that methodology fails for machine processing, the M-Layer would extend the representation with a ABSTRACT Recent work has proposed a metrology-information layer (M-Layer) to support digital systems with quantities and units by addressing the difficulties conventional quantity-unit systems pose for digitalization. This paper reports the work toward developing the M-Layer’s current abstract conceptualization into a concrete model, working prototype, and demonstration software, with the final goal to create a FAIR (findable, accessible, interoperable, reusable) resource. mailto:mjk@ieee.org ACTA IMEKO | www.imeko.org March 2023 | Volume 12 | Number 1 | 2 third element that uniquely identifies the aspect (generalized quantity kind) in MA documents as 𝑞[𝑄] → 𝑞[𝑄]⟨𝑞⟩ (1) or in our example, 2.446 mm <length> [5], where <length> represents an aspect-identifying code discussed later. However, machines do not require multiple units per quantity, base-derived unit distinctions, or prefixes for internal processing or communication. Therefore, an M-Layer aspect may associate with one and only one unprefixed unit, in which case the aspect would uniquely determine the unit and a measurement-software application might drop the unit entirely from the data. This means digital systems may simplify the data and carry q<q> in computations without ambiguity or loss of generality. In our example, the data would simply contain 2.446 × 10−3<length>, assuming M-Layer documentation declares the SI9 [1] meter, e.g., as the M-Layer length unit. The data model should then allow digital systems to render this in the expected form— outside diameter, 2.446 mm—using any unit and aspect alias the user prefers. The M-Layer representation suffices for processing of digital measurement data, including all calculations, uncertainty propagation, etc. Widely interoperable MA documents, however, require more metadata to describe the measurand in order to automatically match measurement data in instrument specifications, calibration and measurement capabilities, calibration results, calibration requests, and other digital documents that organizations may wish to exchange. The MII (measurement-information infrastructure) taxons [9] would fulfill this requirement unless and until the M-Layer incorporates such aspect qualifiers, something not currently envisioned. For example, the taxon Measure.Length.Diameter.Outside, in which the second element Length links to the aspect <length>, provides the metadata to make a digital outside-diameter value fully interoperable (neglecting qualifiers for influence quantities). The M-Layer’s core therefore comprises unambiguous aspect definitions. Table 1 illustrates a model to capture the useful data elements. The elements AspectID and Name provide the core functionality. The ScaleTypeID-indexed data helps define the meaningful operations on the aspect. Definition would aid users to distinguish one aspect from another and Symbol identifies the aspect’s default math symbol for symbolic processing. Unlisted elements such as Nature (intrinsic, extrinsic, …) and Dimension would add value but the M-Layer goals do not immediately require them. The M-Layer model will also allow sourcing one or more data elements from existing systems such as ontologies [11] or unique reference points such as the Digital SI Brochure. Ideally, the AspectID representing <q> would comprise a lightweight persistent identifier (PID). For example, the M-Layer might identify itself and its contents via a DOI (digital object identifier) [12]. As shown in Figure 1, owners may structure their DOIs as desired. The DOI’s owner-chosen suffix structure allows a hierarchical pointer that would identify, for example, the M-Layer registry; the Aspects dataset; and a particular aspect. For Aspects, the short EntryID then becomes AspectID, and when combined with a numerical value would both disambiguate the measurand and reduce the data size in digital documents relative to other proposals. The DOIs would easily expand to accommodate the MII taxon structure as well. The DOI’s permanence as a PID ensures M-Layer availability regardless of any changes in the organization or web site hosting the registries. A number of other datasets would supplement or complement the M-Layer; these may include datasets to register quantity-unit systems for rendering user results, scale types, base dimensions, aspect aliases (alternate quantity names) and aspect relations. If an M-Layer implementation omits any of these supplementary datasets, dependent systems and applications may augment the core M-Layer accordingly or, as previously mentioned, follow M-Layer pointers to existing systems. We omit details here due to space and the model’s current fluidity— the reader may find further information at [13] as it develops— but briefly mention the most germane points. Potential ancillary datasets: QuantitySystems and UnitSystems register systems such as Imperial, U.S. Customary, natural, CGS systems, as well as previous and future SI versions. The Units and UnitAspects datasets associate all units of interest (for user interfaces) with the correct aspect and provide symbolic conversion expressions to and from the aspect’s M-Layer- declared unit, e.g., the SI9 equivalent. To simplify the data model and client application logic, prefixed units may have their own data entries. This would allow easy unit conversions and rendering as users desire. ScaleTypes and ScaleOperations register scales (ratio, interval, cyclic or modular, logarithmic, ordinal, nominal, empirical) and their data types and operations. As an example multi-scale operation, an interval quantity added to a compatible ratio quantity yields a ratio quantity. Though neither sufficient nor required for disambiguation, BaseDimensions would define the basis for dimensional analysis. Finally, an AspectRelations dataset might contain mathematical expressions relating aspects, e.g., Ohm’s Law. An MA-document scheme that propagated mathematical expressions for measurement models and results might start from here. As a distributed resource, the M-Layer may comprise any number of separate registries. Some national metrology institutes Table 1. Aspects data model. Data Element Description Example AspectID unique identifier-index representing the aspect <q> in MA documents and data <length> Name registered name length Symbol mathematical symbol markup (e.g., LaTeX, MathML [10]) l Definition textual description or external pointer PID to unique reference point ScaleTypeID index to the aspect’s scale type RatioScaleID Figure 1. A DOI-based scheme for M-Layer PIDs. The top two DOIs identify articles in two different journals, each of which has designed their own DOI structure. The bottom DOI shows one choice for M-Layer PIDs, allowing separate registries, each with a number of identified datasets containing identified entries. ACTA IMEKO | www.imeko.org March 2023 | Volume 12 | Number 1 | 3 may wish to establish M-Layer registries to link local or legacy measurement units to the M-Layer SI registry. Likewise, standards bodies, industry associations and common-interest communities may wish to register and digitally define unique aspects, scales, units and relationships. The M-Layer model also envisions an access interface such as an API, which would define a number of operations, such as retrieving a registry for local use. This would complete the M- Layer as a FAIR data source. 3. DISCUSSION This section discusses some benefits of the M-Layer. 3.1. Disambiguation Metrologists involved in digital transformation have begun to realize that quantity values as numeric value and unit do not suffice for automated consumption; nor do accompanying free- text measurand descriptions solve the problem. NCSL International’s MII initiative set up a test-bed database organized around quantities [14] and later initiated a measurand taxonomy project to begin addressing measurand ambiguity. The M-Layer would extend this capability beyond ratio quantities in order to handle, for example, the ordinal quantity hardness, modular angle quantities, temperature quantities on interval, ordinal, ratio, and special scales, etc. Aspect IDs of course automatically resolve such problems as disambiguating dimensionless quantities (all using the implied unit 1) or other quantities denoted in the same unit (e.g., torque and work). So though digital documents would record for example 1.00 <torque> or 1.00 <work>, both render to the same conventional form, 1.00 N m, if so desired in an application, though preferably labeled with the quantity name or MII taxon. Dimensionless quantities would work likewise, as each would have its own Aspects entry. For example, digital systems rendering the text “turns ratio, r: 200” or “amplifier gain A: 200” would do so from digital data containing 200 ⟨turnsratio⟩ and 200 ⟨gain⟩. The M-Layer would also have the option of adding base dimensions such as angle A for rotational quantities, though again, the M-layer does not rely on dimensional analysis. 3.2. Simplified data processing With the M-Layer, digital document producers may remain ignorant of the customer’s preferred units and simply embed the M-Layer representations because the customer may render the values as desired or simply pass them to other digital systems. Documents that the producer converts to PDF form for the customer may do likewise. Computations using M-Layer data may ignore measurement units and proceed as with dimensionless quantities, then simply attach the appropriate aspect ID to the final result before embedding the value in a document or otherwise communicating it. The system may ignore alternate unit systems, prefixes, and other pragmatisms because the M-Layer’s units would implicitly correspond to a declared SI edition such as [1], or other standards for which the SI provides no equivalent, e.g., hardness. As a simple example, an application without M-Layer support might perform a simple period-to-frequency calculation as 𝑓 = 1 𝑇 = 1 (1 ms)⁄ = 1000 Hz = 1 kHz , (2) which with the M-Layer would reduce to 1/(0.001 <period>) = 1000 <frequency>. (3) The latter operation both carries more information (aspect) and simplifies processing. Many software systems therefore would require no refactoring to handle quantities properly (defining quantity-value classes, for example, and overloading their operators to deal with dimensions). Also, having an AspectRelations dataset available in the M-Layer would help standardize metrological computations–for example to provide commonly used expressions such as moist-air density. 3.3. Unit conversions The usual unit conversions of course remain trivial with an M-Layer. User interfaces would translate conventional notations to and from M-Layer representations but all intermediate processing and communications between M-Layer-aware systems would entail no conversions. This M-Layer model includes symbolic conversion functions to eliminate precision-limited conversion constants. Thus, digital systems using sufficiently precise, arbitrary-precision, or symbolic computations for all operations would introduce no further errors or uncertainty into results, at least up to a user interface. Hence, a system may postpone numeric conversions until required by encoding them symbolically as, e.g., LaTeX or MathML. An angle value, for example might digitalize as equation (4)’s right hand side, 44.234° = 44.234 𝜋 180 < planeangle >, (4) where the symbolic conversion expression 𝑥 𝜋 180 comes from the M-Layer Units dataset entry for degree and assumes the SI radian as the M-Layer angle unit. Similarly, conversion functions allow arbitrary scale conversions such as 𝐿 𝑥 𝑥0 = log ( 𝑥 𝑥0 ) , (5) which converts from a dimensionless ratio-scale quantity to a logarithmic-scale level quantity. 3.4. Scale handling The M-Layer would handle scale conversions similarly to unit conversions. Since every AspectID associates with a unique ScaleTypeID, we may facilitate conversions and corrections between empirical scales. For example, we might add the aspect <1990ConventionalVoltage> and the appropriate scale entry based on the conventional Josephson constant 𝐾𝐽−90 with a scale-conversion entry such as 𝐾𝐽−90𝑥 𝐾𝐽 , where 𝐾𝐽 = 2 𝑒 ℎ with constants e and h defined to match the declared M-Layer references, e.g. SI9 [1]. This would allow automated systems to easily correct past (digital) measurement data according to new definitions. Figure 2 exemplifies such a voltage-scale conversion via a demonstration application that takes advantage of a prototype registry containing aspect relations to automatically look up conversion equations and compute results. The M-Layer would likewise define other empirical scales, such as the ITS-90 temperature scale and mercury-based temperature scales [3] for various atmospheric pressures in order to capture the differences from their associated SI-defined aspects. ACTA IMEKO | www.imeko.org March 2023 | Volume 12 | Number 1 | 4 Defining ordinal scales would bring such quantities as hardness into the same digital system without requiring ad hoc modifications and data representations. Modular scales would handle angular quantities when restricting values to a certain range, such as 0°to 360°. From these examples, the reader will see the potential that M-Layer opens to digital transformation. 4. CONCLUSION This paper has presented initial steps toward modeling and prototyping an M-Layer to support FAIR digital measurement data and systems. For human-readable documents, the M-Layer changes nothing, except perhaps to facilitate their generation. By replacing unit symbols and textual measurand descriptions with unique aspect IDs, the M-Layer concept offers machine- readability, global interoperability, and generalized quantities (aspects) and units (scales) to handle all types of measurements in digital documents and measurement software systems. In collaboration with international partners, the NCSL International 141 MII and Automation Committee plans to continue developing the M-Layer model and populating a prototype with intention to replace the MII test-bed quantities and units database for use in digital documents. In cooperation with industry partners, we have begun drafting use cases, a product definition and requirements from the user viewpoint, an open-source prototype registry with back-end software, and demonstration applications. As the MII committee continues its collaboration with the international quality infrastructure, the M- Layer should become a FAIR data resource. ACKNOWLEDGEMENT The Author would like to thank NCSL International, the NCSL International 141 MII and Automation Committee, and Cherine Marie-Kuster for their support. REFERENCES [1] The International System of Units (SI), International Bureau of Weights and Measures (BIPM) Information Document SI Brochure, 9th edition, 2019. Online [Accessed 26 March 2023] https://www.bipm.org/en/publications/guides/ [2] Quantities and units, International Standardization Organization (ISO) and International Electrotechnical Commission (IEC) Std. ISO-IEC 80000, first edition, 2006-2011. [3] The international system of units (SI) —conversion factors for general use, NIST, Washington, DC, Special Publication 1038 (2006). Online [Accessed 26 March 2023] https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublica tion1038.pdf [4] Bureau international des poids et mesures (BIPM), The international system of units (SI) in digital communication. CIPM Task Group on the Digital SI (2020). Online [Accessed 26 March 2023] https://www.bipm.org/en/conference-centre/bipm- workshops/digital-si/ [5] B. D. Hall, M. J. Kuster, Metrological support for quantities and units in digital systems, Measurement: Sensors 18 (2021). DOI: 10.1016/j.measen.2021.100102 [6] Joint Committee for Guides in Metrology (JCGM) Guidance Document JCGM 200:2012, The international vocabulary of metrology - Basic and general concepts and associated terms (VIM), Rev. 3rd edition, 2012. Online [Accessed 26 March 2023] https://www.bipm.org/utils/common/documents/jcgm/JCGM _200_2012.pdf [7] S. S. Stevens, On the theory of scales, Science 103(2684) (1946), art. No. 2684, pp. 677–680. DOI: 10.1126/science.103.2684.677 [8] B. D. Hall, M. J. Kuster, Representing quantities and units in digital systems, Measurement: Sensors 23 (2022), art no.100387. DOI: 10.1016/j.measen.2022.100387 [9] Cal Lab Solutions and NCSLI141 MII & Automation Committee, Metrology taxonomy. Online [Accessed 26 March 2023] http://www.metrology.net/home/metrology-taxonomy/ [10] WC3, Mathematical markup language (MathML). World Wide Web Consortium (W3C). Online [Accessed 26 March 2023] https://www.w3.org/Math/ [11] Semantic specifications for units of measure, quantity kind, dimensions and data types. Quantity, Unit, Dimension and Type (QUDT). Online [Accessed 26 March 2023] http://www.qudt.org/ [12] Information and documentation—Digital object identifier system, International Standardization Organization (ISO) Std. ISO 26 324:2012, 2012. [13] M. J. Kuster, B. D. Hall, R. White, M-Layer registry prototype. NCSLI 141 MII & Automation Committee (2022). Online [Accessed 26 March 2023] http://miiknowledge.wikidot.com/local--files/wiki:mii-projects/ [14] D. Zajac, Creating a standardized schema for representing ISO/IEC 17025 scope of accreditations in XML data, Proc. NCSL Int. Workshop & Symposium. St. Paul, MN: NCSL International, 24-28 July 2016. Online [Accessed 26 March 2023] http://miiknowledge.wikidot.com/local--files/wiki:mii- reference-data- sources/NCSLI%202016%20Zajak%20XML%20SoA%20Paper. pdf Figure 2. Screen shot from a demonstration application using a prototype M- Layer registry. From AspectIDs tied to the input aspect (1990 Conventional Voltage), output aspect (SI9 voltage) and variables in an AspectRelations table, the software automatically locates the applicable conversion equations and computes the result to any desired precision. The application displays AspectIDs using aspect symbols: action <S>, charge <Q>, frequency- voltage coefficient <cfV>, etc. The application shows the M-Layer representations for information only. https://www.bipm.org/en/publications/guides/ https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication1038.pdf https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication1038.pdf https://www.bipm.org/en/conference-centre/bipm-workshops/digital-si/ https://www.bipm.org/en/conference-centre/bipm-workshops/digital-si/ https://doi.org/10.1016/j.measen.2021.100102 https://www.bipm.org/utils/common/documents/jcgm/JCGM_200_2012.pdf https://www.bipm.org/utils/common/documents/jcgm/JCGM_200_2012.pdf https://doi.org/10.1126/science.103.2684.677 https://doi.org/10.1016/j.measen.2022.100387 http://www.metrology.net/home/metrology-taxonomy/ https://www.w3.org/Math/ http://www.qudt.org/ http://miiknowledge.wikidot.com/local--files/wiki:mii-projects/ http://miiknowledge.wikidot.com/local--files/wiki:mii-reference-data-sources/NCSLI%202016%20Zajak%20XML%20SoA%20Paper.pdf http://miiknowledge.wikidot.com/local--files/wiki:mii-reference-data-sources/NCSLI%202016%20Zajak%20XML%20SoA%20Paper.pdf http://miiknowledge.wikidot.com/local--files/wiki:mii-reference-data-sources/NCSLI%202016%20Zajak%20XML%20SoA%20Paper.pdf http://miiknowledge.wikidot.com/local--files/wiki:mii-reference-data-sources/NCSLI%202016%20Zajak%20XML%20SoA%20Paper.pdf