Long John Silver, a pirate, has buried his treasure on an island with five trees located at the following points: A (30.0 m, –20.0 m), B (60.0 m, 80.0 m), C (–10.0 m, –10.0 m), D (40.0 m, –30.0 m), and E (–70.0 m, 60.0 m). All of the points are measured relative to some origin, as in Figure. Long John’s map instructs you to start at A and move toward B, but cover only 1/2 the distance between A and B. Then move toward C, covering 1/3 the distance between your current location and C. Then move toward D, covering 1/4 the distance between where you are and D. Finally, move toward E, covering 1/5 the distance between you and E, stop, and dig.
A (30.0 m, –20.0 m), B (60.0 m, 80.0 m), C (–10.0 m, –10.0 m)
D (40.0 m, –30.0 m), and E (–70.0 m, 60.0 m).
The intermediate points are F,G,H and I. For each of coordinates x and y:
F = A + 1/2 (B - A)
G = F + 1/3 (C - F)
H= G + 1/4 (D - G)
I = H + 1/5 (E - H)
F = A + 1/2 (B - A)
G = F + 1/3 (C - F)
H= G + 1/4 (D - G)
I = H + 1/5 (E - H)
Vectors:
F = (30,-20) + 1/2 ((60,80) - (30,-20)) = (30,-20) + 1/2 (30,100) = (45, 30)
F = (30,-20) + 1/2 ((60,80) - (30,-20)) = (30,-20) + 1/2 (30,100) = (45, 30)
G = (45,30) + 1/3 ((-10,-10) - (45, 30)) = (45, 30) + 1/3 (-55, -40) = = (45-55/3,30-40/3)
H= ...
or you can use a program
XA=30.0
YA=-20.0
XB=60.0
YB=80.0
XC=-10.0
YC=-10.0
XD=40.0
YD=-30.0
XE=-70.0
YE=60.0
XF=XA+(XB-XA)/2.
YF=YA+(YB-YA)/2.
XG=XF+(XC-XF)/3.
YG=YF+(YC-YF)/3.
XH=XG+(XD-XG)/4.
YH=YG+(YD-YG)/4.
XI=XH+(XE-XH)/5.
YI=YH+(YE-YH)/5.
print *,XI,YI
output: 10. 16.