Thermal and Microstructure Modeling of Metal Deposition Processes with Application to Ti-6Al-4V