tmath-definitions.txt - pism - [fork] customized build of PISM, the parallel ice sheet model (tillflux branch)
 (HTM) git clone git://src.adamsgaard.dk/pism
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) LICENSE
       ---
       tmath-definitions.txt (2692B)
       ---
            1 .. -*- mode: rst -*-
            2 
            3 .. math stuff
            4 
            5 .. \newcommand has to appear in a math environment for MathJax to use it. Unfortunately
            6    \newcommand included in a math environment in LaTeX is limited to this environment, so
            7    we need to define custom commands twice: once for HTML (MathJax), once for LaTeX.
            8 
            9 .. only:: html
           10 
           11    .. math::
           12 
           13       \newcommand{\Diff}[2]{ \frac{\mathrm{d}#1}{\mathrm{d}#2} }
           14       \newcommand{\diff}[2]{ \frac{\partial #1}{\partial #2} }
           15       \newcommand{\var}[2]{ {#1}_{\text{#2}} }
           16       \newcommand{\h}[1]{ \var{h}{#1} }
           17       \newcommand{\T}[1]{ \var{T}{#1} }
           18       \newcommand{\m}[1]{ \var{m}{#1} }
           19       \newcommand{\ms}[1]{ \var{m^{*}}{#1} }
           20       \newcommand{\psw}{p_{\text{ocean}}}
           21       \newcommand{\pice}{p_{\text{ice}}}
           22       \newcommand{\pmelange}{p_{\text{melange}}}
           23       \newcommand{\n}{\mathbf{n}}
           24       \newcommand{\nx}{\n_{x}}
           25       \newcommand{\ny}{\n_{y}}
           26       \newcommand{\phimin}{\phi_{\mathrm{min}}}
           27       \newcommand{\phimax}{\phi_{\mathrm{max}}}
           28       \newcommand{\bmin}{b_{\mathrm{min}}}
           29       \newcommand{\bmax}{b_{\mathrm{max}}}
           30       \newcommand{\bq}{\mathbf{q}}
           31       \newcommand{\Up}[2]{\operatorname{Up}\left(#1\big|#2\right)}
           32       \newcommand{\uppair}[2]{\left\{\begin{matrix} #1 \\ #2 \end{matrix}\right\}}
           33       \newcommand{\div}{\nabla \cdot}
           34       \newcommand{\V}{\mathbf{V}}
           35       \newcommand{\Wtill}{W_{\mathrm{till}}}
           36 
           37 .. raw:: latex
           38 
           39    % We use \providecommand here so that these can be repeated several times.
           40 
           41    % generic
           42    \providecommand{\Diff}[2]{ \frac{\mathrm{d}#1}{\mathrm{d}#2} }
           43    \providecommand{\diff}[2]{ \frac{\partial #1}{\partial #2} }
           44    \providecommand{\div}{\nabla \cdot}
           45 
           46    % elevation-dependent surface model
           47    \providecommand{\var}[2]{ {#1}_{\text{#2}} }
           48    \providecommand{\h}[1]{ \var{h}{#1} }
           49    \providecommand{\T}[1]{ \var{T}{#1} }
           50    \providecommand{\m}[1]{ \var{m}{#1} }
           51    \providecommand{\ms}[1]{ \var{m^{*}}{#1} }
           52 
           53    % Melange
           54    \providecommand{\psw}{p_{\text{ocean}}}
           55    \providecommand{\pice}{p_{\text{ice}}}
           56    \providecommand{\pmelange}{p_{\text{melange}}}
           57    \providecommand{\n}{\mathbf{n}}
           58    \providecommand{\nx}{\n_{x}}
           59    \providecommand{\ny}{\n_{y}}
           60 
           61    % Basal strength
           62    \providecommand{\phimin}{\phi_{\mathrm{min}}}
           63    \providecommand{\phimax}{\phi_{\mathrm{max}}}
           64    \providecommand{\bmin}{b_{\mathrm{min}}}
           65    \providecommand{\bmax}{b_{\mathrm{max}}}
           66 
           67    % hydrology
           68    \providecommand{\bq}{\mathbf{q}}
           69    \providecommand{\V}{\mathbf{V}} % velocity vector
           70    \providecommand{\Wtill}{W_{\mathrm{till}}}
           71 
           72    % BOMBPROOF
           73    \providecommand{\Up}[2]{\operatorname{Up}\left(#1\big|#2\right)}
           74    \providecommand{\uppair}[2]{\left\{\begin{matrix} #1 \\ #2 \end{matrix}\right\}}