Initial potential energy = Final potential energy + Work performed
Because the spring is unloaded at t=0, the only potential energy in the system is gravitational potential energy in the elevator. Using the unloaded location of the spring as the origin,
Initial potential energy = mgd
When the elevator comes to rest, the potential energy is stored in the spring and in the elevator. Using conservation of external forces on the elevator at rest on the spring, you find the final resting height of the elevator. Choosing downward force as negative to keep the signs straight,
-mg - kX = 0, where X = final resting height
Final potential energy = mgX + ½kX²
Work performed is the work overcoming friction over the total travel of the elevator. Because the frictional force is constant and directly opposes the elevator,
Work performed = FD, where F is the frictional force due to the safety device and D is the total travel of the elevator
mgd = mgX + ½kX² + FD
-mg - kX = 0 therefore X = -mg/k (negative indicating compressed spring)
mgd = mg * (-mg/k) + ½k(-mg/k)² + FD
mgd = -m²g² / k + ½m²g² / k +FD
D = (mgd + ½m²g²/ k) / F
Substituting known values,
D = (1800 * 9.8 * 3.7 + ½ * 1800² * 9.8² / 150000) / 4400
D = 15.07 m