Types of MATLAB file extension….a pet name to recognize the file type…

Since all the files which we save have one or other extension, with which the computer recognize in which platform /software it needs to open that file for future uses. The same applies for MATLAB. Here are the important file extensions which MATLAB provides.
They are as follow….

1)     Figure Files: -
Extension: -“.fig”
These files contains MATLAB figure. He plot, figure, image, etc. are stored with the extension of .fig by default. (You can specify the format of image you would like to store by selecting the format type from the drop down list which appears while saving the figure.)

2)     M-Files: -
Extension: - “.m” 
M-Files are standard ASCII text files. There are two types of these files
a)     Script files
b)    Function files
The built- functions in MATLAB are M-files most of which reside on computer in precompiled format. It may possible that you may not find the built-in function as per your requirement. In that case, you can create your own function which can be later used anywhere and whenever required in MATLAB program.  

3)     Mat- Files: -
Extension: - “.mat”
They are MATLAB binary file for storing variables. These files can also be easily transfer to other systems.  They contain a machine signature in the file header. Matlab checks the signature when it loads a file and, if a signature indicates that a file is foreign, performs the necessary conversion.

4)     Mex Files: -
Extension: - “.mex…” 
Matlab provides an interface to external programs written in the C and FORTAN languages.
You can call C or FORTAN subroutines from MATLAB as if they were built in functions. These callable programs are referred to as MEX-files. They are dynamically linked subroutines that the MATLAB interpreter can automatically load and execute.
(Platform specific, e.g. ".mexmac" for the Mac, ".mexglx" for Linux, etc.)

Third-party File extension

1)     .jkt 
GPU Cache file generated by Jacket for MATLAB (AccelerEyes)

2)     .mum 
MATLAB CAPE-OPEN Unit Operation Model File (AmsterCHEM)

P.S: - The first four file extensions are much of our use.
Hope to see you in next tutorial….!!!

Written By,

Student @ VIT University