New triangle and polygon classes