How does energy from the sun get passed through an ecosystem