selfintersection and intersection demo