Raising Capital from Heterogeneous Investors