Skip to content

These some of the coding tasks I completed in my first few months on placement to practice different python skills to prepare me for the larger project.

Notifications You must be signed in to change notification settings

OliviaT18/Placement_practice_code

Repository files navigation

Placement Practice Code

These some of the coding tasks I completed in my first few months on placement to practice different python skills to prepare me for the larger project. This does not include the tasks I did on my managers repositories which I forked so it includes only the basic 'starter problems.'

Activity Calculator

I was asked to write some code that for a given radioactive isotope, initial activity and decay time calculated the activity at said decay time. The csv file I was given (half_lives.txt) included the name of the nuclide, its half life and the corresponding unit which was either years, days, minutes or seconds. The challenge was to read the file in and then for the given nuclide convert the unit to seconds, calculate the decay constant then finally calculate the activity.

Monte Carlo Task

This was the first activity I was given when I started my placement. The task was using a monte carlo method in order to verify pi. This was designed to help me get comfortable with using python as well as using jupyter notebooks.

Neutron Yield

This task was based upon a paper by Jack Carpenter. Here I was given the task of using the model given in the paper to plot a graph of the neutron yield over an energy range for a given A value, then plot a second graph of neutron yield over a range of mass numbers (in the file) for a set energy value.

Orbital Problem

Here the idea was to learn more python basics by writing a script that plotted an orbit i.e. the two body problem. Unfortunately I was unable to get this code to work due to issues with the maths. Since it wasnt relevant to what I would later be doing I moved on to the next task.

Trajectory Problem

This problem was also designed to help me learn more python basics, in this case writing and using functions, but also start applying it to relevant nuclear physics problems. Initially I was asked to model the trajectory of a ball. Once i had done this I was asked to apply it to the situation of neutron displacement which is where the neutrons that exit the moderators perpendicular to the surface 'displace' from this perpendicular path before they reach the instruments.

About

These some of the coding tasks I completed in my first few months on placement to practice different python skills to prepare me for the larger project.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published