# Algebra question

1. Apr 21, 2012

### rhenretta

My math skills are failing me, and I was hoping one of you could help me with this real quick..

I need to solve for i:
$a^{i}=b$

a in this case is based on the interval in the musical scale, so
$a = 2^{\frac{1}{12}}$

I have to solve this in objective c, and apparently it doesn't let me solve logarithms except for bases 2, 10, and e

2. Apr 21, 2012

### chiro

Hey rhenretta.

This kind of problems what is called logarithms. Basically logs and exponentials are inverses in that log(e^x) = x and e(log(x)) = x for valid x's. So we have:

$log_a(a^{i}) = log_a(b)$ gives us
$i = log_a(b) = \frac{ln(b)}{ln(a)}$

where ln(x) is the natural logarithm function.

3. Apr 21, 2012

### rhenretta

Thanks chiro :)