\chapter{Programs}

\section{MATLAB script}
\label{sec:matlabscript}
% This file was automatically created from the m-file 
% "m2tex.m" written by USL. 
% The fontencoding in this file is UTF-8. 
%  
% You will need to include the following two packages in 
% your LaTeX-Main-File. 
%  
% \usepackage{color} 
% \usepackage{fancyvrb} 
%  
% It is advised to use the following option for Inputenc 
% \usepackage[utf8]{inputenc} 
%  
  
% definition of matlab colors: 
\definecolor{mblue}{rgb}{0,0,1} 
\definecolor{mgreen}{rgb}{0.13333,0.5451,0.13333} 
\definecolor{mred}{rgb}{0.62745,0.12549,0.94118} 
\definecolor{mgrey}{rgb}{0.5,0.5,0.5} 
\definecolor{mdarkgrey}{rgb}{0.25,0.25,0.25} 
  
\DefineShortVerb[fontfamily=courier,fontseries=m]{\$} 
\DefineShortVerb[fontfamily=courier,fontseries=b]{\#} 
  
\noindent                          
 \hspace*{-1.6em}{\scriptsize 1}$  $\color{mblue}$function$\color{black}$ sum=sumentropy(sig,x,R,N)$\\
 \hspace*{-1.6em}{\scriptsize 2}$  $\color{mgreen}$%For every step in the axial direction, x, sum all the cells from 0 to$\color{black}$$\\
 \hspace*{-1.6em}{\scriptsize 3}$  $\color{mgreen}$%r_max of the flame. Output is a vector including the sum of the entropy$\color{black}$$\\
 \hspace*{-1.6em}{\scriptsize 4}$  $\color{mgreen}$%production at every axial point x from the fuel outlet.$\color{black}$$\\
 \hspace*{-1.6em}{\scriptsize 5}$  $\color{mgreen}$%R(i,j) is considered to be the center of every cell (x,r) in the flat$\color{black}$$\\
 \hspace*{-1.6em}{\scriptsize 6}$  $\color{mgreen}$%plane.$\color{black}$$\\
 \hspace*{-1.6em}{\scriptsize 7}$  $\\
 \hspace*{-1.6em}{\scriptsize 8}$  S_sum=zeros(length(x),1);$\\
 \hspace*{-1.6em}{\scriptsize 9}$      $\color{mblue}$for$\color{black}$ i=1:length(x)$\\
 \hspace*{-2em}{\scriptsize 10}$          $\color{mblue}$if$\color{black}$ i==1$\\
 \hspace*{-2em}{\scriptsize 11}$              dx=x(1);$\\
 \hspace*{-2em}{\scriptsize 12}$          $\color{mblue}$else$\color{black}$$\\
 \hspace*{-2em}{\scriptsize 13}$              dx=x(i)-x(i-1);$\\
 \hspace*{-2em}{\scriptsize 14}$          $\color{mblue}$end$\color{black}$$\\
 \hspace*{-2em}{\scriptsize 15}$          $\\
 \hspace*{-2em}{\scriptsize 16}$          $\color{mblue}$for$\color{black}$ j=1:N(i)$\\
 \hspace*{-2em}{\scriptsize 17}$              $\color{mblue}$if$\color{black}$ j==1$\\
 \hspace*{-2em}{\scriptsize 18}$                  dr=0.5*(R(i,j+1)-R(i,j));$\\
 \hspace*{-2em}{\scriptsize 19}$              $\color{mblue}$else$\color{black}$$\\
 \hspace*{-2em}{\scriptsize 20}$                  dr=R(i,j)-R(i,j-1);$\\
 \hspace*{-2em}{\scriptsize 21}$              $\color{mblue}$end$\color{black}$$\\
 \hspace*{-2em}{\scriptsize 22}$              S_sum(i)=S_sum(i)+2*pi*R(i,j)*sig(i,j)*dr*dx;$\\
 \hspace*{-2em}{\scriptsize 23}$          $\color{mblue}$end$\color{black}$$\\
 \hspace*{-2em}{\scriptsize 24}$      $\color{mblue}$end$\color{black}$$\\
 \hspace*{-2em}{\scriptsize 25}$      sum=S_sum;$\\
 \hspace*{-2em}{\scriptsize 26}$  $\color{mblue}$end$\color{black}$$\\ 
  
\UndefineShortVerb{\$} 
\UndefineShortVerb{\#}

\section{Maple routine}
\label{sec:mapleroutine}
\includegraphics[width=\columnwidth,page=1]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=2]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=3]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=4]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=5]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=6]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=7]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=8]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=9]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=10]{entropyprod_curvefits.pdf}
\includegraphics[width=\columnwidth,page=11]{entropyprod_curvefits.pdf}
