Energetics and electronic structures of thin films and heterostructures of a hexagonal GaN sheet