Introduction and Installation Instructions: Matlab & Simulink Student Version
Introduction and Installation Instructions: Matlab & Simulink Student Version
Introduction and Installation Instructions: Matlab & Simulink Student Version
R2012a
Web Newsgroup Product enhancement suggestions Bug reports Documentation error reports Sales, pricing, and general information
508-647-7000 (Phone) The MathWorks, Inc. 3 Apple Hill Drive Natick, MA 01760-2098
For localities outside the U.S., see the MathWorks Web site. MATLAB & Simulink Student Version Introduction and Installation Instructions COPYRIGHT 19842012 by The MathWorks, Inc.
The software described in this document is furnished under a license agreement. The software may be used or copied only under the terms of the license agreement. No part of this manual may be photocopied or reproduced in any form without prior written consent from The MathWorks, Inc. FEDERAL ACQUISITION: This provision applies to all acquisitions of the Program and Documentation by, for, or through the federal government of the United States. By accepting delivery of the Program or Documentation, the government hereby agrees that this software or documentation qualifies as commercial computer software or commercial computer software documentation as such terms are used or defined in FAR 12.212, DFARS Part 227.72, and DFARS 252.227-7014. Accordingly, the terms and conditions of this Agreement and only those rights specified in this Agreement, shall pertain to and govern the use, modification, reproduction, release, performance, display, and disclosure of the Program and Documentation by the federal government (or other entity acquiring for or through the federal government) and shall supersede any conflicting contractual terms or conditions. If this License fails to meet the governments needs or is inconsistent in any respect with federal procurement law, the government agrees to return the Program and Documentation, unused, to The MathWorks, Inc.
Trademarks
MATLAB and Simulink are registered trademarks of The MathWorks, Inc. See www.mathworks.com/trademarks for a list of additional trademarks. Other product or brand names may be trademarks or registered trademarks of their respective holders.
Patents
MathWorks products are protected by one or more U.S. patents. Please see www.mathworks.com/patents for more information.
Revision History
April 2007 March 2008 October 2008 March 2009 March 2010 April 2011 March 2012
First printing Online only Online only Online only Online only Online only Online only
Rewritten for Release 2007a Release 2008a Release 2008b Release 2009a Release 2010a Release 2011a Release 2012a
Contents
Introducing MATLAB & Simulink Student Version
1
What Is Student Version? . . . . . . . . . . . . . . . . . . . . . . . . . . . Student Use Policy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Quick Start . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Installing Student Version . . . . . . . . . . . . . . . . . . . . . . . . . . Learning the MATLAB Programming Language . . . . . . . . Learning to Use Simulink Software . . . . . . . . . . . . . . . . . . . Student Version Overview . . . . . . . . . . . . . . . . . . . . . . . . . . What You Can Do with Student Version . . . . . . . . . . . . . . . Products Included in Student Version . . . . . . . . . . . . . . . . . Obtaining Additional MathWorks Products . . . . . . . . . . Finding Reference Information . . . . . . . . . . . . . . . . . . . . . Other Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . MathWorks Web Site . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Technical Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2 1-2 1-3 1-3 1-4 1-5 1-7 1-7 1-8 1-11 1-12 1-14 1-14 1-15
2
System Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Windows Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Macintosh Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Linux Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . MEX-Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-2 2-2 2-3 2-3 2-3
iii
Installing and Activating Student Version . . . . . . . . . . . Before You Begin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Installation Procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Activation Procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Starting MATLAB Student Version . . . . . . . . . . . . . . . . . . . Installing Additional Products . . . . . . . . . . . . . . . . . . . . . . Mounting the DVD on Linux Systems . . . . . . . . . . . . . . . .
Index
iv
Contents
1
Introducing MATLAB & Simulink Student Version
What Is Student Version? on page 1-2 Quick Start on page 1-3 Student Version Overview on page 1-7 Obtaining Additional MathWorks Products on page 1-11 Finding Reference Information on page 1-12 Other Resources on page 1-14
1-2
Quick Start
Quick Start
In this section... Installing Student Version on page 1-3 Learning the MATLAB Programming Language on page 1-4 Learning to Use Simulink Software on page 1-5
Student Version DVD. For more information about installation and activation, see Chapter 2, Installation and Activation Instructions.
1-3
Microsoft Windows Platforms On your desktop, double-click the MATLAB icon. Apple Macintosh Computers In the MATLAB installation folder (Applications, by default), double-click the MATLAB icon. Linux operating systems (Linux is a registered trademark of Linus Torvalds) At the command prompt, enter the matlab command.
1-4
Quick Start
Task
Action
Learn how to enter matrices, how to use the : (colon) operator, and how to invoke functions. Use the online help facility to access all the product documentation. Print this document You need a PDF reader, such as an Adobe Acrobat product. The PDF reader opens a .pdf file.
1 In a Web browser, go to the following URL:
http://www.mathworks.com/help.
2 Search for Student Version. Click the link for the associated .pdf file. 3 In the PDF reader, select File > Print.
Find detailed See Finding Reference Information on page 1-12 and Other Resources information on page 1-14. about using MATLAB and troubleshooting.
View the Simulink tutorial designed for students at View demos, as follows:
1 Start MATLAB.
http://www.mathworks.com/academia/simulinktutorial.
1-5
Task
Action
3 Click Demos and click the name of any demo.
View a recorded Simulink presentation, such as Introduction to Simulink, on the MathWorks Web site. Read the Simulink Getting Started Guide documentation. These resources help you learn how to model, simulate, and analyze dynamic systems. Because Simulink is graphical and interactive, you can start using Simulink quickly. After you master the basics, you can access the rest of the documentation through the online help facility (Help).
1-6
1-7
1-8
Simulink
Use the Simulink interactive tools for modeling, simulating, and analyzing dynamic systems, including controls, signal processing, communications, and other complex systems. Simulink supports linear and nonlinear systems, modeled in continuous time, sampled time, or a hybrid of the two. Systems also can be multirate (having different parts that are sampled or updated at different rates). You can easily build new models, or take an existing model and add to it. With instant access to all the MATLAB analysis tools, you can analyze and visualize the results. The Simulink environment provides a sense of fun and discovery in modeling and simulation. It encourages you to pose a question, model it, and see what happens. Thousands of engineers around the world use Simulink to model and solve real problems. Simulink is a tool that you can use throughout your professional career. Student Version Differences. Accelerator mode and Rapid-Accelerator simulation mode are not available in Student Version. You can use Model blocks in Normal mode only. Models, including the blocks in referenced models, are limited to 1000 blocks. Printouts contain the footer:
Student Version of MATLAB.
1-9
Image Processing Toolbox Optimization Toolbox Signal Processing Toolbox Simulink Control Design Statistics Toolbox Symbolic Math Toolbox For descriptions of these products, see the MathWorks Web site. Demos. Student Version includes many product demos. For example, a demo version of Stateflow software lets you edit and run Simulink models. You can use Stateflow to design and simulate state machines and control logic. However, you cannot save models when you use the demo version.
1-10
1-11
Find a block for a specific purpose, but you do not know the block name
1-12
What I Want What blocks are available in a general area Learn about a specific topic, such as sparse matrices, ordinary differential equations, or cell arrays
What I Should Do Use the Help browser to view Blocks for a product or use Search. Use the Help browser to locate the topic in the documentation for a product included with Student Version (for example, MATLAB > Mathematics > Sparse Matrices).
1-13
Other Resources
In this section... MathWorks Web Site on page 1-14 Technical Support on page 1-15
Web-Based Documentation
You can find documentation for all MathWorks software in the Support area of the MathWorks Web site. In addition to tutorials and function reference pages, you can find PDF versions of all the manuals.
MathWorks Store
At www.mathworks.com/store, you can purchase add-on products and documentation.
1-14
Other Resources
Central also contains the Link Exchange, where you can share your favorite links to various educational, personal, and commercial MATLAB Web sites. The comp.soft-sys.matlab newsgroup is for professionals and students who use MATLAB and have questions or comments about it and its associated software. Use this important resource for posing questions and answering queries from other MATLAB users. MathWorks staff also participates actively in this newsgroup.
Technical Support
At www.mathworks.com/support, you can get technical support. Telephone and email access to our technical support staff is not available for students running Student Version unless you are experiencing difficulty installing or downloading MATLAB or related products. There are numerous other vehicles of technical support that you can use. If you experience a problem that is unrelated to installing MATLAB or related products, look at the available MathWorks sources for help. If you still cannot resolve your problem, contact your instructor. Your instructor might be able to help you. (Registered instructors who have adopted Student Version in their courses have access to telephone and email technical support.)
1-15
1-16
2
Installation and Activation Instructions
You can download Student Version at
http://www.mathworks.com/downloads/student_downloads, or request a
Student Version DVD. This chapter describes how to install and activate Student Version using the Student Version DVD: System Requirements on page 2-2 Installing and Activating Student Version on page 2-5 Installing Additional Products on page 2-33 Mounting the DVD on Linux Systems on page 2-34
System Requirements
In this section... Windows Systems on page 2-2 Macintosh Systems on page 2-3 Linux Systems on page 2-3 MEX-Files on page 2-3
Note For detailed and current information on system requirements, see http://www.mathworks.com/support/sysreq/current_release/.
Windows Systems
32-Bit MathWorks Products Operating System Windows XP Service Pack 3 Windows Server 2003 R2 with Service Pack 2 Windows Vista Service Pack 2 Windows Server 2008 Service Pack 2 or R2 Windows 7 Processors Any Intel or AMD x86 processor supporting the SSE2 instruction set Disk Space 1 GB (MATLAB only) 3-4 GB for a typical installation RAM 1024 MB (At least 2048 MB recommended)
2-2
System Requirements
Macintosh Systems
32-Bit and 64-Bit MathWorks Products Operating System Mac OS X 10.6.4 (Snow Leopard) and above with Apple Java for Mac OS X Update 2 and above Processors All Intel based Macs Disk Space 1 GB (MATLAB only) 3-4 GB for a typical installation RAM 1024 MB (At least 2048 MB recommended)
Linux Systems
32-Bit and 64-Bit MathWorks Products Operating System Qualified distributions*: Ubuntu 10.04 LTS and 10.10 Red Hat Enterprise Linux 5.x or 6.x SUSE Linux Enterprise Desktop 11.x Debian 5.x Processors Any Intel or AMD x86 processor supporting the SSE2 instruction set. Disk Space 1 GB (MATLAB only) 3-4 GB for a typical installation RAM 1024 MB (At least 2048 MB recommended)
MEX-Files
MEX-files are dynamically linked subroutines that MATLAB automatically loads and executes. MEX-files provide a mechanism by which you call your
2-3
own C and Fortran subroutines from MATLAB as if they were built-in functions. To build your own MEX-files, you need a supported compiler. For the most up-to-date information about compilers, see the support area at the MathWorks Web site (http://www.mathworks.com/support/sysreq/current_release/).
2-4
Windows Systems You must have administrator privileges to install the software. Linux Systems Get the root password. You can install MATLAB software without superuser privileges, however, it limits certain installation options. For example, if you want to setup symbolic links to the matlab command, you must have root privileges. Macintosh Systems Get the name and password of the administrator account on your computer. The administrator account is the user account you set up when you configured your Macintosh system; this is not your MathWorks Account. During installation, you must enter this name and password in the Authenticate dialog box, shown below.
2-5
Installation Procedure
1 Start the installer by inserting the Student Version DVD into the DVD
drive. Windows Systems The installer should start automatically. If it doesnt, open the DVD in Windows Explorer. In the top-level folder on the DVD, double-click the MathWorks Installer, setup.exe. Linux Systems In a terminal window, navigate to the top-level folder on the DVD and execute the following command:
./install &
Depending on how your system is configured, you might have to mount the DVD first. Make sure you mount it with execute permissions, as in the following example. Note that the name of the DVD drive might be different on your system. For more information, see Mounting the DVD on Linux Systems on page 2-34.
mount -o exec /media/cdrom0
Macintosh Systems Double-click the DVD icon on your desktop to open the DVD and then double-click the InstallForMacOSX icon.
2-6
2 Read the information in the MathWorks Installer dialog box, and then
click Next.
Click Next.
3 Review the software licensing agreement in the License Agreement dialog
box and, if you agree with the terms, select Yes and click Next.
4 Select the type of installation you want to perform in the Installation Type
dialog box: Typical or Custom. A typical installation installs all the licensed products. If you want to choose which products get installed, select the Custom option. After making your selection, click Next.
2-7
5 Specify the name of the folder where you want to install MathWorks
products in the Folder Selection dialog box. Accept the default folder, or specify another folder, and click Next. If the folder doesnt exist, the installer creates it. The default installation folder varies by platform: Windows C:\Program files\MATLAB\R2012a Student Macintosh Applications/MATLAB_R2012a_Student.app Linux /usr/local/MATLAB/R2012a_Student
Specify installation folder.
Click Next.
2-8
6 (Custom installation only) Select the products you want to install in the
Click Next.
7 (Custom installation only) Specify additional installation options in the
Installation Options dialog box. On Windows systems, you can specify whether you want the installer to put a shortcut to the MATLAB program on your desktop. On Linux systems, you can specify whether you want to create symbolic links to the MATLAB executable. After making your choices, click Next.
8 Review your installation choices in the Confirmation dialog box. To change
Installation Complete dialog box. Choose whether to activate the software you just installed. MathWorks recommends activating immediately after
2-9
installation because you cannot use the software you installed until you activate it. To proceed with activation, click Next. To exit the installer without performing activation, clear the Activate MATLAB option and click Finish (the button label changes). You can activate later.
Leave this option selected to proceed to activation.
Click Next.
Activation Procedure
Perform this procedure to activate the software you just installed. You cannot use the software until you activate it.
2-10
Note To use this procedure to activate the software, you must be connected to the Internet. If you are not connected to the Internet, see When You Dont Have an Internet Connection on page 2-21.
1 Start the activation application. If you left the Activate MATLAB option
selected on the Installation Complete dialog box, the activation application starts automatically. Other ways to start the application include: Start MATLAB Student Version. If it needs to be activated, MATLAB starts the activation application. Navigate to the matlabroot/bin/$ARCH folder and launch the activate_matlab.exe program (activate_matlab.sh on Linux systems).
2 Read about the activation process in the Activation Overview dialog box.
Activation is the process that verifies licensed use of MathWorks products. This process validates the license and ensures that it is not used on more computers or by more users than allowed by the license option you have acquired. In most cases, activation is a two-step process: Enter the product serial number and your email address. Provide other registration information. You might also be required to provide proof of your student status. You can upload a digital image of your proof during activation, or provide it later. In this case, the software is only temporarily activated. To complete activation, check for an email from MathWorks indicating that your student status has been authenticated and follow the instructions in that email. To proceed with activation, click Next.
2-11
Click Next.
Select Yes if you are a student using the software for course work at a school, college, or university, and click Next to proceed with activation. Select No if you are not a student, and then click Cancel. You cannot use this software if you do not fit the description presented in this dialog box.
2-12
Click Next.
2-13
4 Enter the product serial number and your email address in the Serial
Click Next.
2-14
Click Next.
If you do not have a MathWorks account, the activation application creates one for you. In this case, specify the password that you want to use with your account in the Create Account dialog box, and click Next.
2-15
Click Next.
2-16
Click Send.
Note If MathWorks already has proof of your student status, sending registration information completes the activation process. The activation application displays the following Activation Status dialog box. Click Finish to exit the activation application and begin using the software. If you need to provide proof of student status, the activation application continuessee Step 7.
2-17
Click Finish.
2-18
displays the Proof of Student Status dialog box. If you have a digital image of your proof, select the I can provide a digital image now option and click Next to upload it. If you cannot provide proof of student status at this time, select I will provide a digital image later and click Next.
Choose whether to provide proof now or later.
Click Next.
If you chose the I can provide a digital image now option, the activation application displays the Online Proof of Student Status dialog box. Specify the file name of the digital image of your proof of student status and click Send to send it to MathWorks.
2-19
Click Send.
2-20
8 If you were required to provide proof of your student status, the activation
process ends by temporarily activating the software. Click Finish in the Activation Status dialog box to exit the activation application and begin using the software. To complete activation, check for an email from MathWorks indicating that your student status has been authenticated and follow the instructions in that email.
Follow these instructions.
Click Finish.
2-21
1 Start the activation application. If you left the Activate MATLAB option
selected on the Installation Complete dialog box, the activation application starts automatically. Other ways to start the application include: Start MATLAB Student Version. If it needs to be activated, MATLAB starts the activation application. Navigate to the matlabroot/bin/$ARCH folder and launch the activate_matlab.exe program (activate_matlab.sh on Linux systems).
2 Read about the activation process in the Activation Overview dialog box.
Activation is the process that verifies licensed use of MathWorks products. This process validates the license and ensures that it is not used on more computers or by more users than allowed by the license option you have acquired. To proceed with activation, click Next.
2-22
Click Next.
If the activation application cannot connect with MathWorks, it displays the Connection Error dialog box. Click OK to continue.
2-23
Click Next.
4 Verify that you are a student in the Student Use Policy dialog box:
Select Yes if you are a student using the software for course work at a school, college, or university, and click Next to proceed with activation. Select No if you are not a student, and then click Cancel. You cannot use this software if you do not fit the description presented in this dialog box.
2-24
Click Next.
2-25
5 Enter the product serial number and your email address in the Serial
Click Next.
2-26
2-27
Click Next.
2-28
7 Click Print to get a copy of all the information you will need to activate
the software when you visit a computer with an Internet connection and then click Next.
Print this information to help you activate later.
2-29
connection, you cannot activate the software. Bring the information you printed out to a computer with an Internet connection and complete activation there.
Note that the software is not activated.
Click Finish.
2-30
On Windows 7 systems, click the Windows Start menu, and click MATLAB R2012a Student Version. On Windows XP systems, click the Windows Start menu, and then select Programs > MATLAB > R2012a, and click MATLAB R2012a. If you chose to create a shortcut on your desktop in the Installation Options dialog box, you can double-click the MATLAB icon.
Navigate to matlabroot/bin, where matlabroot is your MATLAB installation folder, and double-click matlab.exe.
Linux Systems
2-31
Enter the matlab command at the system prompt. If you did not set up symbolic links on the Installation Options dialog box during installation, you must enter the full path name, matlabroot/bin/matlab, where matlabroot is the name of your MATLAB installation folder. Navigate to your installation folder and double-click the MATLAB icon.
Macintosh Systems
2-32
2-33
If your system requires that you have root privileges to mount a DVD drive, these commands work on most systems:
$ su root # mount -t iso9660 /dev/dvd /dvd
To enable nonroot users to mount a DVD drive, include the exec option in the entry for DVD drives in your /etc/fstab file, as in the following example:
/dev/dvd /dvd iso9660 noauto,ro,user,exec 0 0
This option is often omitted from the /etc/fstab file for security reasons.
2-34
Index
A
Index
I
installing additional products on Windows 2-33 installing Student Version on Linux 2-5 on Mac 2-3 on Windows 2-5
activating Student Version on Linux 2-5 on Windows 2-5 additional products installing on Windows 2-33
B
blocks finding specific 1-12 books MATLAB and Simulink related 1-14
L
learning MATLAB 1-5 learning Simulink 1-6 Linux activating Student Version 2-5 installing Student Version 2-5
C
comp.soft-sys.matlab 1-15 configuring additional products on Windows 2-33
M
Mac activating Student Version 2-3 installing Student Version 2-3 Macintosh computers 2-3 MathWorks Store purchasing products from 1-14 MATLAB books 1-14 calling C subroutine on Linux 2-3 calling C subroutine on Mac 2-3 calling C subroutine on Windows 2-3 calling Fortran subroutine on Linux 2-3 calling Fortran subroutine on Mac 2-3 calling Fortran subroutine on Windows 2-3 demos 1-5 learning 1-5 starting 2-31 to 2-32 MATLAB Central 1-14 MEX-file Linux 2-3 Mac 2-3 supported Linux compilers 2-3
D
demos MATLAB 1-5 Simulink 1-6
E
environment options 2-31
F
functions finding specific 1-12
H
help sources of 1-14 via newsgroup 1-14
Index-1
Index
N
newsgroup 1-14
Q
quick start 1-3
R
reference information obtaining 1-12 requirements, system for Linux operating systems 2-3 for Mac computers 2-3 for Windows platforms 2-2
starting MATLAB 2-31 startup.m file Windows 2-31 Student Version installing on Linux 2-5 installing on Mac 2-3 installing on Windows 2-5 MATLAB differences 1-8 Simulink differences 1-9 Stateflow differences 1-10 student use policy 1-2 support sources of 1-14 system requirements for Linux operating systems 2-3 for Mac computers 2-3 for Windows platforms 2-2
T S
shortcut MATLAB shortcut on desktop 2-31 Simulink books 1-14 demos 1-6 learning 1-6 technical support 1-15
W
Windows activating Student Version 2-5 installing Student Version 2-5
Index-2