Thanks for your feedback for my library, I will look into this issue more 
closely soon.


> The hypot is nice and probably well used by beginners. But in numerics
> you can and will use very often the squared value as that saves you
> taking most of the time taking an unnecessary square root.
> 
> E.g. checking the distance won't be done by checking the hypot, but by
> comparing the scalar product (which is the hypot squared) against the
> squared value of the distance.
> 
> So I suggest adding a Math.hypot2 as well.

I agree with you, that you can use the scalar product to compare lengths.
So +1 for Math.hypot2
But I see also use cases for calculating the actual length.
So I would definitely include both methods.

alex

P.S I had problems with my mail program this afternoon. 
Sorry if someone got my previous mail twice.
I think I made some chaos in the mailing list...
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to