Origin and Evolution of Terrestrial Planets