Skip to content

Commit d63404b

Browse files
committed
MyMath: add the "phi" constant
1 parent 3bc3a09 commit d63404b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/main/java/jme3utilities/math/MyMath.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,10 @@ public class MyMath {
4242
// *************************************************************************
4343
// constants and loggers
4444

45+
/**
46+
* golden ratio = 1.618...
47+
*/
48+
final public static float phi = (1f + FastMath.sqrt(5f)) / 2f;
4549
/**
4650
* square root of 1/2
4751
*/

0 commit comments

Comments
 (0)