San Rafael-based Autodesk said Thursday that it has signed a definitive agreement to acquire Moldflow, a developer of software for simulating injection molding. Autodesk said it would pay $22 per share for the firm, making the deal worth approximately $297M. Moldflow is based in Framingham, Mass., and had fiscal 2007 revenues of $55.9M. Autodesk said it expects the deal to close in Q2 of 2008. Autodesk said the acquisition would provide its customers with analysis capabilities for plastics manufacturing.