Skip to content

Main content

Logcosh Loss Small Residual Limit Tool

Return the second- and fourth-order small-residual Taylor terms for log(cosh(residual)).

Loading tool…

Description

Return residual² / 2 and -residual^4 / 12 as the first quadratic term and quartic correction of the small-residual log-cosh expansion.

Signed errors preserve direction while absolute or squared errors emphasize magnitude. Their gradients and small-residual approximations represent specific mathematical terms rather than complete performance evaluations.

Return residual² / 2 and -residual^4 / 12 as the first quadratic term and quartic correction of the small-residual log-cosh expansion.

When to use this tool

Use Logcosh Loss Small Residual Limit when you need an explicit error, gradient, or local loss component.

How to use the tool and how it works

  1. Enter residual. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read quadraticApproximation, quarticCorrection. Use the output convention below.

Return residual² / 2 and -residual^4 / 12 as the first quadratic term and quartic correction of the small-residual log-cosh expansion.1

Input fieldMeaning and unitsAccepted input
residualSigned residual using the convention in the calculation paragraph.Required. Finite number.
Output fieldInterpretationReturned shape
quadraticApproximationQuadratic ApproximationRequired. Finite number.
quarticCorrectionQuartic CorrectionRequired. Finite number.
json
{
  "input": {
    "residual": 0.2
  },
  "output": {
    "quadraticApproximation": 0.020000000000000004,
    "quarticCorrection": -0.00013333333333333337
  }
}

Limitations and assumptions

  • These are separate approximation terms, not the exact loss or a guaranteed error bound for large residuals.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
  • Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.

Alternative or Complementary methods

Assess a full error distribution and keep the sign and aggregation conventions consistent across models.

References

  1. Calculation and input contract: metrics/logcosh-loss-small-residual-limit — tool.io

Similar or alternative tools