{"id":"table-interpolate-linear","version":"1.0.0","description":"Evaluate query x values in an x/y table and return once-rounded linear interpolation results.","supported_operations":["interpolate function table x y","linear interpolation lookup table","evaluate values between table points","piecewise linear table lookup","clamp interpolation outside range","linearly extrapolate table endpoints"],"unsupported_operations":["spline or polynomial interpolation","tables with duplicate or unsorted x values"],"semantics":["Uses the bracketing segment formula y0 + (x-x0)*(y1-y0)/(x1-x0) with strictly increasing x.","The explicit out_of_range policy is error, clamp, or linear extrapolation; exact rational results are rounded once.","half_up rounds ties away from zero (for example, -2.5 rounds to -3 at zero decimal places)."],"limits":{"max_input_bytes":32768,"max_items":32,"max_decimal_chars":70,"max_total_decimal_chars":1024,"max_digits":64,"max_exponent_magnitude":100,"max_decimal_places":18,"max_iterations":256,"max_output_bytes":32768},"pricing":{"status":"unpriced","charge_usd":null},"input_schema":{"type":"object","additionalProperties":false,"required":["x","y","query_x","out_of_range","decimal_places","rounding_mode"],"properties":{"x":{"type":"array","minItems":2,"maxItems":32,"items":{"type":["string","number"]}},"y":{"type":"array","minItems":2,"maxItems":32,"items":{"type":["string","number"]}},"query_x":{"type":"array","minItems":1,"maxItems":32,"items":{"type":["string","number"]}},"out_of_range":{"type":"string","enum":["error","clamp","extrapolate"]},"decimal_places":{"type":"integer","minimum":0,"maximum":18},"rounding_mode":{"type":"string","enum":["half_even","half_up","toward_zero","toward_positive","toward_negative"]}}},"output_schema":{"type":"object","additionalProperties":false,"required":["results","standard_version"],"properties":{"results":{"type":"array","items":{"type":"string"}},"standard_version":{"type":"string","const":"IEEE 754-2019 section 4.3"}}},"examples":[{"input":{"x":["0","10"],"y":["0","20"],"query_x":["2.5"],"out_of_range":"error","decimal_places":2,"rounding_mode":"half_even"},"output":{"results":["5.00"],"standard_version":"IEEE 754-2019 section 4.3"}},{"input":{"x":[0,1],"y":[2,4],"query_x":[-1,2],"out_of_range":"clamp","decimal_places":0,"rounding_mode":"half_even"},"output":{"results":["2","4"],"standard_version":"IEEE 754-2019 section 4.3"}}],"execute_url":"/v1/tools/table-interpolate-linear/versions/1.0.0/execute"}