Bug fixes. Changed pow to **.