Patent ID: 8741686

Claim:
A method of producing a semiconductor device, comprising: forming an n-type semiconductor layer; forming an active layer on the n-type semiconductor layer; forming a first semiconductor layer which comprises p-type GaN-based compound semiconductor, a p-type In 1-x-y1 Ga x Al y1 N layer (0≦x<1, 0<y1<1) containing In and is disposed between the active layer and the first semiconductor layer, a second semiconductor layer which comprises a p-type GaN-based compound semiconductor and is disposed on either of between the active layer and the In 1-x-y1 Ga x Al y1 N layer or between the In 1-x-y1 Ga x Al y1 N layer and the first semiconductor layer, and an In y2 Ga 1-y2 N layer (0<y2≦1) disposed between the first semiconductor layer and the active layer, wherein the In y2 Ga 1-y2 N layer has a band gap smaller than a band gap of each of the In 1-x-y1 Ga x Al y1 N layer, the first semiconductor layer and the second semiconductor layer; the In y2 Ga 1-y2 N layer has a lattice constant larger than a lattice constant of each of the In 1-x-y1 Ga x Al y1 N layer, the first semiconductor layer and the second semiconductor layer; the In y2 Ga 1-y2 N layer has a thickness of 1 to 15 nm and containing Mg of 1×10 17 cm − to 1×10 19 cm −3 ; and an In composition ratio of the In y2 Ga 1-y2 N layer is higher than an In composition ratio of each of the In 1-x-y1 Ga x Al y1 N layer, the first semiconductor layer and the second semiconductor layer.