Learning Representations With Linear-Algebraic Structure