Optoelectronic devices require materials with energy gap within a given range. Quantum dots, nanoparticles with unique optical characterization satisfy this by changing its energy gap to be within this range. Graphene and boron nitride are both consider to use in photovoltaic cells, the last is the lightest compound of III-V. Like graphene Boron nitride has Hexagonal sturucture, but due to large energy gap it categorized as semiconductor unlike graphene which is conductor. Many approaches have been proposed to improving properties of these two materials including use of strains, patterned defects, reduction in dimension as nanoribbons, external supper-lattice potentials, doping and applying external electric fields, doping by other materials such as hydrogen. Breaking the symmetry and doping graphene lattice with boron and nitrogen atoms which will make p-type and n-type semiconductors with replacing boron and nitrogen atoms with carbon in its structure respectively leads to widening the gap at the Fermi level. Also remarkable structures can be made by mixing of graphene and boron nitride In this study changes in band gap by identifying a quantum dot and changing its structure in boron nitride compounds were studied. Calculations are done by quantum espresso’s PWscf.It is based on density functional theory and considering the plane waves as basic wave functions in electron-wave function expansion, using ultra soft pseudopotentials based on the generalized gradient approximation and the PBE exchange-correlation function.