# Changelog

## 1.2.0 - 2026-11-20

- Adds passive pressure-loss elements with explicit adiabatic or prescribed-heat
  closure, and optional imposed losses or specific heat for single-stream heat
  exchangers. Pressure, drop and ratio routes are exclusive; existing outlets
  are checked. Combined thermal/loss paths are schematic and unspecified entropy
  transfer remains unavailable. Isobaric defaults and prior component results
  are preserved. These additive APIs introduce no further migration requirement
  relative to CTAN 1.1.1; the cumulative migration table below still applies.

- Consolidates the Lua API reference and documentation build guide under
  `doc/luatex/luacoolprop/`, with their existing filenames. Links and distribution
  paths are updated; the runtime API and numerical results are unchanged.

- Adds adiabatic liquid pumps and turbines with explicit isentropic efficiency,
  phase validation, ideal reference outlets and signed work/power. Documents a
  steam Rankine cycle in PH and TS with common calculated states. Supports
  saturated-liquid pump inlets and equilibrium wet turbine outlets within the
  stated domains, without inferring cavitation margins or droplet losses.

- Adds explicit steady-flow compressor, valve, isobaric heat-exchange and custom
  component models to named constructions. Requires compressor efficiency and
  optional mass flow explicitly; exposes signed specific-energy balances,
  powers and explicit balance tables. Marks nonideal/custom endpoint connectors
  as schematic and leaves unspecified entropy production unavailable.

- Adds scoped named SI states, reusable conserved-property processes and closed
  cycles. Draw the same construction in PH, PV, TS, HS and PT; retrieve SI values,
  projected coordinates, logs and explicit tables without redefining endpoints.
  Keeps model values distinct from graphical readings and validates connectivity,
  conservation, ownership, units and reference conventions.

- Opens the manual with first figures, everyday customization and full
  PGFPlots/Lua control. Adds a key-family map, task recipes and inspectable
  document-owned worksheet, solution and monochrome styles. Demonstrates
  override order and grouping in LaTeX, plain TeX and ConTeXt MkIV.

- Installs generic TeX loaders under `tex/luatex/luacoolprop/` and all Lua
  components under its `lua/` subdirectory. Keeps documentation under
  `doc/luatex/luacoolprop/`; checks isolated installations in all three formats.

- Detects the actual CoolProp binary and selects reviewed bindings/capabilities
  for the pinned 8.0.0b1, 8.0.0 and 8.0.1dev identities. Adds `library_info()`
  diagnostics and records adapter/ABI/capabilities in caches and table provenance.
  Explicit library selections now fail without silently falling back elsewhere.
- Corrects C string-status handling, parameter descriptions and debug-level
  forwarding; validates configuration names/types against the detected revision.

- Resolves fluid aliases through CoolProp's canonical identity before selecting
  or locking enthalpy and entropy references. Keeps process/table metadata and
  cache provenance consistent across aliases. Restricts managed references and
  diagrams to HEOS rather than silently applying HEOS offsets to other backends.

- Adds explicit diagram/process table exports for all five projections, with
  SI metadata, native/source provenance, round-trip precision and domain gaps.
  Documents TikZ externalization and independent PGFPlots table consumption.
- Verifies cached and uncached critical tails, disconnected domains, endpoint
  macros and exported tables across compiler processes and TeX formats.

- Adds optional numerical caching for PH, PV, TS, HS and PT curves and
  processes, with off, read-write, refresh and strict read-only policies.
  Preserves domain gaps, process exports and warning messages; fingerprints
  runtime/native dependencies and keeps label placement at rendering time.

- Separates the Lua runtime into private modules behind the stable public
  facade. Keeps native resources, state validation, sampling, projections,
  serialization, and the TeX bridge in distinct components; installs all Lua
  components together in the TDS runtime directory.

- Uses unframed notes and warnings with native PGF manual typography.
- Extracts README previews directly from marked figures in the compiled manual,
  with reproducible cropping and stale-image checks before packaging.
- Raises errors for unknown package keys in all three TeX formats while
  preserving documented aliases and native PGFPlots options. Checks structured
  key contracts and compiles their configuration examples in the manual.

### Compatibility and migration from CTAN 1.1.1

This section compares version 1.2.0 with the published CTAN version **1.1.1**. Public TeX command names, documented aliases, the five diagram
identifiers and their coordinate-unit defaults remain available. The following
changes can require action even though most figure sources need no editing.

| Area | Previous behavior and change in 1.2.0 | Migration |
| --- | --- | --- |
| Installation and paths | The single Lua file is now a facade requiring adjacent private modules. Runtime TeX files are in `tex/luatex/luacoolprop/`, Lua files in its `lua/` directory, and manual sources/PDF in `doc/luatex/luacoolprop/`. A missing component fails instead of borrowing a different installed version. | Install the complete runtime tree; remove obsolete copies that shadow it. Replace scripts using root-relative `luacoolprop.lua` or `luacoolprop-manual.tex` paths. Normal `\usepackage`, plain/ConTeXt loaders and Kpathsea-based Lua loading keep their names. |
| Native versions and ABI | Loading an arbitrary CoolProp binary is no longer accepted merely because the dynamic loader opens it. The version **and embedded Git revision** must match a reviewed identity, with required symbols and a supported 64-bit data model. | Use one of the exact supported builds listed below. A different snapshot with the same version string needs validation and an updated adapter registry; there is no user `compat` switch to bypass it. |
| Explicit library selection | An invalid explicit `library`, `LUACOOLPROP_LIB` or `COOLPROP_LIB` used to fall through to later candidates. The first nonempty selection is now authoritative. A request to switch an already loaded binary is rejected. | Correct or remove a stale selection before starting the engine. Start a fresh compiler process to change binaries or recover from a rejected native identity. |
| Unknown package keys | Unknown setup, diagram or process keys could be ignored; they now stop compilation. Documented aliases remain supported. | Correct spelling and use a key supported by that projection. Put native PGFPlots options in `axis options` or the appropriate documented drawing-style key, rather than inventing package keys. |
| Fluid aliases and references | Reference selections/locks were keyed by the user's fluid spelling. Equivalent aliases now share one canonical identity and one lock. Reading a reference can require native identity resolution. | Select the reference once, before any calculation for that fluid, regardless of alias. Do not use an alias to change an already locked reference. Recompute outputs that previously mixed reference conventions. |
| Managed backends | Managed diagrams and reference-state operations now accept only HEOS (unprefixed, `HEOS::`, or the native default prefix `?::`). Other prefixes could previously reach a non-HEOS model while applying HEOS reference changes. | Use a pure HEOS fluid for the managed API. Deliberate other-backend calculations belong in the low-level native wrappers with their own reference-state handling. |
| Native string/configuration wrappers | Failed string queries previously could return an empty string because the C success status was misread. They now raise an error. `parameter_information_string` correctly requests the long description; setters reject unknown or wrong-type configuration keys for the detected revision and report native errors. | Handle errors at the application boundary rather than testing an empty result. Use `library_info().capabilities.configuration_keys` to select a supported setter. Existing valid setter signatures are unchanged. |
| Explicit native buffers | Buffer lengths are now checked as integer byte counts from 1 to 16777216; parameter descriptions require at least 5 bytes. | Omit the length for the 4096-byte default, or supply a valid integer sized for the native result. |
| Internal Lua tables | Underscored implementation tables/helpers, including `_strict` and private PT helpers, are no longer exposed by the facade. They were not supported public extension points. | Use the documented `diagram`, `process`, state and native-wrapper interfaces; do not load private components directly. |
| Distributed developer tools | Tests, release/submission tools and local maintenance notes no longer belong to the curated user distribution. | Use the shipped user build helpers to rebuild documentation. Test and release automation are not installed package interfaces. |

Supported native identities in this release are CoolProp `8.0.0b1`
(`322000f4ddab06fcdf94488b7bfd782f01a0783d`), `8.0.0`
(`ae81610e7d23efc57f9d051c8e70a4d66e87537f`) and the reviewed `8.0.1dev`
snapshot (`6de0bf8c5164e415814bda3d7313e81d201fab07`). A version name alone is
insufficient. See the README and Lua API reference for discovery and diagnostics.

Scientific corrections can change numerical coordinates or reference metadata
for documents that previously mixed aliases/backends. Rebuild derived tables,
externalized pictures and any manually saved results after correcting such
inputs. Numerical caching and table export are new, opt-in facilities;
caching defaults to `off` and introduces no required persistent files.

Named models are additive and introduce no further default behavior change
relative to CTAN 1.1.1. Existing explicit process commands remain supported.
Install the complete runtime, including `luacoolprop-models.lua`,
`luacoolprop-models-tex.lua` and `luacoolprop-components.lua`. Component and
balance commands are additive: they introduce no additional default behavior
break relative to CTAN 1.1.1 and do not assign heat/work to existing geometric
processes. Pump and turbine types are additive, with no additional break relative
to CTAN 1.1.1 and no change to existing compressor/valve/heat-exchanger results.
Nonideal compressors, pumps, turbines and custom components draw dashed schematic
endpoint connectors unless explicitly restyled. Runtime fingerprints invalidate numerical caches;
rebuild them before using strict read-only mode. There is no automatic conversion
of existing TikZ intersections into model states.

The getting-started chapters and document-owned style recipes introduce **no
additional runtime compatibility break**. They do not change default sampling,
units, label placement or the package's public commands. Decimal-dot input,
rejection of mixtures for diagrams, and unsupported-family errors already
belonged to 1.1.1; they are not new restrictions in 1.2.0. Autonode's separate
1.0.0-to-1.1.0 migration notes apply when updating that dependency.

## 1.1.1 - 2026-09-20

- Makes the independently distributed `pgfplots-autonode` package a required
  runtime dependency instead of embedding a second package in LuaCoolProp.
- Removes autonode implementation files, standalone documentation, examples,
  and tests from the LuaCoolProp CTAN and TDS archives.
- Tests the integration against a separately supplied
  `pgfplots-autonode.tds.zip`; the label library now has its own repository,
  release workflow, documentation, and test suite.

## 1.1.0 - 2026-09-18

Public GitHub release following the limited 1.0.0 distribution. All diagrams,
tutorials, and package examples are generated from LuaCoolProp sources and an
external CoolProp shared library; the reference exercise files are not shipped.

This historical release distributed the independent `pgfplots-autonode`
library alongside LuaCoolProp. The label-library changes listed below refer
to that separately developed library, not to LuaCoolProp's implementation.
Since 1.1.1 it is installed and distributed separately; its own repository and
manual are the reference for its implementation and documentation.

- Adds reproducible README previews generated from the methane and butane
  tutorial PDFs, plus two complete quick-start PH examples.
- Adds CoolProp's scientific citation to the reference manual,
  README, and Lua API documentation.
- Keeps exercise reference scans, PDFs, and screenshots out of the source and
  release manifests; tutorial files use descriptive names.
- Updates the then co-distributed `pgfplots-autonode` library with fixes for
  label-state initialization across consecutive PGFPlots axes and exact
  disconnected-path endpoints, plus multi-axis and endpoint regression fixtures.

- Adds a native PT (pressure--temperature) diagram with a logarithmic pressure
  axis; one rigorously sampled pure-fluid liquid--vapour coexistence curve from
  exact triple to critical endpoints; optional isentropes, isenthalps, and
  isochores; all shared process projections; semantic axis units; stable named
  curves; LaTeX, plain TeX, and ConTeXt examples; and indexed reference
  documentation.
- Releases the maintained LPPL 1.3c-or-later package under Christophe
  Jorssen's maintainership with synchronized release metadata.
- Produces deterministic CTAN browsing and TDS archives, normalizes file modes,
  and tests an installed TDS tree with LuaLaTeX, plain LuaTeX, ConTeXt MkIV,
  and standalone pgfplots-autonode.
- Stops changing the user's PGFPlots compatibility level and unrelated axes;
  automatic label-placement hooks are local to LuaCoolProp-created axes or
  explicitly enabled by users of the low-level API.
- Marks common critical endpoints as quality-independent graphical limits;
  vapor quality remains explicitly undefined at the critical state.
- Makes critical-region quality sampling genuinely adaptive in logarithmic
  reduced pressure for PH, PV, TS, and HS; the configured tolerance and
  recursion limit now govern the added high-pressure samples instead of a
  fixed epsilon table.

- Makes PH, PV, TS, and HS peers of one capability-checked diagram registry;
  unsupported background-family switches now fail while every projection
  retains all process-path types.
- Adds semantic axis-unit keys which couple numerical conversion to the
  generated label, including a genuine Celsius offset on linear TS axes; raw
  scale keys now advertise scaled SI coordinates.
- Preserves disconnected valid CoolProp domains as separate segments, emits
  PGFPlots jumps, exposes topology metadata, and adds configurable omitted-
  sample diagnostics.
- Exposes and locks CoolProp's `DEF`, `IIR`, `ASHRAE`, and `NBP` enthalpy/
  entropy reference conventions during initialization and records the active
  convention in process metadata and TeX fluid constants.
- Enforces a pure-fluid boundary for all diagram operations while retaining
  mixture support in the low-level Lua wrappers.
- Rejects thermodynamically inconsistent overdetermined states and process
  endpoints by validating every explicit property and each conserved process
  quantity against the canonical state resolved by CoolProp, with quantitative
  diagnostics and documented absolute/relative tolerances.
- Makes numeric, unit, list, grid-mode, preset, boolean, and explicit-bound
  parsing strict and locale independent. Numeric input now requires `.` as its
  decimal separator and accepts decimal scientific quantities such as
  `1.2E5Pa`; invalid input is never silently replaced, discarded, or repaired.
- Adds a native linear HS (mass-specific-enthalpy--mass-specific-entropy)
  diagram type with fluid-independent qualities, isochores, isotherms, and
  entropy-parameterised isobars; exact critical and two-phase handling; all
  six process paths; Water examples for LaTeX, plain TeX, and ConTeXt; and
  exhaustive indexed TeX and Lua documentation.
- Adds a native linear TS (temperature--mass-specific-entropy) diagram type
  with fluid-independent quality curves, canonical critical closure,
  constant-mass-specific-enthalpy backgrounds, all six process paths,
  format-generic TeX commands, structured Lua renderers, examples for LaTeX,
  plain TeX, and ConTeXt, and exhaustive indexed reference documentation.
- Adds an expert methane Linde-liquefaction teaching pair: a regenerated PH
  worksheet, six progressive correction views, coupled separator/regenerator/
  mixer balances, three-stage compression and cooling, live state exports,
  signed powers, and comparison with coarse graphical estimates.
- Adds a shared-source R1234yf swimming-pool heat-pump teaching pair: a dense
  PH worksheet, intersection-defined four-state solution cycle, saturation-
  derived operating pressures, industrial first-law discussion, process-fed
  state chaining, and an automated signed condenser-power calculation.
- Expands numeric process-export macros inside subsequent `from` and `to`
  state specifications, allowing reproducible process chains without copying
  intermediate CoolProp values while keeping TeX labels and styles protected.
- Adds a five-stage butane PV teaching tutorial: a reusable worksheet,
  phase-region and critical-state
  reading, ideal-gas comparison, intersection-defined tank state, isochoric
  heating path, and endpoint-derived numerical results.
- Fixes process-state completion so derived properties continue to use the
  original independent CoolProp pair; this resolves two-phase PV isochores
  whose target is specified by temperature after volume has been inferred.
- Documents official CoolProp download and reproducible source-build workflows
  for macOS, Linux, and Windows while keeping every dependency checkout and
  binary outside the CTAN package tree.
- Documents independent-validation requirements and native-library trust
  guidance.
- Adds an explicit warning that full `--shell-escape` is required to expose the
  LuaTeX FFI module but grants dangerous external-command capabilities to the
  complete TeX document and all of its dependencies.
- Adds a native log-log PV (pressure--specific-volume) diagram type with
  quality curves, isotherms (including exact two-phase plateaux), isentropes,
  all process paths, multi-fluid critical closure tests, format-generic TeX
  commands, and exhaustive reference examples.
- Adds an extensible diagram registry with generic TeX dispatch commands and a
  structured Lua API; PH and PV are the built-in diagram types.
- Standardizes new PH documents on uppercase diagram names and the `quality`,
  `isotherm`, `isentrope`, `isochore`, and `process` vocabulary.
- Keeps the earlier mixed-case commands, abbreviated keys, and flat Lua
  functions as compatibility aliases.
- Makes the ConTeXt wrapper use the native PGFPlots frontend and format-aware
  Lua file resolution, including ConTeXt's e-TeX primitive aliases.
- Builds and tests LaTeX, plain TeX, and ConTeXt examples with `lualatex`,
  `luatex`, and ConTeXt MkIV respectively, with logs kept by the build script.
- Uses the independent PGFPlots `autonode` library for automatic label
  placement; that library retained its package and direct-loader entry points.
- Uses the independent library's diagnostics for labels registered without
  the mandatory `auto node placement` lifecycle, fixes the dense manual-axis
  showcase, and verifies that its solve and render hooks run in LaTeX, plain
  LuaTeX, and ConTeXt.
- Includes updates to the independent label library's per-label overlap
  weights, numerical-option validation, and geometric regression coverage
  for borders, rotations, priorities, collision models, failure handling,
  and axis-state isolation.
- Distributes the independent autonode library's standalone examples for
  LaTeX, plain TeX, and ConTeXt alongside the LuaCoolProp examples.
- Adds an extensive Lua developer reference covering the complete public API,
  SI units, errors, FFI resource ownership, structured diagram records, future
  diagram registration, the TeX bridge, and compatibility boundaries.
- Documents every public CoolProp wrapper and managed `AbstractState` method in
  the Lua source with LDoc-compatible contracts.
- Runs a standalone `texlua` smoke test for the documented metadata, property,
  managed-state, PH curve, process, and PGFPlots serialization APIs.
- Adds an exhaustive English TeX reference with a documented example for every
  public command and key, live source/result showcases, precise defaults,
  accepted values, aliases, units, sampling controls, and process-state syntax.
- Includes the independent `pgfplots-autonode` library's own user reference,
  covering standalone LaTeX, plain TeX, and ConTeXt loading, all per-label and
  axis keys, solver algorithms, failure policies, diagnostics, and examples.
- Generates independent command and key/value indexes reproducibly with
  `makeindex` as part of `scripts/build-examples.sh`.
- Adds LuaCoolProp documentation-coverage checks and numerical regression
  tests, alongside the independent PGFPlots label library's own tests.
- Adds `scripts/test.sh` as the complete validation entry point for shell
  portability, public-reference coverage, Lua behavior, all three TeX formats,
  examples, and the indexed manual.
- Adds an explicit release manifest and deterministic archive builder that
  excludes CoolProp sources, binaries, logs, and transient TeX files.
- Adds an extensive instructor-oriented R717 refrigeration-machine tutorial,
  with a shared-source blank worksheet, annotated model solution, thermodynamic
  state table, process construction, energy balance, dimensional checks, and
  reproducible source/result diagrams.
- Publishes process endpoint coordinates through opt-in TeX macros and log
  messages, and derives the tutorial's states from intersections of named TikZ
  process paths instead of duplicated numeric coordinates.
- Adds an advanced six-stage R134a air-conditioner tutorial, from phase-region
  analysis through the complete cycle, endpoint-derived state properties,
  energy balances, and a comparison with approximate graphical readings.
- Closes every pure-fluid quality curve at one canonical critical state,
  removes the former `0.999 pcrit` truncation, and adds geometric near-critical
  refinement plus multi-fluid numerical regression coverage.
- Uses `siunitx` for generated LaTeX numbers and units while preserving any
  configuration established before LuaCoolProp is loaded; plain TeX and
  ConTeXt retain format-independent fallbacks.
- Makes PH axis and curve-family symbols configurable as TeX math material,
  including alternative quality and temperature notations such as `x` and
  `\theta`.

## 1.0.0 - 2026-09-05

Limited distribution to a small group of users. This release provided the PH
diagram and a generic TeX interface with LaTeX, plain TeX, and ConTeXt wrappers.
The first version of the independent `pgfplots-autonode` library was supplied
alongside it for automatic label placement.

## 1.0-RC-01

- Consolidates the pressure-enthalpy diagram interface for pure fluids.
- Provides generic TeX code plus LaTeX, ConTeXt, and plain TeX wrappers.
- Delegates automatic label placement to pgfplots-autonode.
- Supports quality curves, isotherms, isentropes, isochores, and process paths.
- Provides stable curve names and per-curve label/style overrides.
- Provides an English user manual and developer reference.
