You've given me some ideas (again

) I might have a play with this tonight.
For testing:
fdiv1()
that can only accept string floats as input and INTs them to div() them, drop the remainder and give the dec places it's got from there (so 1/3 will just come out as 0.3 etc) and do what is in your example above
fdiv2()
that can accept ints but gets the remainder from the mod and generates to x decimal places in a loop.
From there try to merge them into fdiv() which can accept floats and generate the extra decimal places.
Considering it's going to be using my integer div and mod functions it's going to be kind of slow.
See if I can beat you to generating pi to 1000 decimal places

(a long way off yet)
(this won't really be the answer to sqr() though. )