PyProblems for undergraduate physics

Plasma physics PhD student Lloyd James teamed up with Dr Yasmin Andrew to run a postgraduate student project developing Python-based simulation problems rooted in the undergraduate physics curriculum. In this blog post the duo tell us more about the project.

By Dr Yasmin Andrew and Lloyd James

In 2019 we recognised that many physics students’ second year laboratory courses, final year research projects, and summer UROP projects would directly benefit from more opportunities to develop their coding skills. Students start their undergraduate physics studies with a very wide range of abilities, experiences and backgrounds in coding. Most students have no programming experience at the beginning of their first year. Python, and coding more generally, is not only an increasingly relied-upon tool in physics research, but also a hugely transferrable skill that opens up doors to other exciting fields such as tech and data science. This was the motivation behind the PyProblems project.

A pedagogical opportunity

In developing questions directly linked to students’ ongoing undergraduate studies, the ‘PyProblems’ initiative would allow them to practice using mathematical and computational skills to solve conceptual and quantitative physics problems. The result has been a stand-alone bank of Python-based physics questions and Jupyter-notebook solutions that students access voluntarily and which helps improve and maintain their coding proficiency and confidence.

Physics PhD students were recruited to work directly with the course and module leaders to develop the problems and solutions, with the only brief being to be both rigorous and creative in the original question design and construction. The project benefitted from these students’ subject knowledge and Python experience, and a valuable outcome for the students was the pedagogical opportunity to develop teaching and learning resources early on in their academic career. The first set of first year problems and solutions was initially released in December 2019 while the second set for some Year 2 and 3 physics courses was completed for the start of the 2020/21 academic year.

A simulation of asteroid trajectories passing Earth
An example graph from the solutions showing a simulation of asteroid trajectories passing Earth

Python Helpdesks

The rollout of the project was supported by a group of physics PhD and final year MSci students who set up a series of hour-long Python Helpdesks in the Blackett Computer Suite on a voluntary basis. The purpose of these helpdesks was to directly support students in working through the PyProblems questions, and also provide help for any other coding questions they might have. This student-led initiative was so successful it was adopted by the Department of Physics as part of the ongoing undergraduate student support over the 2020/21 academic year, switching to an online Teams format.

Student-led collaboration with staff

This is an exciting time for the PyProblems initiative, which has now reached the stage of planning for future extension of the resources to the Year 3 and 4 modules and possible collaborations with other Imperial departments, as well as external higher education institutions.

It’s an excellent example of a postgraduate student-led collaboration with staff, which showcases how PhD students can directly contribute to the development of high-quality teaching and learning resources with their valuable subject and technical knowledge.

Find out more

Leave a Reply

Your email address will not be published. Required fields are marked *