"""
Stiffness Check Closure
Validates that stiffness values are within acceptable bounds.
"""

from __future__ import annotations


def compute(kappa: float) -> dict:
    """
    Check if stiffness is valid (positive and within reasonable bounds).

    Args:
        kappa: Stiffness in N/m

    Returns:
        Dict with validity boolean
    """
    # Stiffness must be positive and less than 1e12 N/m (reasonable physical limit)
    valid = 0 < kappa < 1e12
    return {"valid": valid}


if __name__ == "__main__":
    result = compute(1000.0)
    print(f"Result: {result}")  # valid = True
