Skip to main content
Mathematics LibreTexts

4.1: Greatest Common Factor

  • Page ID
    173470
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \( \newcommand{\dsum}{\displaystyle\sum\limits} \)

    \( \newcommand{\dint}{\displaystyle\int\limits} \)

    \( \newcommand{\dlim}{\displaystyle\lim\limits} \)

    \( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

    ( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\id}{\mathrm{id}}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\kernel}{\mathrm{null}\,}\)

    \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\)

    \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\)

    \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \(\newcommand{\longvect}{\overrightarrow}\)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \(\newcommand{\ket}[1]{\left| #1 \right>}\)
    \(\newcommand{\bra}[1]{\left< #1 \right|}\)
    \(\newcommand{\braket}[2]{\left< #1 \vphantom{#2} \right| \left. #2 \vphantom{#1} \right>}\)
    \(\newcommand{\braopket}[3]{\left< #1 \vphantom{#2}\vphantom{#3} \right| #2 \vphantom{#1}\vphantom{#3} \left| #3 \vphantom{#1}\vphantom{#2} \right>}\)
    \(\newcommand{\qmvec}[1]{\mathbf{\vec{#1}}}\)
    \(\newcommand{\op}[1]{\hat{\mathbf{#1}}}\)
    \(\newcommand{\expect}[1]{\langle #1 \rangle}\)
    \(\newcommand{\dfn}[1]{\emph{\textbf{#1}}}\)

    \(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)

    Videos

    Lecture: Why We Factor

    Example: Factoring the GCF from a Multi-Variable Expression

    Example: Factoring Out the GCF Involving a Rational Exponent

    Definitions and Theorems

    Definition: Factor

    When two or more numbers or expressions are multiplied, each is called a factor of the resulting product.

    Definition: Factoring

    To factor an expression is to write it as a product of two or more factors.

    Definition: Greatest Common Factor of Integers

    The greatest common factor (GCF) of two or more integers, not all zero, is the largest positive integer that is a factor of each of them.

    Definition: Greatest Common Factor of Monomials

    The greatest common factor of two or more monomials is the product of the greatest common factor of their coefficients and each variable common to every monomial raised to the smallest exponent with which that variable appears.

    Theorem: Factoring Out a Common Factor

    If the terms of a sum share a common factor, then the distributive property, applied in reverse, allows that factor to be written outside a set of parentheses:\[ab+ac = a(b+c).\nonumber\]When the shared factor is the greatest common factor of the terms, the remaining expression inside the parentheses has no factor common to all of its terms.

    Factoring Out a Negative

    When the leading term of a polynomial is negative, it is customary to factor out the negative of the greatest common factor so that the leading term inside the parentheses is positive. Doing so reverses the sign of every term inside the parentheses.

    Caution: A Term Equal to the GCF

    When a term is itself equal to the greatest common factor, dividing that term by the GCF leaves \(1\), not \(0\). For instance, the GCF of the terms of \(5x^2+5x+5\) is \(5\), and\[5x^2+5x+5 = 5(x^2+x+1),\nonumber\]not \(5(x^2+x)\).

    Tip for Success

    You can check any factorization by multiplying the factors back out using the distributive property. The product must return the original polynomial.

    Examples

    Example \(\PageIndex{1}\): Numerical GCF

    Find the greatest common factor of \(24\) and \(60\).

    Solution
    Write each integer as a product of primes: \(24 = 2^3\cdot 3\) and \(60 = 2^2\cdot 3\cdot 5\). The primes common to both are \(2\) and \(3\); take each to the smallest power that appears in both, giving \(2^2\cdot 3 = 12\). Thus the greatest common factor is \(12\).
    Example \(\PageIndex{2}\): GCF of Monomials

    Find the greatest common factor of \(12x^4\), \(18x^3\), and \(30x^2\).

    Solution
    First find the GCF of the coefficients: \(12 = 2^2\cdot 3\), \(18 = 2\cdot 3^2\), and \(30 = 2\cdot 3\cdot 5\), so the common part is \(2\cdot 3 = 6\). The variable \(x\) appears in every monomial; take its smallest exponent, \(x^2\). Hence the greatest common factor is \(6x^2\).
    Example \(\PageIndex{3}\): Factoring a Binomial

    Factor \(6x^2 + 9x\).

    Solution
    The GCF of \(6x^2\) and \(9x\) is \(3x\) (coefficient GCF \(3\); smallest power of \(x\) is \(x\)). Dividing each term by \(3x\) gives \(2x\) and \(3\). Applying the distributive property in reverse,\[6x^2+9x = 3x(2x+3).\nonumber\]
    Example \(\PageIndex{4}\): Factoring a Trinomial

    Factor \(15x^3 - 25x^2 + 10x\).

    Solution
    The GCF of the coefficients \(15\), \(25\), and \(10\) is \(5\), and the smallest power of \(x\) present is \(x\), so the GCF is \(5x\). Dividing each term by \(5x\) gives \(3x^2\), \(-5x\), and \(2\). Therefore,\[15x^3-25x^2+10x = 5x(3x^2-5x+2).\nonumber\]
    Example \(\PageIndex{5}\): Factoring Out a Negative Leading Term

    Factor \(-4x^3 - 8x^2 + 12x\), taking the leading coefficient inside the parentheses to be positive.

    Solution
    The GCF of the terms is \(4x\). Because the leading term is negative, factor out \(-4x\). Dividing each term by \(-4x\) reverses every sign: \(-4x^3\div(-4x)=x^2\), \(-8x^2\div(-4x)=2x\), and \(12x\div(-4x)=-3\). Thus,\[-4x^3-8x^2+12x = -4x(x^2+2x-3).\nonumber\]
    Example \(\PageIndex{6}\): Two Variables

    Factor \(8x^2y - 12xy^2\).

    Solution
    The GCF of the coefficients \(8\) and \(12\) is \(4\). Both terms contain \(x\) (smallest power \(x\)) and \(y\) (smallest power \(y\)), so the variable part of the GCF is \(xy\), and the GCF is \(4xy\). Dividing each term by \(4xy\) gives \(2x\) and \(-3y\). Therefore,\[8x^2y-12xy^2 = 4xy(2x-3y).\nonumber\]
    Example \(\PageIndex{7}\): A Common Binomial Factor

    Factor \(x(x-5) + 3(x-5)\).

    Solution
    Both terms share the common factor \((x-5)\). Treating \((x-5)\) as a single quantity and factoring it out,\[x(x-5)+3(x-5) = (x-5)(x+3).\nonumber\]

    MyOpenMath Practice


    Sources

    Several parts of this text use modifications from the following sources:

    All of these sources are released under the Creative Commons Attribution-Share-Alike License 4.0.


    This page titled 4.1: Greatest Common Factor was last modified on Sat, 12 Sep 2026 01:29:55 GMT and is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by Roy Simpson, Cosumnes River College.

    • Was this article helpful?