confused on how to code this
2 ビュー (過去 30 日間)
古いコメントを表示
(a) Create a variable named theta. Assign an angle of to it.
Prove the trigonometric identity sin^2(theta)+cos^2(theta)=1
Here the is the variable ‘theta’ you created.
(b) Convert theta into degrees and store in a new variable theta_d and then repeat (a) to prove the trigonometric identity again. (Do not use function deg2rad).
4 件のコメント
Chunru
2022 年 8 月 26 日
theta = pi/2 instead of theta=angle(pi/2). Angle is a function to find the phase angle of a complex number. For a real number pi/2, the "angle" is 0.
回答 (2 件)
Walter Roberson
2022 年 8 月 25 日
編集済み: Image Analyst
2022 年 8 月 26 日
Use sin(theta)^2
360 degrees = 2π radians
divide by 2π
360/(2π) degrees = 1 radian
so x radians = 360/(2π) * x degrees
In matlab π is pi
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Special Functions についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!