Write a script similar script2.m in the Comet Plots section to plot the graph of the following polar equation, known as the "butterfly." It will be your duty to discover an appropriate interval for `theta`. The beauty of polar equations is the chance to see some really beautiful and exatic plots. You might want to try a smaller number of points in the comet plot before you try this. One final fun thing to do is to select Publish to HTML from the File menu and watch what happens. After executing a cell, examine the contents of your folder and note that a PNG file was generated by executing the cell. There are options for executing both single and multiple cells.
POLAR PLOT MATLAB R2013A CODE
After that, use the entries on the Cell Menu or the icons on the toolbar to execute the code in the cells provided in the file. The file mypolar.m is designed to be run in "cell mode." Open the file mypolar.m in the Matlab editor, then enable cell mode from the Cell Menu. Download the file to a directory or folder on your system.
POLAR PLOT MATLAB R2013A DOWNLOAD
You can download the Matlab file at the following link. Matlab FilesĪlthough the following file features advanced use of Matlab, we include it here for those interested in discovering how we generated the images for this activity. Save the file as script2.m and execute by pressing F5 in the editor. These will execute as soon as the comet animation is complete. In order to obtain a plot that will print, we added a plot command and some annotations.