added square root scalar function