scamp.utilities
Various and sundry utility functions used by SCAMP.
Classes
Parent class for class for classes like |
Functions
|
Returns the multiple of factor that is closest above x. |
|
Returns the integer power of y that is closest above x. |
|
Returns the multiple of factor that is closest below x. |
|
Returns the integer power of y that is closest below x. |
|
A test of the similarity of two strings via a (squared) cross-correlation of their characters. |
|
Returns a list of the indispensabilities of different pulses in a meter defined by the rhythmic_strata. |
Returns the indigestibility of a number per the theories of Clarence Barlow. |
|
|
Checks if x is a multiple of y. |
|
Checks if a is a prime number. |
|
Checks if x is an integer (including negative) power of y |
|
Iterates all generations of subclasses of a type |
|
Flattens a list, including ones containing multiple levels of nesting. |
|
Decorator used for memoization (see https://en.wikipedia.org/wiki/Memoization) |
|
Returns a list of the prime factors of n. |
|
|
|
Resolves the given path based on a variety of prefixes. |
|
Rotates a list such that it starts at the nth index and loops back to end at the (n-1)st |
|
Returns the multiple of factor that is closest to x (above or below). |
|
Returns the integer power of y that is closest to x (above or below). |
Sums up all of the values within a nested list. |