The relationship between count rate, C, and distance, d, follows an inverse square relationship and students can investigate this relationship or use a power relationship to determine the values.
The equation can be rearranged using logs and values for n and k determined.
Similarly students can determine a value for k and investigate the effect of background radiation on the equation.
The apparatus can be set up as follows and the candidates measure the count rate at various distances.
# Importing the necessary libraries
from matplotlib import pyplot as plt
import numpy as np
#from prettytable import PrettyTable
# Preparing the data to be computed and plotted
dt = np.array([
[1.0, 0.15],
[2.0, 0.29],
[3.0, 0.38],
[4.0, 0.50],
[5.0, 0.60],
[6.0, 0.81],
[7.0, 0.90],
[8.0, 1.13]
])
# Preparing X and y data from the given data
x = dt[:, 0].reshape(dt.shape[0], 1)
X = np.append(x, np.ones((dt.shape[0], 1)), axis=1)
y = dt[:, 1].reshape(dt.shape[0], 1)
# Calculating the parameters using the least square method
theta = np.linalg.inv(X.T.dot(X)).dot(X.T).dot(y)
print(f'The parameters of the line: {theta}')
# Now, calculating the y-axis values against x-values according to
# the parameters theta0 and theta1
y_line = X.dot(theta)
# Plotting the data points and the best fit line
plt.scatter(x, y)
plt.plot(x, y_line, 'r')
plt.title('Best fit line using regression method')
plt.xlabel('Length in cm')
plt.ylabel('Resistance')
plt.show()
#def makePrettyTable(table_col1, table_col2):
# table = PrettyTable()
# table.add_column("Column-1", x)
# table.add_column("Column-2", Y)
#return table
The parameters of the line: [[ 0.13452381] [-0.01035714]]
In comparison, our calculated resistivity is 0.13 Ohm/m vs a databook value of 0.105 Ohm/m This is well within the expected variance of an A-level practical.