You will write functions for an amino acid that has two ionisable groups. They give the share of each form at a pH, the net charge, the isoelectric point and the direction of movement in an electric field.
The idea. The fractions come from the pH and the two pK values. The net charge is the cation share minus the anion share. Above the pI the amino acid moves to the anode, and below it to the cathode.
Your tasks.
fractions(ph, pk1, pk2) so that it returns the shares of the cation, the zwitterion and the anion.net_charge(ph, pk1, pk2).isoelectric(pk1, pk2).direction(ph, pk1, pk2) so that it returns "cathode", "anode" or "stays". Call the charge small if it lies between and .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…