Loïc Grenié on Mon, 11 Mar 2024 13:24:25 +0100 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: which LaTeX package for Pari/GP scripts ? |
Hello,
I'm currently writing an article where most results were computed with a Pari/GP script. I would like to include it in the methods section, and tried the 'listings' package to do so. Unfortunately, this package does not properly handle Pari comments (\\ seems to be a nightmare for LaTeX).
I even tired to define Pari as a new language, with :
\lstdefinelanguage{parigp}
{ morekeywords={for,if,sum,binomial,my,eval,print,return,vector,write},%
sensitive=true,%
morecomment=[l]{//},%
morecomment=[s]{/*}{*/},%
literate={//}{\textbackslash\textbackslash}{2},
}
but to no avail...