fixes #863 -- math.cloneNode should be set to true
Merge pull request #864 from pkra/issue863

fixes #863