J, P and K seem to be on a straight line. The whole line length is 17z-4 and the two segments 8z-17+5z+37=17z-4.
From this 13z+20=17z-4. Add 4 to each side: 13z+24=17z; subtract 13z from each side: 24=4z or 4z=24. Dividing through by 4 we get: z=6. So, JP=8*6-17=31; PK=67; JK=98.