Math doesn't work?

yes the problem is caused by teleporting the rectangle. So is there any other way to erase it without teleporting?