@ecterrab
THanks. I included the packages that I thought I needed. After all, I am only exporting some math and text, so I thought that is what needed is.
\usepackage{amsmath}
\usepackage{array}
\usepackage{maple}
But now I exported the latex file itself. i.e. I typed in new worksheet the following
restart;
Student:-Calculus1:-ShowSolution(Int(x^3,x=0..1));
Then did file->export as->Latex after evaluating the above.
Two issues: The latex file does not compile. it gives error
>pdflatex t.tex
This is pdfTeX, Version 3.14159265-2.6-1.40.21 (TeX Live 2020) (preloaded format=pdflatex)
restricted \write18 enabled.
entering extended mode
(./t.tex
.............
! Undefined control sequence.
<argument> \[\begin {array}{ccc} & & \textrm {Integration Steps} \\ & & \int _{0}^{1}x^{3}dx \\ \textrm {â–«} & & \textrm {1. Apply the}\boldsymbol {\textrm {power}}\textrm {rule to the term}\intx
^{3}dx \\ & \textrm {â—¦} & \textrm {Recall the defini...
l.75 \end{array}\]}
?
I am using current texlive.
Second issue: Maple generates \usepackage{breqn}
This package breqn is known to cause massive problems as it redfined many things. I stopped using it long time ago as it could break latex compilation due to conflict with other package. There are many post about this in tex forum. It will be best if Maple latex export does not use this package at all.
Please see worksheet attached. I wonder if the above latex file generated compiles OK for others. Here is the latex file generated by Maple.
%% Created by Maple 2021.0, Windows 10
%% Source Worksheet: t
%% Generated: Sun Mar 28 15:07:48 CDT 2021
\documentclass{article}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage{hyperref}
\usepackage{listings}
\usepackage{mathtools}
\usepackage{maple}
\usepackage[utf8]{inputenc}
\usepackage[svgnames]{xcolor}
\usepackage{amsmath}
\usepackage{breqn}
\usepackage{textcomp}
\begin{document}
\lstset{basicstyle=\ttfamily,breaklines=true,columns=flexible}
\pagestyle{empty}
\DefineParaStyle{Maple Bullet Item}
\DefineParaStyle{Maple Heading 1}
\DefineParaStyle{Maple Warning}
\DefineParaStyle{Maple Heading 4}
\DefineParaStyle{Maple Heading 2}
\DefineParaStyle{Maple Heading 3}
\DefineParaStyle{Maple Dash Item}
\DefineParaStyle{Maple Error}
\DefineParaStyle{Maple Title}
\DefineParaStyle{Maple Ordered List 1}
\DefineParaStyle{Maple Text Output}
\DefineParaStyle{Maple Ordered List 2}
\DefineParaStyle{Maple Ordered List 3}
\DefineParaStyle{Maple Normal}
\DefineParaStyle{Maple Ordered List 4}
\DefineParaStyle{Maple Ordered List 5}
\DefineCharStyle{Maple 2D Output}
\DefineCharStyle{Maple 2D Input}
\DefineCharStyle{Maple Maple Input}
\DefineCharStyle{Maple 2D Math}
\DefineCharStyle{Maple Hyperlink}
\begin{lstlisting}
> interface(version);
Physics:-Version();
\end{lstlisting}
% \mapleresult
\begin{maplelatex}
\mapleinline{inert}{2d}{}
{\[\mathit{Standard\,Worksheet\,Interface,\,Maple\,2021.0,\,Windows\,10,\,March\,5\,2021\,Build\,ID\,1523359\,} \]}
\end{maplelatex}
% \mapleresult
\begin{maplelatex}
\mapleinline{inert}{2d}{}
{\[\mathit{The\,``Physics\,Updates"\,version\,in\,the\,MapleCloud\,is\,938\,and\,is\,the\,same\,as\,the\,version\,installed\,in\,this\,computer,\,created\,2021,\,March\,27,\,12:39\,hours\,Pacific\,Time.\,} \]}
\end{maplelatex}
\begin{lstlisting}
> restart;
\end{lstlisting}
\begin{lstlisting}
> Student:-Calculus1:-ShowSolution(Int(x^3,x=0..1));
\end{lstlisting}
% \mapleresult
\begin{maplelatex}
\mapleinline{inert}{2d}{}
{\[\begin{array}{ccc}
& & \textrm{Integration Steps}
\\
& & \int_{0}^{1}x^{3}dx
\\
\textrm{â–«} & & \textrm{1. Apply the}\boldsymbol{\textrm{power}}\textrm{rule to the term}\intx^{3}dx
\\
& \textrm{â—¦} & \textrm{Recall the definition of the}\boldsymbol{\textrm{power}}\textrm{rule, for n}\textrm{≠}
\\
\textrm{-1}
\\
& & \intx^{n}dx =\frac{x^{n +1}}{n +1}
\\
& \textrm{â—¦} & \textrm{This means:}
\\
& & \intx^{3}dx =\frac{x^{3+1}}{3+1}
\\
& \textrm{â—¦} & \textrm{So,}
\\
& & \intx^{3}dx =\frac{x^{4}}{4}
\\
& \textrm{â—¦} & \textrm{Apply limits of definite integral}
\\
& & \frac{x^{4}}{4}{\raisebox{-0.36em}{$\Big |$}}{\mstack{}{_{x \hiderel{=}1}}}-\left(\frac{x^{4}}{4}{\raisebox{-0.36em}{$\Big |$}}{\mstack{}{_{x \hiderel{=}0}}}\right)
\\
& & \textrm{We can rewrite the integral as:}
\\
& & \frac{1}{4}
\end{array}\]}
\end{maplelatex}
\begin{lstlisting}
>
\end{lstlisting}
\begin{lstlisting}
>
\end{lstlisting}
\end{document}
t.mw