One myth that exists about the sun is that it emits the optimal wavelengths and intensities in the color spectrum that a plant needs to thrive. The reality is the sun is actually pretty inefficient for plant growth but its free and there's a lot of it. Here's a small excerpt from wikipedia which explains the how plants use the suns energy.
"The following is a breakdown of the energetics of the photosynthesis process from Photosynthesis by Hall and Rao:
Starting with the solar spectrum falling on a leaf,
47% lost due to photons outside the 400–700 nm active range (chlorophyll utilizes photons between 400 and 700 nm, extracting the energy of one 700 nm photon from each one)
30% of the in-band photons are lost due to incomplete absorption or photons hitting components other than chloroplasts
24% of the absorbed photon energy is lost due to degrading short wavelength photons to the 700 nm energy level
68% of the utilized energy is lost in conversion into d-glucose
35–45% of the glucose is consumed by the leaf in the processes of dark and photo respiration
Stated another way:
100% sunlight → non-bioavailable photons waste is 47%, leaving
53% (in the 400–700 nm range) → 30% of photons are lost due to incomplete absorption, leaving
37% (absorbed photon energy) → 24% is lost due to wavelength-mismatch degradation to 700 nm energy, leaving
28.2% (sunlight energy collected by chlorophyll) → 32% efficient conversion of ATP and NADPH to d-glucose, leaving
9% (collected as sugar) → 35–40% of sugar is recycled/consumed by the leaf in dark and photo-respiration, leaving
5.4% net leaf efficiency.
Many plants lose much of the remaining energy on growing roots. Most crop plants store ~0.25% to 0.5% of the sunlight in the product (corn kernels, potato starch, etc.)."