{
  "id": "rational-expressions",
  "version": "34473d966fe5",
  "status": "published",
  "name": "Rational Expressions Calculator",
  "question": "How to simplify rational expressions?",
  "summary": "Simplifies, adds, subtracts, multiplies and divides rational expressions in one variable: one fraction in lowest terms, with the excluded values.",
  "category": "math",
  "subcategory": "algebra",
  "url": "https://www.acalculator.org/math/rational-expressions-calculator",
  "markdown": "https://www.acalculator.org/math/rational-expressions-calculator.md",
  "kind": "function",
  "method": "Combine into one fraction (multiply across, or over the product of the denominators), factor the top and the bottom, and cancel the common factors.",
  "assumptions": [
    "One variable; whole-number powers.",
    "The simplified form equals the expression wherever the expression is defined."
  ],
  "inputs": {
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "type": "object",
    "properties": {
      "expr": {
        "title": "Rational expression",
        "description": "Polynomials divided by polynomials, joined by + − × ÷.",
        "type": "string",
        "maxLength": 200
      }
    }
  },
  "outputs": {
    "simplified": {
      "label": "Simplified",
      "description": "One fraction in lowest terms.",
      "format": "math"
    },
    "excluded": {
      "label": "Excluded values",
      "description": "Where a denominator of the typed expression is 0; the expression is undefined there.",
      "format": "text"
    },
    "top": {
      "label": "Numerator, factored",
      "description": "The numerator after combining, factored.",
      "format": "math"
    },
    "bottom": {
      "label": "Denominator, factored",
      "description": "The denominator after combining, factored.",
      "format": "math"
    }
  },
  "defaultAnswer": {
    "inputs": {
      "expr": "(x^2 - 9)/(x^2 + 4x + 3)"
    },
    "outputs": {
      "simplified": "(x - 3)/(x + 1)",
      "excluded": "x ≠ -3, x ≠ -1",
      "top": "(x - 3) (x + 3)",
      "bottom": "(x + 1) (x + 3)"
    },
    "text": "(x^2 - 9)/(x^2 + 4x + 3) simplifies to (x - 3)/(x + 1)."
  },
  "examples": [
    {
      "given": {
        "expr": "(x^2 - 9)/(x^2 + 4x + 3)"
      },
      "expect": {
        "simplified": "(x - 3)/(x + 1)",
        "excluded": "x ≠ -3, x ≠ -1"
      },
      "source": "OpenStax, College Algebra 2e, section 1.6 Rational Expressions (https://openstax.org/books/college-algebra-2e/pages/1-6-rational-expressions), Example 1: (x − 3)/(x + 1)"
    },
    {
      "given": {
        "expr": "(x^2 + 4x - 5)/(3x + 18) * (2x - 1)/(x + 5)"
      },
      "expect": {
        "simplified": "(x - 1) (2x - 1)/(3 (x + 6))",
        "excluded": "x ≠ -6, x ≠ -5"
      },
      "source": "OpenStax, College Algebra 2e, section 1.6 Rational Expressions (https://openstax.org/books/college-algebra-2e/pages/1-6-rational-expressions), Example 2: (x − 1)(2x − 1)/(3(x + 6))"
    },
    {
      "given": {
        "expr": "(2x^2 + x - 6)/(x^2 - 1) / ((x^2 - 4)/(x^2 + 2x + 1))"
      },
      "expect": {
        "simplified": "(2x - 3) (x + 1)/((x - 1) (x - 2))",
        "excluded": "x ≠ -2, x ≠ -1, x ≠ 1, x ≠ 2"
      },
      "source": "OpenStax, College Algebra 2e, section 1.6 Rational Expressions (https://openstax.org/books/college-algebra-2e/pages/1-6-rational-expressions), Example 3: (2x − 3)(x + 1)/((x − 1)(x − 2))"
    },
    {
      "given": {
        "expr": "6/(x^2 + 4x + 4) - 2/(x^2 - 4)"
      },
      "expect": {
        "simplified": "4 (x - 4)/((x - 2) (x + 2)^2)",
        "excluded": "x ≠ -2, x ≠ 2"
      },
      "source": "OpenStax, College Algebra 2e, section 1.6 Rational Expressions (https://openstax.org/books/college-algebra-2e/pages/1-6-rational-expressions), Example 5: 4(x − 4)/((x + 2)²(x − 2))"
    }
  ],
  "sources": [
    "OpenStax, College Algebra 2e, section 1.6 Rational Expressions (retrieved 2026-10-03): https://openstax.org/books/college-algebra-2e/pages/1-6-rational-expressions"
  ],
  "related": [
    "simplify",
    "partial-fraction",
    "factoring",
    "polynomial-division"
  ],
  "changelog": []
}
