Info
この質問は閉じられています。 編集または回答するには再度開いてください。
how can i create a circle with a radius leading to a point p with a tangent on the point p?
1 回表示 (過去 30 日間)
古いコメントを表示
I need a script to create a circle from a fixed point defined 𝑥 = 𝑟 cos 𝜃 + 𝑥0 𝑦 = 𝑟 sin 𝜃 + 𝑦0 with a radius plotted between (𝑥0, 𝑦0 ) and (𝑥𝑃, 𝑦𝑃 ) and a tangent line (𝑥𝑡 , 𝑦𝑡) are defined as follows: When 𝑦𝑃 ≠ 𝑦0 𝑥𝑃 − 2 ≤ 𝑥𝑡 ≤ 𝑥𝑃 + 2 𝑦𝑡 = 𝑚𝑡 (𝑥𝑡 − 𝑥𝑃 ) + 𝑦𝑃, When 𝑦𝑃 = 𝑦0 𝑥𝑡 = 𝑥𝑃 𝑦𝑃 − 5 ≤ 𝑦𝑡 ≤ 𝑦𝑃 + 5.
The MATLAB script must include the following: • User input for o The radius of the circle o The coordinates of the centre of the circle o The coordinates of the point 𝑃 • All calculations, including the calculation for the gradient of the tangent • The commands to: o Create a single figure containing all three lines/curves o Create a legend on the figure o Label the figure axes o Choose appropriate limits for the axes to ensure the circle does not touch the axes at any point o Set the aspect ratio of the figure to be 1:1 (use the MATLAB help to find the correct command to do this) • Comments describing the code
0 件のコメント
回答 (0 件)
この質問は閉じられています。
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!