All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
7.2.0 - 2026-02-11
-
Add static factory methods
QuantityValue.of(value, unit)with various value argument types that can be used to instantiate theBigDecimalvalue used internally. -
Add dynamic factory methods in
Unit.quantityValue(value)with various value argument types that can be used to instantiate theBigDecimalvalue used internally. -
Add delegate methods for many
BigDecimalmethods toQuantityValueto allow for mathematical operations with automatic unit conversion, for example:QuantityValue mVal = Qudt.Units.M.quantityValue(20); QuantityValue ftVal = Qudt.Units.FT.quantityValue(1); QuantityValue mValResult = mVal.add(ftVal);
- Fix wrong definition of
Quantity. It used to encapsulate a Set ofQuantityValue, which never made sense. With this change, it encapsulates aQuantityValueand aQuantityKind, conforming to the definition of the concept in QUDT. - Upgrade various dependencies.
7.1.1 - 2025-10-09
7.1.0 - 2025-09-01
- Bump QUDT version to 3.1.5
- Exclude all language-specific labels except
enanden-USas their number has increased prohibitively for QUDTLib' current architecture.
- Recently, the packaging of the
qudtlibartifact was changed topom, which caused its tests not to be run any more. This is now fixed by explicitly binding the execution ofsurefire:testto thetestphase.
7.0.1 - 2025-07-25
Unit.convert()andUnit.getConversionMultiplier(Unit)now strip any trailing fractional zeros and the scale of the result is >= 0.
7.0.0 - 2025-07-22
Unit.dependents- the number of units that refer to that unit as one of its factor units or are scaled from that base unit. this value is required to achieve better sorting inQudt.derivedUnitListFromFactorUnits, allowing to prefer more important units (those with more dependents)
- when using
qudtlibas a dependency, you have to add<type>pom</type>(see updatedeREADME.md). This is due to more rigorous artifact checks by sonatype that prevent jar artifacts without sources. - Upgrade to QUDT 3.1.4
- Calculation of scalings and factor units now happens in QUDT (see PR 1129)
However, a few things have changed:
- rename
qudt:isScalingOftoqudt:scalingOf - rename
qudt:factorUnit/qudt:unittoqudt:hasFactorUnit/qudt:hasUnit
- rename
- Currency units have changed:
- they were moved back into the graph 'http://qudt.org/vocab/unit/'
- their localnames have received the prefix
CCY_ - both changes are 'soft', ie, the old way is still available, but deprecated
- for example:
http://qudt.org/vocab/currency/EURis nowhttp://qudt.org/vocab/unit/CCY_EUR. - QUDTLib makes the change now instead of adopting the deprecation, as there are other breaking changes as well, so upgrading will require work anyway.
- for QUDTLib constants, this means that the pattern
${CurrencyName}_Currencyis dropped in favor of the QUDT styleCCY_${CurrencyName}, e.g.Qudt.Units.EUR_CurrencybecomesQudt.Units.CCY_EUR
- Many conversion multipliers were changed in QUDT. They now consistently have at most 34 significant digits (ie, BigDecimal's precision of 34). This fixes problems such as the one reported in Conversion error from MilliSV__PER__HR to MicroSV__PER__HR.
- scalings of
unit:GMdeserve special mention:- in the upcoming QUDT release we have
unit:GM qudt:scalingOf unit:KiloGM, makingqudt:scalingOfandqudt:conversionMultiplierconsistent in all cases - QUDTLib makes the change as well, with the effect that unit factorization does not use
Units.GM(which probably surprised a few people) for the mass dimension butUnits.KiloGM(which is what one would expect)
- in the upcoming QUDT release we have
- Sorting in
Qudt.derivedUnitListFromFactorUnitsnow takes more aspects into account and ordering has changed in some cases. - When creating a Unit instance, its factor units are checked for factors
x^N^M, where x has no more factors. Such factors are simplified as x^(N*M). The same is applied to newly instantiatedFactorUnitsobjects.
- Calculation of scalings and factor units now happens in QUDT (see PR 1129)
However, a few things have changed:
- Fixed a sorting bug in
Qudt.derivedUnitListFromFactorUnitsthat caused wrong sorting for some very similar units.
6.8.1 - 2025-01-29
- Add quantitykind constants for those quantitykinds that are defined in the currency file in QUDT.
6.8.0 - 2024-12-11
- Add
Unit.altSymbols - Add
Qudt.parseUnit() - Add unit index structures in
Qudtto improve performance of unit searches and factor unit matching
- Bump QUDT version to 2.1.46
6.7.0 - 2024-04-04
- Bump QUDT version to 2.1.37
6.5.0 - 2024-03-17
- Add model classes PhysicalConstant and ConstantValue, populate from data.
- Add tool for generating the decimal/scientific values for QUDT
- Add description to
Unit, QuantityKind and PhysicalConstant(i.e. the string value ofdcterms:description)
- Update to qudt-public-repo@16f1b30
- Handle TemperatureDifference edge case (ignore offset when converting)
6.4.3 - 2024-02-20
- Add units
unit:KiloGM-PER-PA-SEC-M,unit:M2-K-PER-W,KiloM2,CentiM4
- Improve qudtlib-tools for contributions to QUDT
6.4.2 - 2024-02-20
6.4.1 - 2024-02-08
6.4.0 - 2024-02-08
boolean Unit.generated()method indicating whether a unit was generated during the QUDTLib build process (and is therefore not in QUDT)- Added two units and a quantity kind pending upstream PR merging
- New class
io.github.qudtlib.QudtMainForDebugginginqudtlib-main-rdfthat can be used for thread-debugging the non-hardcoded static initializer when other methods fail. FactorUnits.getConversionMultiplierOptobtains the multiplier only if all factor units have one, instead of falling back to using 1.0.
- Bump qudtlib version to 2.1.35
- Refactoring and extensions of qudtlib-tools to keep up with incoming changes and slowly working toward a state in which the tools can be used in github actions for correctness checks.
- Factor units can now be sorted for a given unit IRI, resulting in symbols being generated with expected ordering of factors.
- Data generation input files have been renamed for consistency
6.3.0 - 2024-02-03
Qudt.unitsFrom*methods for obtaining units that match a given specification expressed via factor units.FactorUnits FactorUnits.withoutScaleFactor()to get the FactorUnits object with scaleFactor 1.
Qudt.unitsFromFactorUnitshas been changed to give highest priority to units with factorUnits equal to the requested ones.
Qudt.derivedUnitsFrom*have been deprecated. The implementations have become slower. The alternatives are listed in the code comments. The replacing methods have been renamed to fit better with the other unit-related methods and returnList<Unit>instead ofSet<Unit>. The reason is that the list is sorted according to match quality, which helps clients to choose the best after filtering.
6.2.0 - 2024-01-11
- Simplified BEST_MATCH algorithm for obtaining a unit from a set of factor units. Recent additions to the data model (scalingOf and factorUnit relationships) led to a larger set of candidates and the complexity of the previous algorithm led to very high computation time.
- Changed the behaviour of Unit.hasFactorUnits() such that for a FactorUnits object with only one top-level factor unit (such as [N^1]), the method returns false.
unit:MHO,unit:MicroMHO: fix dimension vector and quantity kindunit:F: fixunit:scalingOf
6.1.0 - 2024-01-05
- Josh Feingold(@occamsystems) contributed the ability to add units and quantity kinds at runtime, along with a number of improvements
6.0.3 - 2023-12-20
- Created CONTRIBUGING.md
- Bugfix by Josh Feingold(@occamsystems): Offset difference and scale difference no longer throw exceptions when the provided Units do not have explicit conversion values
6.0.2 - 2023-12-18
6.0.1 - 2023-12-18
6.0.0 - 2023-12-15
- Add (crude) tools for inspecting QUDT units/quantitykinds and for generating triples for unit/quantitykind contributions
- Add simple SHACL validation for contribution
- Add some units/quantitykinds for the construction domain
- Generate all possible localnames from factor units for checking if one of them is used for a unit
- Add Unit.getIriLocalname()
- Add member ucumCode with getters/setters and builder
- Add setFactorUnits() to Unit.Definition
- Add Qudt.currencyFromLocalname()
- Add Qudt.isBroaderQuantityKind()
- Add FactorUnits.getDimensionVectorIri()
- Add inspection of Factor unit tree in qudtlib-tools
- Make getSymbol() return Optional
- handling of currency units such that they can now also be factor units
- Exclude unit:Kilo-FT3 from QUDTLib because it breaks unit localname parsing
- Implement a not so recent change in QUDTLib whereby quantitykinds are no longer skos:broader but
qudt:exactMatch in certain conditions. See #61. The change
adds an
exactMatchproperty to theQuantityKindandUnitclasses and uses the exactMatch property where appropriate in algorithms. - Improve quantitykind extraction query
- Fix use of Unit constructor
5.0.1 - 2023-09-21
quantitykind:Currencywas missing in 5.0.0. Its definition was moved to the currencies file in the QUDT repo which used to be ingested only for units code generation. Now it is also used for quantity kinds code generation.
5.0.0 - 2023-09-15
- Updated QUDT to v2.1.29
4.3.0 - 2023-03-10
- Added currency symbols for major currencies
4.2.0 - 2023-03-03
- Add qudt namespace to Qudt.NAMESPACES
- Updated QUDT to v2.1.25
4.1.0 - 2023-02-13
- Corresponding unit in system functionality - finds the best matching units to a given unit in a desired unit system, such as the corresponding unit for inch in the SI system (centimeter).
4.0.0 - 2023-02-07
- SystemOfUnits as a model class
- Several manual links from units to their base units or factor units
- BREAKING: Made QUDTlib data model immutable, changed instantiation to force use of builders.
3.1.0 - 2023-01-20
- Temporarily added quantitykinds
PositivePlaneAngle, NonNegativeLength, PositiveLength and Countuntil upstream upstream PR 630 and upstream PR 631 are released.
- Updated QUDT to v2.1.24
3.0.2 - 2022-12-06
- Add quantity kinds for positive dimensionless ratio and normalized dimensionless ratio temporarily until the canges from the upstream PR are released.
3.0.1 - 2022-12-01
- Fix bug in unit comparison
3.0.0 - 2022-11-30
- Add QuantityKinds and Units required to map IFC to QUDT. These are added temporarily until an upstream release of QUDT.
- BREAKING: Modify the selection of units matching a set of factor units. The matching algorithm as well as the scoring algorithm of matching units was adapted. With this change, there are only two options for the client: get all matching units or get the one that matches best.
- Upgrade to QUDT v2.1.22. All data temporariy added via
/qudtlib-data-gen/src/main/resources/triples-to-add-to-(units|quantitykinds).ttlwhile waiting for PRs to be released upstream have been removed.
2.2.0 - 2022-10-28
- Update QUDT to 2.1.21
- Improve the release process on GitHub
2.1.1 - 2022-10-25
- Add triples missing in Qudt v2.1.20 temporarily until the upstream fix is released.
- All
(add|set).+methods ofUnit,QuantityKind, andPrefixnow require non-null parameters. Not performing this check led to a bug in QUDT v2.1.20 to slip through.
2.1.0 - 2022-10-24
- Update QUDT to 2.1.20
- Fix MW/mW derivation bug (#27) by adding missing QUDT triples manually (until the upstream fix is released)
2.0.1 - 2022-10-21
- Improve Changelog handling during release
2.0.0 - 2022-10-20
- Add module
qudtlib-js-gen, which generates Typescript code to instantiate units, quantitykinds and prefixes forqudtlib/qudtlib-js - Add project
qudtlib-jsas a git submodule to allow the build process to generate javascript into that project - Add
Qudt.*requiredstatic methods that return e.g.Unit, notOptional<Unit>and throw an Exception if there is nothing to return.
- A number of breaking changes without prior deprecations, sorry about that.
- Upgrade to QUDT v2.1.19
- Move any code from
Qudtto model classes (Unit,QuantityValue, etc.) if the code does not directly depend on pre-instantiated units. - Refactor
Qudt.*static methods to returnOptionals where appropriate - Made
Qudt.convert(BigDecimal, Unit, Unit)returnBigDecimal(was:QuantityValue) whileQudt.convert(QuantityValue, Unit)still returns aQuantityValue. It's cleaner: you get what you provide. - Refactor factor unit matching (fixing some bugs in the process)
- Fix errors in RDF generation
- Fix errors in generation of constants (such as
Qudt.Units.M) - Improve unit tests
- Change
toString()methods in a number of model classes for better readability - Upgrade dependencies to latest versions
- Remove unused code
- Initial release.