Optimize Foundry Layouts for Modern Casting Systems