# Pythagorean theorem calculator

- Human page: https://happytails.ai/en/calculators/pythagorean-theorem/
- Markdown: https://happytails.ai/en/calculators/pythagorean-theorem.md
- Structured JSON: https://happytails.ai/agents/en/calculators/pythagorean-theorem/index.json
- Visibility: public

## Tool capabilities

| Property | Value |
| --- | --- |
| Tool ID | `pythagorean-theorem` |
| Category | calculators |
| Implementation | Registered implementation. Registration alone is not a production-quality guarantee. |
| Browser execution | Automatic updates after valid input or file selection. |
| Browser processing | Browser; see tool notes for network behavior. |
| HTTP API | Not callable through HTTP. |
| Browser-agent interface | run_current_tool |

### Implementation notes

For right triangles only: a² + b² = c². In Missing leg mode, the second value is the hypotenuse and must exceed the known leg. Use the same unit for both lengths.

### Inputs and settings

No free-text input is required. Use the file inputs and/or settings below.

| Setting | Meaning | Control type | Default | Constraints |
| --- | --- | --- | --- | --- |
| `find` | Find | select | "Hypotenuse" | Allowed: Hypotenuse, Missing leg |
| `a` | Known leg a | number | 3 | min=0 max=1e+100 step=any |
| `b` | Other leg or hypotenuse | number | 4 | min=0 max=1e+100 step=any |

### Browser-agent workflow

1. Open the human page in a browser that supports WebMCP.
2. Discover the interface exposed by that page; use its actual schema.
3. Select files on the page first when the tool requires files.
4. Call `run_current_tool` with valid input and settings.
5. Inspect the returned result or error and the displayed output. Retrieve files from the displayed download links.

Calls do not automatically copy or download results. Browser permissions still apply. Interface availability alone is not proof of successful execution.

### Planning specification

The formula a² + b² = c² applies only to right triangles. Every side must be positive. In missing-leg mode, the hypotenuse must be longer than the known leg.

This describes intended requirements. Use the implementation notes, interface schema and observed output to determine current support.

### Complete machine-readable capability record

```json
{
  "id": "pythagorean-theorem",
  "category": "calculators",
  "built": true,
  "requirements": "The formula a² + b² = c² applies only to right triangles. Every side must be positive. In missing-leg mode, the hypotenuse must be longer than the known leg.",
  "implementation": {
    "fields": [
      {
        "key": "find",
        "label": "Find",
        "value": "Hypotenuse",
        "type": "select",
        "values": [
          "Hypotenuse",
          "Missing leg"
        ]
      },
      {
        "key": "a",
        "label": "Known leg a",
        "value": 3,
        "type": "number",
        "min": 0,
        "max": 1e+100,
        "step": "any"
      },
      {
        "key": "b",
        "label": "Other leg or hypotenuse",
        "value": 4,
        "type": "number",
        "min": 0,
        "max": 1e+100,
        "step": "any"
      }
    ],
    "input": false,
    "live": true,
    "presentation": "metrics",
    "note": "For right triangles only: a² + b² = c². In Missing leg mode, the second value is the hypotenuse and must exceed the known leg. Use the same unit for both lengths.",
    "experience": {
      "automatic": true,
      "single": false,
      "inputMaxLength": 1000000,
      "inputMode": "text",
      "label": "Your text",
      "placeholder": "Type or paste your input…",
      "help": "Change the input or settings to update your result. Results update as you type. Up to 1,000,000 characters.",
      "action": null
    },
    "mode": "automatic",
    "interactive": false
  },
  "execution": "Browser interface",
  "api": null,
  "browser_agent": {
    "supported": true,
    "name": "run_current_tool",
    "discovery": "WebMCP on the human page in a supporting browser",
    "verification": "See audit/API-AUDIT.md; availability is not verification"
  }
}
```

## Page guide

Find a missing side of a right triangle.

How can we improve this tool?

Report a problem or share an idea.

Please leave out private information. Your message and the tool name go to our team via PostHog.

### How to use Pythagorean theorem calculator

1. Enter the values you want to calculate and choose the relevant units or settings.
2. The result updates as you type. Adjust the available settings if needed.
3. Review the result, then use Copy result or a download link when available.

## Useful next steps

- [Distance formula calculator](https://happytails.ai/en/calculators/distance-formula-calculator/) ([Markdown](https://happytails.ai/en/calculators/distance-formula-calculator.md))

- [Slope calculator](https://happytails.ai/en/calculators/slope-calculator/) ([Markdown](https://happytails.ai/en/calculators/slope-calculator.md))

- [Scientific calculator](https://happytails.ai/en/calculators/scientific-calculator/) ([Markdown](https://happytails.ai/en/calculators/scientific-calculator.md))

## How to use it

Choose Hypotenuse and enter both legs, or choose Missing leg and enter one leg followed by the hypotenuse. Use the same measurement unit for both inputs.

### A worked example

Legs of 3 and 4 give a hypotenuse of 5. If the hypotenuse is 13 and one leg is 5, the other leg is 12.

### What to know

The formula a² + b² = c² applies only to right triangles. Every side must be positive. In missing-leg mode, the hypotenuse must be longer than the known leg.
