|
2.5
Sept 10, 2015 17:40:23 GMT
Post by matthorr on Sept 10, 2015 17:40:23 GMT
Consider the following periodic function:
\( u(x) = \sum_{k=1}^6 \frac{1}{k} \sin(2kx) \)
Please plot the exact function on one figure for 0 < x < 2π. What do you think the function would look like if the summation was not stopped with 6 terms but rather had an infinite number of terms (just include a sketch)? Derive the exact first derivative and plot on a second figure. What do you think the first derivative of the function would look like if the summation was not stopped with 6 terms but rather had an infinite number of terms (sketch)? Use a three point central difference to approximate the first derivative for the given periodic function at x = π/8 with Δx = 0.04 and Δx = 0.02 and compare to the exact solution. What are the errors for both of these approximations? Any comments?
|
|
|
2.5
Sept 16, 2015 19:02:06 GMT
Post by matthorr on Sept 16, 2015 19:02:06 GMT
Here's my answers all together. Please post if you see an error... HW2.pdf (146.33 KB)
|
|
|
2.5
Sept 16, 2015 23:00:12 GMT
Post by lucasp on Sept 16, 2015 23:00:12 GMT
Correct me if I'm wrong, but shouldn't the error on 2.4 be fourth order due to symmetry? The a terms on the left hand side of the equation should cancel like the b terms did, causing the error to appear to be zero. The next column of the taylor table would then be used to find the error. By the same logic, wouldn't the expected order of the central difference w/ 5 points on 2.3 be fifth order?
Also, your equation for the central difference on 2.5 should have a 2*deltax on the bottom instead of just deltax. Everything else looks good though.
|
|
|
2.5
Sept 17, 2015 1:15:28 GMT
Post by matthorr on Sept 17, 2015 1:15:28 GMT
I double checked my maths on 2.3 and 2.4 and I think I did them right - can anyone else chime in what they got? If I'm wrong and the coefficients add up to zero, the error would be in the next column bumping up the order of the error.
Thanks for catching the error in 2.5 on the central difference. My calculations used the right formula - I just copied it wrong in the answer.
|
|
|
2.5
Sept 21, 2015 14:14:01 GMT
Post by Br. Marius on Sept 21, 2015 14:14:01 GMT
Shoot-sorry that I've been lax in posting here, guys. I'm going to be keeping a better eye on this from here on out.
|
|