MATLAB Learning notes Miscellaneous

Source: Internet
Author: User

1. You have three ways to get help from Matlab. The best way is to use the Help space window (Helpbrowser). You can click the icon on the Matlab Desktop toolbar or in the Command window (thecommand

Windows), enter Helpdesk or Helpwin to start the Help space window (Helpbrowser). There are also two other ways to use the original form of the command line to get help. The first method is to enter help or Help and the name of the required function in the MATLAB command Window (the command Windows). If you enter only Help,matlab in the command Window (thecommandwindows), a series of functions will be displayed. If a specific function name or toolbox name is included, help will provide the function or toolbox. The second method is to get help through the lookfor command. Unlike the help command, the LOOKFOR command requires an exact match to the function name, and LookFor only requires a match to the summary information in each function. The lookfor command runs much slower than the help command, but it increases the chance of getting useful information. For example, suppose you want to find a function of the inverse array (inverseofmatrix) of the Matrix. However, there is no function called inverse in matlab, then the help command will not work, only with the LookFor command.

2. Another important command is the abort command. If an M file is running too long, it may contain an infinite loop without ending. In this case, you can enter control-c (abbreviated as ^C) in the command window. Enter this command by clicking the cursor inside the command window, holding down the control key and pressing C. When Matlab removes the ^c, the program has stopped and returned to the command prompt state. Ellipsis (! ) is another important special character. Its special function is to send a command to the computer's operating system. The word Fu after the ellipsis is sent to the computer and executed if the character is entered in the command prompt of the computer. This feature makes system commands easier to embed in a MATLAB program. Finally, you can use the diary command to record what each thread does in the process of running MATLAB. The format of the command is as follows: Diary filename When this command is executed, all input and output in the command window will be recorded in the diary file. This is a very important tool that you can use to reconstruct important events when the MATLAB error breaks. The diary off command aborts writing to the diary file, and the diary on command restarts the write.

The 3.MATLAB also includes a special command--which command that helps us find the version of the file being executed and the path to it. We can use the path tool in the boot platform to check and modify this path at any time, or enter the Editpath command in the command window. The path tool allows the user to add, remove paths and change the order in the directory. There are other path-related functions, including:

?? Addpath add directory to matlab search path.
?? Path Displays the MATLAB search path.
?? PATH2RC adds the current directory to the MATLAB search path.
?? Rmpath move the directory in the MATLAB search path.

 

MATLAB Learning notes Miscellaneous

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.