1 Using MATLAB, write a program (.m file) to compute an approximate value of the derivative of a function using the following finite difference formula.
2 Test your program using the function tan ๐‘ฅ for ๐‘ฅ = 1. Determine the error by comparing with the square of the built-in function sec (๐‘ฅ).
3 Graph the magnitude of the error as a function of โ„Ž, for โ„Ž = 10^(โˆ’k), ๐‘˜ = 0,โ€ฆ, 16. You should use logarithmic scale for โ„Ž and also for the magnitude of the error.
4 Is there a minimum value for the magnitude of the error?
5 How does the corresponding value for โ„Ž compare with the rule of thumb โ„Ž โ‰ˆ โˆš๐œ€๐‘š๐‘Ž๐‘โ„Ž?
6 Repeat items 1 through 5 using the central difference approximation.

๋Œ“๊ธ€ ์ˆ˜: 1

Sulaymon Eshkabilov
Sulaymon Eshkabilov 2021๋…„ 9์›” 4์ผ
It looks like a student assignment. Could you pl., show here your attempted actions (written codes)?

๋Œ“๊ธ€์„ ๋‹ฌ๋ ค๋ฉด ๋กœ๊ทธ์ธํ•˜์‹ญ์‹œ์˜ค.

๋‹ต๋ณ€ (0๊ฐœ)

์นดํ…Œ๊ณ ๋ฆฌ

๋„์›€๋ง ์„ผํ„ฐ ๋ฐ File Exchange์—์„œ Get Started with MATLAB์— ๋Œ€ํ•ด ์ž์„ธํžˆ ์•Œ์•„๋ณด๊ธฐ

์งˆ๋ฌธ:

2021๋…„ 9์›” 4์ผ

๋Œ“๊ธ€:

2021๋…„ 9์›” 4์ผ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by