rework code to run multiple clearances