Assuming we have a set of k known haplotypes, the generation of a case (control) starts by simulating a genotype g using the case (control) genotype frequencies. This simulated genotype specifies the alleles on the the two haplotypes of the new individual at the disease locus. For example, if g = Aa then h k+1,d = 1 and h k+2,d = 0.