PHD Discussions Logo

Ask, Learn and Accelerate in your PhD Research

Question Icon Post Your Answer

Question Icon

7 years ago in Matlab By Aama

Coding in MATLAB

Which are the various kinds of coding methods used in MATLAB?

All Answers (4 Answers In All)

By Renu Answered 7 years ago

Coding in MATLAB can be done using 4 methods
Directly enter code in a terminal window.
Creating a script M-file.
The third method is the function M-file.
Incorporating C code or FORTRAN code into Matlab; this method uses .mex files.

By Aama Answered 7 years ago

Ok. Can someone briefly explain the above mentioned methods?

By Krishan Pancholi Answered 7 years ago

Ofcourse! The first method uses MATLAB as a kind of calculator; It is good for simple, low-level work.
In the second method, one makes a file with the same code as one would enter in a terminal window. When the file run’s, the script is carried out.
Third method actually creates a function, with inputs and outputs.
I’m not sure about the last method. Maybe you can talk to professionals from MATLAB and get your query cleared.

By Rajiv Bhatia Answered 7 years ago

https://www.youtube.com/watch?v=NPd13u4i6fM. This site teaches you how to create a M-file in MATLAB. Check it out.

Your Answer