/ Published in: PHP
Explanation of the method used here in the URL.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
<?php /* * Due to being a simple piece of mathematics, my triangular number function is likely * exempt from copyright, but just in case I eschew all copyright and give it entirely * to the public domain. * --Joey Sabey */ function triangularNumber($_x) { return (($_x / 2) + 0.5) * $_x; } ?>
URL: http://www.curiousmath.com/index.php?name=News&file=article&sid=95