A company wants to run a pipeline from point A on the shore to point B on the island which is 6km from the shore. It costs 5, 000 dollars per kilometer to run the pipeline on the shore and 13, 000 dollars per kilometer to run it underwater. There is a point C on the shore so that BC is at right angles to AC. The straight shoreline is the line AC whose distance is 9km. The company wants to determine a point D between A and C so that the pipeline runs from A to D and to B. How far is D to C to minimize the cost? What is the minimum cost?