reducing down path finder code

more work is still needed and no testing has been done yet.