Building Algebraic Thinking in the Middle Grades through Pattern and Function