Latex output bugs?
Publié : sam. oct. 10, 2020 5:31 pm
I have been using the latex output for elegant printouts of work and when I started to use units in the calculations I think I noticed a few bugs.
Please find attached a diff printout of the tex file produced by Xcas with the modifications I needed to do to prevent errrors when creating a PDF. When I ran: latex <my original tex file> in cygwin I got the following errors:
! Missing { inserted.
<to be read again>
\left
l.96 \mathrm{Rl}=(_\left
(1,\mathrm{\_ft}\right)) \\
?
! Missing } inserted.
<inserted text>
}
l.96 ...hrm{Rl}=(_\left(1,\mathrm{\_ft}\right)) \\
?
Underfull \hbox (badness 10000) in paragraph at lines 99--101
[2]
! Missing { inserted.
<to be read again>
\left
l.102 \mathrm{Dl}=(_\left
(0.785398163397,\mathrm{\_ft}\right))
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.103 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.103 \end{equation}
?
Underfull \hbox (badness 10000) in paragraph at lines 103--105
! Missing { inserted.
<to be read again>
\left
l.106 \mathrm{Al}=(_\left
(512.065886703,\frac{\mathrm{\_ft}^{2}\cdot \mathrm...
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.107 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.107 \end{equation}
?
Underfull \hbox (badness 10000) in paragraph at lines 107--109
! Missing { inserted.
<to be read again>
\left
l.110 \mathrm{Al}=(_\left
(512.065886703,\frac{\mathrm{\_ft}}{\mathrm{\_s}^{2...
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.111 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.111 \end{equation}
?
Underfull \hbox (badness 10000) in paragraph at lines 111--113
Underfull \hbox (badness 10000) in paragraph at lines 111--113
Underfull \hbox (badness 10000) in paragraph at lines 115--117
! Missing { inserted.
<to be read again>
\left
l.118 \mathrm{Fl}=(_\left
(512.065886703,\frac{\mathrm{\_ft}\cdot \mathrm{\_l...
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.119 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.119 \end{equation}
?
Underfull \hbox (badness 10000) in paragraph at lines 119--121
! Missing { inserted.
<to be read again>
\left
l.122 \mathrm{Fl}=(_\left
(15.9119171679,\mathrm{\_lbf}\right))
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.123 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.123 \end{equation}
?
I also attached the PDF produced by the "repaired" tex file.
The following is a bash script that I use as a work around right now to "fix" the tex file.
sed '
s/_\\left/\\left/g
s/,\\/\\/g
/(\\/{/))$/{s/(\\/\\/; s/))$/)/}}
/(\\/{/))[ \]*$/{s/(\\/\\/; s/))\([ \]*\)$/)\1/}}
' $1
Please find attached a diff printout of the tex file produced by Xcas with the modifications I needed to do to prevent errrors when creating a PDF. When I ran: latex <my original tex file> in cygwin I got the following errors:
! Missing { inserted.
<to be read again>
\left
l.96 \mathrm{Rl}=(_\left
(1,\mathrm{\_ft}\right)) \\
?
! Missing } inserted.
<inserted text>
}
l.96 ...hrm{Rl}=(_\left(1,\mathrm{\_ft}\right)) \\
?
Underfull \hbox (badness 10000) in paragraph at lines 99--101
[2]
! Missing { inserted.
<to be read again>
\left
l.102 \mathrm{Dl}=(_\left
(0.785398163397,\mathrm{\_ft}\right))
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.103 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.103 \end{equation}
?
Underfull \hbox (badness 10000) in paragraph at lines 103--105
! Missing { inserted.
<to be read again>
\left
l.106 \mathrm{Al}=(_\left
(512.065886703,\frac{\mathrm{\_ft}^{2}\cdot \mathrm...
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.107 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.107 \end{equation}
?
Underfull \hbox (badness 10000) in paragraph at lines 107--109
! Missing { inserted.
<to be read again>
\left
l.110 \mathrm{Al}=(_\left
(512.065886703,\frac{\mathrm{\_ft}}{\mathrm{\_s}^{2...
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.111 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.111 \end{equation}
?
Underfull \hbox (badness 10000) in paragraph at lines 111--113
Underfull \hbox (badness 10000) in paragraph at lines 111--113
Underfull \hbox (badness 10000) in paragraph at lines 115--117
! Missing { inserted.
<to be read again>
\left
l.118 \mathrm{Fl}=(_\left
(512.065886703,\frac{\mathrm{\_ft}\cdot \mathrm{\_l...
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.119 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.119 \end{equation}
?
Underfull \hbox (badness 10000) in paragraph at lines 119--121
! Missing { inserted.
<to be read again>
\left
l.122 \mathrm{Fl}=(_\left
(15.9119171679,\mathrm{\_lbf}\right))
?
! You can't use `\eqno' in math mode.
\endequation ->\eqno
\hbox {\@eqnnum }$$\@ignoretrue
l.123 \end{equation}
?
! Missing } inserted.
<inserted text>
}
l.123 \end{equation}
?
I also attached the PDF produced by the "repaired" tex file.
The following is a bash script that I use as a work around right now to "fix" the tex file.
sed '
s/_\\left/\\left/g
s/,\\/\\/g
/(\\/{/))$/{s/(\\/\\/; s/))$/)/}}
/(\\/{/))[ \]*$/{s/(\\/\\/; s/))\([ \]*\)$/)\1/}}
' $1