A best proximity point approach to existence of solutions for a system of ordinary differential equations