For all complex numbers z,
let f(z) = z^2 if z is not real, f(z) = 2z if z is real.
Find f(f(f(f(1+i)))).