Class Stirling.StirlingS1Cache

  • Enclosing class:
    Stirling

    private static final class Stirling.StirlingS1Cache
    extends java.lang.Object
    Precomputed Stirling numbers of the first kind. Provides a thread-safe lazy initialization of the cache.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) static int MAX_N
      Maximum n to compute (exclusive).
      (package private) static long[][] S1
      Stirling numbers of the first kind.
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private StirlingS1Cache()  
    • Method Summary

      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • MAX_N

        static final int MAX_N
        Maximum n to compute (exclusive). As s(21,3) = 13803759753640704000 is larger than Long.MAX_VALUE we must stop computation at row 21.
        See Also:
        Constant Field Values
      • S1

        static final long[][] S1
        Stirling numbers of the first kind.
    • Constructor Detail

      • StirlingS1Cache

        private StirlingS1Cache()