Автора пока нетВзять себе
- Языки
- English
- Темы
- ОбразованиеНаука
Asked simply to "work on" a first-year physics lab, ChatGPT's Code Interpreter produced plausible-looking data and a spring constant. It also skipped the line fit the lab calls for. That is one finding of a study by Andrew Low and Z. Yasemin Kalender (arXiv:2311.12415), which tested how far the tool can carry an introductory laboratory activity.
The setup
Code Interpreter, a plugin that writes and runs Python behind the scenes, was released in beta in July 2023. The authors gave it a standard "Spring Constant" lab from the first semester of a physics degree. Students find the spring constant two ways: from the extension under hanging masses, and from the period of oscillation. They propagate uncertainties and do a chi-squared fit. The lab sheet states a spring constant of 51.5 N/m, and the activity is expected to take 9 hours.
Three approaches were tried:
- Basic prompts, written to mimic a novice, asking ChatGPT to generate model data and do the activity.
- Detailed prompts, closer to expert knowledge, for simulating and analysing data.
- Real experimental data uploaded as a spreadsheet, with an explicit request for an orthogonal distance regression (ODR) fit.
What happened
| Feature | Approach 1 | Approach 2 | Approach 3 |
|---|---|---|---|
| Used real data | No | No | Yes |
| Used a line fit | No | Yes | Yes |
| Counted both x and y errors in the fit | No | No | Yes |
| Plotted a graph with error bars | No | Yes | Yes |
| Correct method for the spring constant | Yes | Yes | Yes |
| Correct error propagation | No | Yes | Yes |
In Approach 1 ChatGPT gave every mass and period a fixed 2% uncertainty and worked out the spring constant for each pair of measurements instead of fitting a line. Its force uncertainty was set wrongly. In Approach 2 it used a least-squares fit that counted only y errors, although the x errors were not negligible.
With real data in Approach 3 and an ODR prompt, ChatGPT plotted and fitted correctly. Method 1 gave 50.86 ± 2.80 N/m with a reduced chi-square of 1.88. Method 2 gave 65.97 ± 0.75 N/m with a reduced chi-square of 12.32, which ChatGPT itself called significantly above 1 and put down to possible systematic errors without elaborating. Its explanations of how it propagated uncertainty were correct.
The hidden flaw in simulated data
In Approach 2 the noise added to the simulated data scaled with each value (5% of the true value), so points with larger values scattered more. This heteroscedasticity can be hard for novices to spot, and the authors say real introductory data, taken with a metre rule and a stop clock, is unlikely to behave like that. The fits still gave plausible spring constants, but the data were not plausible.
Advice on prompting
- Be specific: a detailed first prompt gave a fuller analysis than a vague one.
- Ask follow-ups and question the output, which makes mistakes easier to catch.
- Say the format you want, such as table headings, plotted variables or how errors propagate.
- Avoid ambiguity: without instructions ChatGPT made unstated assumptions, such as using pairs of values rather than a line fit.
For students and teachers
Novices may struggle to spot errors or to write detailed prompts, so the authors urge training on using ChatGPT well. Instructors could use it to prepare simulated data, plots and interactive simulations, but must check its output before giving it to students.
Sources
- Andrew Low and Z. Yasemin Kalender, Data Dialogue with ChatGPT: Using Code Interpreter to Simulate and Analyse Experimental Data, arXiv:2311.12415 (2023), licensed CC BY 4.0. Changed here: shortened and rewritten in hubnx's own words; the paper's figures, tables, code and references are left out.
Комментарии



