# Difference between revisions of "2015 AIME I Problems/Problem 3"

## Problem

There is a prime number $p$ such that $16p+1$ is the cube of a positive integer. Find $p$.

## Solution

Let the positive integer mentioned be $a$, so that $a^3 = 16p+1$. Note that $a$ must be odd, because $16p+1$ is odd.

Rearrange this expression and factor the left side (this factoring can be done using $(a^3-b^3) = (a-b)(a^2+a b+b^2)$, or synthetic divison once it is realized that $a = 1$ is a root):

$a^3-1 = 16p$

$(a-1)(a^2+a+1) = 16p$

Because $a$ is odd, $a-1$ is even and $a^2+a+1$ is odd. If $a^2+a+1$ is odd, $a-1$ must be some multiple of $16$. However, for $a-1$ to be any multiple of $16$ other than $16$ would mean $p$ is not a prime. Therefore, $a-1 = 16$ and $a = 17$.

Then our other factor, $a^2+a+1$, is the prime $p$:

$(a-1)(a^2+a+1) = 16p$

$(17-1)(17^2+17+1) =16p$

$p = 289+17+1 = \boxed{307}$.