In [2]:
%matplotlib inline
import os
working_directory = os.path.pardir
import sys
sys.path.insert(0, working_directory)
from distributions import NormalDistribution
import matplotlib.pyplot as plt
import numpy as np
In [3]:
norm = NormalDistribution()
In [4]:
norm.sample(3)
Out[4]:
In [5]:
plt.plot(norm.distribution.pdf(np.linspace(-3, 3, 100)))
plt.show()
In [6]:
from t1_simulator import *
In [7]:
plt.plot(np.linspace(0, 1, 1000), create_noise_process(np.linspace(0, 1, 1000)))
plt.show()
In [19]:
taus = np.linspace(0, 10, 1000)
noise = create_noise_process(taus, amplitude=1)
In [20]:
plt.plot(taus, calculate_t1_noisy(taus, 1))
plt.axis([0, 10, 0, 1.5])
plt.show()
In [25]:
plt.plot(taus, calculate_t1_noisy(
taus, 1, create_noise_process(taus, amplitude=0.01))
)
plt.axis([0, 10, 0, 1.5])
Out[25]:
In [ ]: