The matlab-of the digital model notes (construction ...)

Source: Internet
Author: User

  MATLAB at the beginning of the feeling is a matrix-oriented version of the command-line program , additional advanced operations and 2d/3d drawing .... Well, yes, that's what I was thinking. = =

Bo Master is a mathematical department of undergraduates, but also to start preparing for the summer of MCM, although the undergraduate stage will open the Math software classes, but heard compared to the chicken, and time compared to the back, so write a note of self-study during the experience more profound or feel more practical place, right when sharing and notes, laughed at, hahaha.

In order to weigh the two major MCM and ICPC competition is also a lot of Kung fu know ...

Later just feel like to do things still have to do ah, mathematical modeling may change my view of mathematics has always been, asked so many people may be directly in person to practice once will have some experience, need to slowly adapt to the two competitions

Introduction to Matlab

The English full name of MATLAB is the matrix Laboratory, which means the Fabric factory (Matrix Lab), which is issued by the American MathWorks Company, and represents the advanced level of the international scientific Computing software today.

  MATLAB and Mathematica,Maple are called the three major math software. It is in the mathematical science and technology application software in the numerical computation aspect is the most. MATLAB can perform matrix operations, draw functions and data, implement algorithms, create user interfaces, connect to other programming language programs, etc., mainly used in engineering calculation, control design, signal processing and communication, image processing, signal detection, financial modeling design and analysis and other fields.

I heard that Professor Cleve Moler, of the University of New Mexico, teaches students the sense of linear algebra programming in other high-level languages is lame, so I wrote one with Fortran (later, the core of Matlab was written in c), and then another two people set up MathWorks company, is not a bit of meaning, haha haha ~

————————— END

Matlab Basics (Record easy-to-forget points only)

Beginner's feeling is similar to C,pascal's big grammar, but the usability and usability enhance a lot, is the door more focus on computing (especially matrix) and graphics, data analysis of the language, mathematical library functions more than imagined.

  

  1.1 Numeric types and character types

    • variable naming rules : 1. The first letter is the English letter, 2. The letter has no space; 3. up to 19 letters , excess will be ignored

    • return value type auto-Convert

Ans = Double type + logic type or character type--ans double

Ans = double type + integer or single type--ans integer or single type

    • Single and integer types (int32,uint16, etc.) cannot perform arithmetic operations.

    • U = [M n]--merges the matrix M and N, which is equivalent to the links m and n in the string, for example
M = ' Hello '; N = ' world! '; u = [M n]% output u =         Hello world!

  1.2 struct type and cell array type

    • It is really a good idea to assign a value directly to a field in a struct, and it is convenient to use the copy matrix function (Repmat ()) when creating an array of structs, for example:
The  Repmat () function, replicate matrix abbreviation, can be used to copy some data, such as creating a 1*2 matrix with the same fields as the different structures:


% Here's student (1) = = Student (2)

    • Use ":" to define a arithmetic progression or to use Linspace () to define a linear split, which is more efficient than for loops in other high-level languages, such as:

>>array = 1:10    % starts with 1, 10 is the end point, 1 is the step size array =     1 2 3 4 5 6 7 8 9 10>>array = 10:-2:1    % step becomes -2array =
   10 8 6 4 2>>array = Linspace (1,10,4)    % on [1,10] Create an array of 4 elements that divide the interval linearly,    array =     1 4 7 10

    • If there is a cell array name C, then there is C (m,n): units of M row n columns in the cell array; C{m,n}: Contents of M-row N-column cells in a cell array

Loading ...

Loading ...

The matlab-of the digital model notes (construction ...)

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.