weierstrass(a, b, x) => Number
Calculate Weierstrass function for given x, a, and b. More can be found there: https://en.wikipedia.org/wiki/Weierstrass_function Can be used for test data generation.
a |
Number |
Coefficient, 0<a<1 |
b |
Number |
Coefficient, odd integer |
x |
Number |
Point to calculate function in |
Return
Value in point x for Weierstrass function with given coefficients
Example
print(weierstrass(0.5, 7, 10)); //will print "1.999218"