#!/usr/bin/python

from random import *
from math import *
from numpy import *


def boltzmanRandom(width):
    x = random()
    y = random()
    z = width*cos(2*pi*x)*(-2*log(y))**0.5
    return z


print boltzmanRandom(10.0)
