Math & ScienceTrouble with maplestd2e package

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
Post Reply
juliette
Posts: 75
Joined: Thu Nov 20, 2008 10:15 pm

Trouble with maplestd2e package

Post by juliette »

First off, is there a separate subforum for the Maple packages for LaTeX ?? If so please send me a link to it!! I guess this subform is the most appropriate place to ask this otherwise.

When I am using :
\usepackage{maplestd2e}

which is the package used for output from Maple, all my formulas start so much further down then I would expect, and vspace{-Xmm} doesn't seem to do anything while using this package, I'm not sure why.

Here is a working example below if you want to see what I mean:

Code: Select all

\documentclass{article}
\usepackage{maplestd2e}
\def\emptyline{\vspace{12pt}}
\begin{document}
\pagestyle{empty}
\DefineParaStyle{Maple Heading 1}
\DefineParaStyle{Maple Text Output}
\DefineParaStyle{Maple Dash Item}
\DefineParaStyle{Maple Bullet Item}
\DefineParaStyle{Maple Normal}
\DefineParaStyle{Maple Heading 4}
\DefineParaStyle{Maple Heading 3}
\DefineParaStyle{Maple Heading 2}
\DefineParaStyle{Maple Warning}
\DefineParaStyle{Maple Title}
\DefineParaStyle{Maple Error}
\DefineCharStyle{Maple Hyperlink}
\DefineCharStyle{Maple 2D Math}
\DefineCharStyle{Maple Maple Input}
\DefineCharStyle{Maple 2D Output}
\DefineCharStyle{Maple 2D Input}
\vspace{-1005mm}
\begin{maplegroup}
\mapleresult
\begin{maplelatex}
\mapleinline{inert}{2d}{H := Matrix(%id = 99892376)}{\[\displaystyle H\, := \, \left[ \begin {array}{ccc} -1/3\,{\frac {{\it C3}_{{\Sigma}}}{{R}^{3}}}+1/3\,{\frac {-{\it C6}_{{\Sigma}}-2\,{\it C6}_{{\Phi}}}{{R}^{6}}}& \left( 1/3\,{\frac {{\it C3}_{{\Sigma}}}{{R}^{3}}}+1/6\,{\frac {-2\,{\it C6}_{{\Phi}}+2\,{\it C6}_{{\Sigma}}}{{R}^{6}}} \right) \sqrt {2}&1/6\,{\frac {{\it C3}_{{\Sigma}}\sqrt {6}}{{R}^{3}}}\\\noalign{\medskip} \left( 1/3\,{\frac {{\it C3}_{{\Sigma}}}{{R}^{3}}}+1/6\,{\frac {-2\,{\it C6}_{{\Phi}}+2\,{\it C6}_{{\Sigma}}}{{R}^{6}}} \right) \sqrt {2}&-2/3\,{\frac {{\it C3}_{{\Sigma}}}{{R}^{3}}}+1/6\,{\frac {-2\,{\it C6}_{{\Phi}}-4\,{\it C6}_{{\Sigma}}}{{R}^{6}}}+{\it deltaE}&1/6\,{\frac {{\it C3}_{{\Sigma}}\sqrt {3}}{{R}^{3}}}\\\noalign{\medskip}1/6\,{\frac {{\it C3}_{{\Sigma}}\sqrt {6}}{{R}^{3}}}&1/6\,{\frac {{\it C3}_{{\Sigma}}\sqrt {3}}{{R}^{3}}}&-{\frac {{\it C6}_{{\Phi}}}{{R}^{6}}}+{\it deltaE}\end {array} \right] \]}
\end{maplelatex}
\end{maplegroup}
\begin{Maple Normal}{
\begin{Maple Normal}{
\mapleinline{inert}{2d}{}{\[\displaystyle \]}
}\end{Maple Normal}
}\end{Maple Normal}
\end{document}

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Trouble with maplestd2e package

Post by localghost »

juliette wrote:First off, is there a separate subforum for the Maple packages for LaTeX ?? If so please send me a link to it!! I guess this subform is the most appropriate place to ask this otherwise. [...]
I think that there is no better place for this request because Maple is really related to mathematics and science.

Your approach is basically correct. The only thing you didn't take into account is the fact that vertical spaces set with the \vspace command are ignored at the beginning of a page. You have to use the starred version.

Code: Select all

\vspace*{-3\baselineskip}
You can test if vertical spacing is necessary by inserting some text before the maplegroup environment.


Best regards
Thorsten¹
Post Reply