Error
There was an error loading the page.
Plot the Fourier series coefficients for a piece-wise linear function. Write a Python script to reproduce the same figure.
Metadata
-
England schools
-
England university
-
Scotland schools
Taxonomy: mathcentre
Taxonomy: Kind of activity
Taxonomy: Context
Contributors
History
Toby Wood 1 year, 4 months ago
Published this.Toby Wood 1 year, 4 months ago
Created this as a copy of Toby JSXGraph one slider, two plots - 2023-11-15.There is only one version of this question that you have access to.
There are 3 other versions that do you not have access to.
Name | Type | Generated Value |
---|
diagram | jsxgraphboard |
HTML node
|
||||
python_code | string |
%matplotlib qt
import numpy a
|
Generated value: jsxgraphboard
This variable doesn't seem to be used anywhere.
Code
Ask the student a question, and give any hints about how they should answer this part.
You can make this figure yourself in Python by running the code below. But you'll need to code the function fourier_coefficient
yourself first.
{code_block(python_code,"python")}
You can practice by modifying the code snippet below.
Note: If you're not careful, your function will produce errors when $d/l = 0$ or $1$.
Use this tab to check that this question works as expected.
Part | Test | Passed? |
---|---|---|
Code | ||
Hasn't run yet |
This question is used in the following exams:
- Embedding digital skills in the mathematics curriculum by Toby Wood in Toby's workspace.
- Christian's copy of Embedding digital skills in the mathematics curriculum by Christian Lawson-Perfect in Debugging other people's stuff.
- claire's copy of Embedding digital skills in the mathematics curriculum by claire lines in claire's workspace.