<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE language SYSTEM "language.dtd">
<language _name="MATLAB M-file" version="1.0" _section="Sources" mimetypes="text/x-objcsrc">

	<line-comment _name = "Line Comment" style= "Comment" end-at-line-end = 
"TRUE">
		<start-regex>%</start-regex>
	</line-comment>
	
	<string _name = "String" style = "String">
		<start-regex>&apos;</start-regex>
		<end-regex>&apos;</end-regex>
	</string>

	<keyword-list _name = "Types" style = "Data Type" case-sensitive="TRUE">
		<keyword>double</keyword>
		<keyword>char</keyword>
	</keyword-list>
	
	<keyword-list _name = "Predefined Special Values" style = "Keyword" case-sensitive="TRUE">
		<keyword>pi</keyword>
		<keyword>i</keyword>
		<keyword>j</keyword>
		<keyword>Inf</keyword>
		<keyword>NaN</keyword>
		<keyword>clock</keyword>
		<keyword>date</keyword>
		<keyword>eps</keyword>
		<keyword>ans</keyword>
	</keyword-list>
	
	<keyword-list _name = "Output Display Format" style = "Keyword" case-sensitive="TRUE">
		<keyword>format\ short</keyword>
		<keyword>format\ short\ e</keyword>
		<keyword>format\ short\ g</keyword>
		<keyword>format\ long</keyword>
		<keyword>format\ long\ e</keyword>
		<keyword>format\ long\ g</keyword>
		<keyword>format\ bank</keyword>
		<keyword>format\ hex</keyword>
		<keyword>format\ rat</keyword>
		<keyword>format\ compact</keyword>
		<keyword>format\ loose</keyword>
	</keyword-list>

	<keyword-list _name = "MATLAB Functions 1" style = "Keyword" case-sensitive="TRUE">
		<!-- FUNCTIONS -->
		<!--Starting and Quiting-->
			<keyword>exit</keyword>
			<keyword>finish</keyword>
			<keyword>matlab</keyword>
			<keyword>matlabrc</keyword>
			<keyword>quit</keyword>
			<keyword>startup</keyword>
		<!--Command Window-->
			<keyword>clc</keyword>
			<keyword>diary</keyword>
			<keyword>dos</keyword>
			<keyword>format</keyword>
			<keyword>home</keyword>
			<keyword>more</keyword>
			<keyword>notebook</keyword>
			<keyword>perl</keyword>
			<keyword>system</keyword>
			<keyword>unix</keyword>
		<!--Getting Help-->
			<keyword>doc</keyword>
			<keyword>demo</keyword>
			<keyword>docopt</keyword>
			<keyword>docroot</keyword>
			<keyword>help</keyword>
			<keyword>helpbrowser</keyword>
			<keyword>helpwin</keyword>
			<keyword>info</keyword>
			<keyword>lookfor</keyword>
			<keyword>support</keyword>
			<keyword>web</keyword>
			<keyword>whatsnew</keyword>
		<!--Workspace, File, and Search Path-->
			<!--Workspace-->
				<keyword>assignin</keyword>
				<keyword>clear</keyword>
				<keyword>evalin</keyword>
				<keyword>exist</keyword>
				<keyword>openvar</keyword>
				<keyword>pack</keyword>
				<keyword>which</keyword>
				<keyword>who</keyword>
				<keyword>whos</keyword>
				<keyword>workspace</keyword>
			<!--File-->
				<keyword>cd</keyword>
				<keyword>copyfile</keyword>
				<keyword>delete</keyword>
				<keyword>dir</keyword>
				<keyword>fileattrib</keyword>
				<keyword>filebrowser</keyword>
				<keyword>ls</keyword>
				<keyword>matlabroot</keyword>
				<keyword>mkdir</keyword>
				<keyword>movefile</keyword>
				<keyword>pwd</keyword>
				<keyword>rehash</keyword>
				<keyword>rmdir</keyword>
				<keyword>type</keyword>
				<keyword>what</keyword>
				<keyword>which</keyword>
			<!--Search Path-->
				<keyword>addpath</keyword>
				<keyword>genpath</keyword>
				<keyword>path</keyword>
				<keyword>path2rc</keyword>
				<keyword>pathtool</keyword>
				<keyword>rmpath</keyword>
		<!--Programming Tools-->
			<!--Editing and Debugging-->
				<keyword>dbclear</keyword>
				<keyword>dbcont</keyword>
				<keyword>dbdown</keyword>
				<keyword>dbquit</keyword>
				<keyword>dbstack</keyword>
				<keyword>dbstatus</keyword>
			<!--Source Control-->
				<keyword>checkin</keyword>
				<keyword>checkout</keyword>
				<keyword>cmopts</keyword>
				<keyword>customverctl</keyword>
				<keyword>undocheckout</keyword>
				<keyword>verctrl</keyword>
			<!--Notebook-->
				<keyword>notebook</keyword>
		<!--System-->
			<keyword>computer</keyword>
			<keyword>javachk</keyword>
			<keyword>liscense</keyword>
			<keyword>prefdir</keyword>
			<keyword>usejava</keyword>
			<keyword>ver</keyword>
			<keyword>version</keyword>
		<!--Performance Improvement Tools and Techniques-->
			<keyword>memory</keyword>
			<keyword>pack</keyword>
			<keyword>profile</keyword>
			<keyword>profreport</keyword>
			<keyword>rehash</keyword>
			<keyword>sparse</keyword>
			<keyword>zeros</keyword>
		<!--Arrays and Matrices-->
			<!--Basic Information-->
				<keyword>disp</keyword>
				<keyword>display</keyword>
				<keyword>isempty</keyword>
				<keyword>islogical</keyword>
				<keyword>isnumeric</keyword>
				<keyword>issparse</keyword>
				<keyword>length</keyword>
				<keyword>ndims</keyword>
				<keyword>numel</keyword>
				<keyword>size</keyword>
			<!--Operations and Manipulations-->
				<keyword>:</keyword>
				<keyword>blkdiag</keyword>
				<keyword>cat</keyword>
				<keyword>cross</keyword>
				<keyword>cumprod</keyword>
				<keyword>cumsum</keyword>
				<keyword>diag</keyword>
				<keyword>end</keyword>
				<keyword>dot</keyword>
				<keyword>find</keyword>
				<keyword>fliplr</keyword>
				<keyword>flipud</keyword>
				<keyword>flipdim</keyword>
				<keyword>horzcat</keyword>
				<keyword>ind2sub</keyword>
				<keyword>ipermute</keyword>
				<keyword>kron</keyword>
				<keyword>max</keyword>
				<keyword>min</keyword>
				<keyword>permute</keyword>
				<keyword>prod</keyword>
				<keyword>repmat</keyword>
				<keyword>reshape</keyword>
				<keyword>rot90</keyword>
				<keyword>sort</keyword>
				<keyword>sortrows</keyword>
				<keyword>sum</keyword>
				<keyword>sqrtm</keyword>
				<keyword>sub2ind</keyword>
				<keyword>tril</keyword>
				<keyword>triu</keyword>
				<keyword>vertcat</keyword>
			<!--Elemetary Matrices and Arrays-->
				<keyword>eye</keyword>
				<keyword>freqspace</keyword>
				<keyword>linspace</keyword>
				<keyword>logspace</keyword>
				<keyword>meshgrid</keyword>
				<keyword>ndgrid</keyword>
				<keyword>ones</keyword>
				<keyword>rand</keyword>
				<keyword>randn</keyword>
				<keyword>repmat</keyword>
			<!--Specialized Matrices-->
				<keyword>compan</keyword>
				<keyword>gallery</keyword>
				<keyword>hadamard</keyword>
				<keyword>hankel</keyword>
				<keyword>hilb</keyword>
				<keyword>invhilb</keyword>
				<keyword>magic</keyword>
				<keyword>pascal</keyword>
				<keyword>rosser</keyword>
				<keyword>toeplitz</keyword>
				<keyword>vander</keyword>
				<keyword>wilkinson</keyword>
		<!--Linear Algebra-->
			<!--Matrix Analysis-->
				<keyword>cond</keyword>
				<keyword>condeig</keyword>
				<keyword>det</keyword>
				<keyword>norm</keyword>
				<keyword>normest</keyword>
				<keyword>null</keyword>
				<keyword>orth</keyword>
				<keyword>rank</keyword>
				<keyword>rcond</keyword>
				<keyword>rref</keyword>
				<keyword>subspace</keyword>
				<keyword>trace</keyword>
			<!--Linear Equations-->
				<keyword>chol</keyword>
				<keyword>cholinc</keyword>
				<keyword>cond</keyword>
				<keyword>condest</keyword>
				<keyword>funm</keyword>
				<keyword>inv</keyword>
				<keyword>lscov</keyword>
				<keyword>lsqnonneg</keyword>
				<keyword>lu</keyword>
				<keyword>luinc</keyword>
				<keyword>pinv</keyword>
				<keyword>qr</keyword>
				<keyword>rcond</keyword>
			<!--Eigenvalues and Singular Values-->
				<keyword>balance</keyword>
				<keyword>cdf2rdf</keyword>
				<keyword>eig</keyword>
				<keyword>eigs</keyword>
				<keyword>gsvd</keyword>
				<keyword>hess</keyword>
				<keyword>poly</keyword>
				<keyword>polyeig</keyword>
				<keyword>qz</keyword>
				<keyword>rsf2csf</keyword>
				<keyword>schur</keyword>
				<keyword>svd</keyword>
				<keyword>svds</keyword>
			<!--Matrix Logarithms and Exponentials-->
				<keyword>expm</keyword>
				<keyword>logm</keyword>
				<keyword>sqrtm</keyword>
			<!--Factorization-->
				<keyword>chol</keyword>
				<keyword>cholupdate</keyword>
				<keyword>lu</keyword>
				<keyword>luinc</keyword>
				<keyword>planerot</keyword>
				<keyword>qr</keyword>
				<keyword>qrdelete</keyword>
				<keyword>qrinsert</keyword>
				<keyword>qrupdate</keyword>
				<keyword>qz</keyword>
	</keyword-list>
		
	<keyword-list _name = "MATLAB Functions 2" style = "Keyword" case-sensitive="TRUE">
		<!--Elementary Math-->
			<!--Trigonometric-->
				<keyword>acos</keyword>
				<keyword>acosh</keyword>
				<keyword>acot</keyword>
				<keyword>acoth</keyword>
				<keyword>acsc</keyword>
				<keyword>acsch</keyword>
				<keyword>asec</keyword>
				<keyword>asech</keyword>
				<keyword>asin</keyword>
				<keyword>asinh</keyword>
				<keyword>atan</keyword>
				<keyword>atanh</keyword>
				<keyword>atan2</keyword>
				<keyword>cos</keyword>
				<keyword>cosh</keyword>
				<keyword>cot</keyword>
				<keyword>coth</keyword>
				<keyword>csc</keyword>
				<keyword>csch</keyword>
				<keyword>sec</keyword>
				<keyword>sech</keyword>
				<keyword>sin</keyword>
				<keyword>sinh</keyword>
				<keyword>tan</keyword>
				<keyword>tanh</keyword>
			<!--Exponential-->
				<keyword>exp</keyword>
				<keyword>log</keyword>
				<keyword>log2</keyword>
				<keyword>log10</keyword>
				<keyword>nextpow2</keyword>
				<keyword>pow2</keyword>
				<keyword>reallog</keyword>
				<keyword>realpow</keyword>
				<keyword>realsqrt</keyword>
				<keyword>sqrt</keyword>
			<!--Complex-->
				<keyword>abs</keyword>
				<keyword>angle</keyword>
				<keyword>conj</keyword>
				<keyword>cplxpair</keyword>
				<keyword>i</keyword>
				<keyword>imag</keyword>
				<keyword>ireal</keyword>
				<keyword>j</keyword>
				<keyword>real</keyword>
				<keyword>unwrap</keyword>
			<!--Rounding and Remainder-->
				<keyword>fix</keyword>
				<keyword>floor</keyword>
				<keyword>ceil</keyword>
				<keyword>round</keyword>
				<keyword>mod</keyword>
				<keyword>rem</keyword>
				<keyword>sign</keyword>
			<!--Discrete Math (e.g., Prime Factors)-->
				<keyword>factor</keyword>
				<keyword>factorial</keyword>
				<keyword>gcd</keyword>
				<keyword>isprime</keyword>
				<keyword>lcm</keyword>
				<keyword>nchoosek</keyword>
				<keyword>perms</keyword>
				<keyword>primes</keyword>
				<keyword>rat</keyword>
				<keyword>rats</keyword>
		<!--for now-->
      		<keyword>if</keyword>
			<keyword>else</keyword>
			<keyword>while</keyword>
			<keyword>for</keyword>
			<keyword>switch</keyword>
			<keyword>case</keyword>
	</keyword-list>

	<pattern-item _name = "Decimal" style = "Decimal">
		<regex>\b([1-9][0-9]*|0)([Uu]([Ll]|LL|ll)?|([Ll]|LL|ll)[Uu]?)?\b</regex>
	</pattern-item>

	<pattern-item _name = "Floating Point Number" style = "Floating Point">
		<regex>\b([0-9]+[Ee][-]?[0-9]+|([0-9]*\.[0-9]+|[0-9]+\.)([Ee][-]?[0-9]+)?)[fFlL]?</regex>
	</pattern-item>
	
</language>
