{
  "id": "golden-ratio",
  "version": "022d5cd78628",
  "status": "published",
  "name": "Golden Ratio Calculator",
  "question": "What is the golden ratio split?",
  "summary": "Splits a length in the golden ratio φ ≈ 1.618 from the whole, the longer part, or the shorter part, and gives the other two lengths.",
  "category": "math",
  "subcategory": "geometry",
  "url": "https://www.acalculator.org/math/golden-ratio-calculator",
  "markdown": "https://www.acalculator.org/math/golden-ratio-calculator.md",
  "kind": "function",
  "method": "φ = (1 + √5) ÷ 2 ≈ 1.6180339887. From the whole s: a = s ÷ φ, b = s − a. From the longer part a: b = a ÷ φ. From the shorter part b: a = b × φ. The whole is a + b.",
  "assumptions": [
    "The parts are in the golden ratio when (a + b) ÷ a = a ÷ b = φ.",
    "Lengths have no unit on the page: type them in any unit and read the answer in the same unit.",
    "φ is irrational, so lengths are computed in 64-bit floating point and rounded for display."
  ],
  "inputs": {
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "type": "object",
    "properties": {
      "k": {
        "title": "I know",
        "description": "Which of the three lengths you know.",
        "type": "string",
        "enum": [
          "whole",
          "long",
          "short"
        ]
      },
      "x": {
        "title": "Length",
        "description": "The length you know, in any unit. The answer is in the same unit.",
        "type": "number",
        "exclusiveMinimum": 0,
        "maximum": 1000000000000
      }
    }
  },
  "outputs": {
    "long": {
      "label": "Longer part a",
      "description": "The longer part: whole ÷ φ, or shorter × φ.",
      "format": "number"
    },
    "short": {
      "label": "Shorter part b",
      "description": "The shorter part: longer ÷ φ, or whole − longer.",
      "format": "number"
    },
    "whole": {
      "label": "Whole a + b",
      "description": "The longer part plus the shorter part.",
      "format": "number"
    },
    "phi": {
      "label": "Golden ratio φ",
      "description": "(1 + √5) ÷ 2.",
      "format": "number"
    }
  },
  "defaultAnswer": {
    "inputs": {
      "k": "whole",
      "x": 66
    },
    "outputs": {
      "long": 40.79024325749306,
      "short": 25.20975674250694,
      "whole": 66,
      "phi": 1.618033988749895
    },
    "text": "The longer part is 40.7902 and the shorter part is 25.2098, for a whole of 66."
  },
  "examples": [
    {
      "given": {
        "k": "whole",
        "x": 66
      },
      "expect": {
        "long": 40.79024325749306,
        "short": 25.20975674250694,
        "phi": 1.618033988749895
      },
      "source": "OpenStax, Contemporary Mathematics, §13.1 Math and Art (φ = (1 + √5)/2 ≈ 1.618), https://openstax.org/books/contemporary-mathematics/pages/13-1-math-and-art (Example 13.1: 66 ÷ L = 1.618, L ≈ 40.8 in); Python 3: 66/((1+5**0.5)/2)"
    },
    {
      "given": {
        "k": "short",
        "x": 10
      },
      "expect": {
        "long": 16.18033988749895,
        "whole": 26.18033988749895
      },
      "source": "hand calculation in content.mdx: a = 10 × φ = 16.18, a + b = 26.18; OpenStax, Contemporary Mathematics, §13.1 Math and Art (φ = (1 + √5)/2 ≈ 1.618), https://openstax.org/books/contemporary-mathematics/pages/13-1-math-and-art"
    },
    {
      "given": {
        "k": "long",
        "x": 10
      },
      "expect": {
        "short": 6.180339887498948,
        "whole": 16.18033988749895
      },
      "source": "hand calculation in content.mdx: b = 10 ÷ φ = 6.18 (φ − 1 = 1 ÷ φ); OpenStax, Contemporary Mathematics, §13.1 Math and Art (φ = (1 + √5)/2 ≈ 1.618), https://openstax.org/books/contemporary-mathematics/pages/13-1-math-and-art"
    }
  ],
  "sources": [
    "OpenStax, Contemporary Mathematics, §13.1 Math and Art (φ = (1 + √5)/2 ≈ 1.618; Examples 13.1, 13.3 and 13.4). https://openstax.org/books/contemporary-mathematics/pages/13-1-math-and-art (retrieved 2026-10-02)",
    "OpenStax, Calculus Volume 2, §5.1 Sequences (the Fibonacci ratios converge to φ = (1 + √5)/2). https://openstax.org/books/calculus-volume-2/pages/5-1-sequences (retrieved 2026-10-02)"
  ],
  "related": [
    "ratio",
    "aspect-ratio",
    "proportion",
    "sequence"
  ],
  "changelog": []
}
