fixed the compute method in the RelType clause