Guth
NewsDocs
Page actions
View as Markdown ↗
Explore MCP tools ↗

instrument implementation / implementation-contract

Correlation & Covariance Calculator implementation

A source-bound implementation contract for Correlation & Covariance Calculator; deployment and executable qualification remain separate.

Status: VERIFIED_CLEANLifecycle: implementation-contract

Binding contract

This record describes what an executable surface must bind and validate. It does not claim that a public calculator, package, or production route is deployed.

Record owner
Guth Instruments
Lifecycle
verified-clean
Evidence ID
t4-225
Effect
Computation or source lookup only

Input and validation requirements

A constant-valued input column produces a zero denominator and the undefined form 0/0. The calculator should reject it or return an explicit undefined result rather than a numeric correlation.

Required corrections

No binding erratum is attached to this unique-name record. Implementers must still preserve the declared units, domain, and failure behavior.

Inspectable interface fixture

The sample below is evidence for interface and validation tests, not a production implementation.

{
  "inputs": {
    "x": [
      1,
      2,
      3
    ],
    "y": [
      2,
      4,
      6
    ],
    "units": {
      "x": "arbitrary",
      "y": "arbitrary"
    }
  },
  "expected_outputs": {
    "pearson_r": 1,
    "covariance_population": 1.3333333333,
    "covariance_sample": 2,
    "correlation_matrix": [
      [
        1,
        1
      ],
      [
        1,
        1
      ]
    ]
  },
  "working": "x̄=(1+2+3)/3=2; ȳ=(2+4+6)/3=4. Deviations: x−x̄=(-1,0,1), y−ȳ=(-2,0,2). Cross-products: 2+0+2=4. Sum of x squared deviations=1+0+1=2. Sum of y squared deviations=4+0+4=8. r=4/√(2×8)=4/4=1. Population covariance=4/3=1.3333333333. Sample covariance=4/(3−1)=2."
}

Other records

Sources and evidence

These pointers bind the page to evidence. They do not grant authority or collapse verification into deployment.

  • VERIFIED_LEDGER.json
  • evidence-tranche4/tranche4-results.json