How long in years does it take for a principal to triple in value if invested at a rate of r compounded semi-annually? Give t as a function of r.

3P = P(1 + r/2)^(2t)

3 = (1+r/2)^(2t)
2t = ln3/ln(1+r/2) , then divide both sides by 2

t is in years, r is the annual rate expressed as a decimal.