Open Source Computing

Week of January 27

Week 3:

Licensing

Monday: the MIT license, etc

Wednesday:

        GPLv3

We will use Daniel Bernstein's ChaCha cipher as a random-number generator. See https://cr.yp.to/chacha/chacha-20080120.pdf.

ChaCha achieves cryptographic mixing through additions, xors and shifts. No multiplications or divisions are used.

echo "hello and welcome to Open Source" | shasum -a 512

python3
import numpy as np
from randomgen import ChaCha
rg=np.random.Generator(ChaCha(seed=0x1234567, rounds=20))    # use the seed from above
# now rg.integers(A,B) chooses a good random value between A and B-1, inclusive