prolog for allegrograph

some changes by steve