You will turn integration steps into proton counts, and use integrals to find the make-up of a mixture.
The idea. Integrals are in proportion to protons. Scale them so that they add up to the protons of the formula. In a mixture, divide each integral by the protons it stands for to get a number in proportion to moles.
Your tasks.
counts(steps, total_h). It returns the proton count of each signal, rounded to whole numbers.mole_fraction(i_a, h_a, i_b, h_b). It returns the mole fraction of compound A from its integral i_a for h_a protons, and that of B.mass_percent(x_a, m_a, m_b), the mass percentage of A when its mole fraction is x_a and the molar masses are m_a and m_b.Run your code once to unlock the worked solution.
Have you tried it?
Do the tasks in the editor first, and run the checker after each one. Its hints help when a check fails. When you are ready, compare your code with this solution.
Log in to join the discussion.
Loading…