Beginning inventory cost $2,000. The factory put $10,000 worth of direct materials into production and spent $5,000 on direct labor and another $4,000 on overhead. At the end of the year, you counted $3,000 worth of ending inventory. What is the cost of goods manufactured?