• AGUTeX changes angle brackets in DOIs
    by Tor on December 25, 2025 at 6:28 pm

    I'm writing a paper for an AGU journal, using the AGUTeX templates. I have a reference with a DOI that contains angle brackets (I'm using the term "angle brackets" loosely here). The correct DOI is 10.1175/1520-0493(1997)125<2293:ROTBSC>2.0.CO;2 This DOI is listed in the doi field in the reference in the .bib file. After typesetting, the DOI listed in the compiled pdf has different angle brackets: 10.1175/1520-0493(1997)125⟨2293: ROTBSC⟩2.0.CO;2 In the pdf I build with the AGUTeX class myself, the DOI is just listed as text, but in the version the journal builds the DOIs are given as clickable URLs, and this link then naturally leads to a page that says DOI NOT FOUND for this reference, as well as other references with angle brackets. Has anyone else come across this issue? And is it possible to find out which lines of code in the AGUTeX class is responsible for the switch? For completeness, here is a minimal example tex-file and bib-file to reproduce this, using the class agujournal2019 available on overleaf (and as mentioned, the error also exists in the pdf with the page proofs I received from the journal, so this or something similar is presumably also what they use in-house). tex-file: \documentclass[draft]{agujournal2019} \draftfalse \journalname{Journal name} \begin{document} \title{Title} \cite{adcroft1997} \bibliography{agusample} \end{document} bib-file: @article{adcroft1997, title = {Representation of {{Topography}} by {{Shaved Cells}} in a {{Height Coordinate Ocean Model}}}, author = {Adcroft, Alistair and Hill, Chris and Marshall, John}, year = {1997}, journal = {Monthly Weather Review}, volume = {125}, number = {9}, pages = {2293--2315}, doi = {10.1175/1520-0493(1997)125<2293:ROTBSC>2.0.CO;2}, }

  • tex4ebook: How to customize section names and include them in the ToC
    by Jack on December 25, 2025 at 3:43 pm

    I am trying to customize section names add them correctly to the ToC While I found a working solution for a standard tex document using the \titleformat from the titlesec package, I have to issues with when doing the same for an ebook: The customized title is not used in the headline of the relevant sections While I can manually add a new line to the ToC even with my customized title, the \protect\setcounter{tocdepth}{0} command does not surpress the standard section line to appear in the ToC, i.e. I now have the sections twice in the ToC Is there a way to solve this so that it looks similar to what is shown when compiling a pdf instead of an ebook? Here is an MWE that works for pdf but has the above issues for an ebook: \documentclass{book} \usepackage{tex4ebook} \usepackage{cleveref} \usepackage{titlesec} \titleformat{\section}{\normalfont\Large\bfseries}{My Section~\thesection}{1em}{} \renewcommand{\thesection}{\arabic{section}} \begin{document} \tableofcontents \addtocontents{toc}{\protect\setcounter{tocdepth}{0}} \section{Headline} \label{sec:Headline} \addtocontents{toc}{\protect\setcounter{tocdepth}{2}} \addcontentsline{toc}{section}{My Section \thesection \hspace{1em} Headline} Some text. \addtocontents{toc}{\protect\setcounter{tocdepth}{0}} \section{Another headline} \addtocontents{toc}{\protect\setcounter{tocdepth}{2}} \addcontentsline{toc}{section}{My Section \thesection \hspace{1em} Another headline} Some text. \end{document} and the relevant cfg file \Preamble{xhtml} \Css{nav ol li{ list-style-type: none; }} \begin{document} \EndPreamble

  • How to make a straight-line stroke that transitions from thick to thin in METAFONT?
    by Grzegorz Brzczyszczykiewicz on December 25, 2025 at 1:32 pm

    is it possible to make a stroke that transitions from thick to thin, like a Chinese brush or a calligraphy pen? Not like a bent hook that fakes the transition using elliptical pens, that one is cheating. I want a perfectly straight line, that starts out thick and transitions to thin. Is it possible to do such a "dynamic brush" effect"?

  • Precision issue with Tikz tangent coordinate system
    by I. Cho on December 25, 2025 at 12:21 pm

    The TikZ tangent coordinate system appears to be inaccurate. The blue and red lines are expected to overlap, but they fail to do so. \documentclass{standalone} \usepackage{tikz} \usetikzlibrary{calc} \begin{document} \begin{tikzpicture} \draw [help lines,dotted,thick] (0,0) grid (10,10); \def\rA{.5} \def\rB{4} \coordinate (OA) at (1,1); \coordinate (OB) at (5,5); \path (OA) node (A) [draw,circle,minimum size=2*\rA cm] {A}; \path (OB) node (B) [draw,circle,minimum size=2*\rB cm] {B}; \path ($(A.center)!{\rA/(\rA - \rB)}!(B.center)$) coordinate (X) node [below left] {X}; \path (tangent cs:node=A,point={(X)},solution=1) coordinate (A1); \path (tangent cs:node=A,point={(X)},solution=2) coordinate (A2); \path (tangent cs:node=B,point={(X)},solution=1) coordinate (B1); \path (tangent cs:node=B,point={(X)},solution=2) coordinate (B2); \draw [blue] (X) -- (A1) -- ([turn]0:9cm); \draw [red] (X) -- (B1) -- ([turn]0:5cm); \draw [blue] (X) -- (A2) -- ([turn]0:9cm); \draw [red] (X) -- (B2) -- ([turn]0:5cm); \end{tikzpicture} \end{document} Corrected by adding outer sep=0pt: \documentclass{standalone} \usepackage{tikz} \usetikzlibrary{calc} \begin{document} \begin{tikzpicture} \draw [help lines,dotted,thick] (0,0) grid (10,10); \def\rA{.5} \def\rB{4} \coordinate (OA) at (1,1); \coordinate (OB) at (5,5); \path (OA) node (A) [draw,circle,minimum size=2*\rA cm,outer sep=0pt] {A}; %% \path (OB) node (B) [draw,circle,minimum size=2*\rB cm,outer sep=0pt] {B}; %% \path ($(A.center)!{\rA/(\rA - \rB)}!(B.center)$) coordinate (X) node [below left] {X}; \path (tangent cs:node=A,point={(X)},solution=1) coordinate (A1); \path (tangent cs:node=A,point={(X)},solution=2) coordinate (A2); \path (tangent cs:node=B,point={(X)},solution=1) coordinate (B1); \path (tangent cs:node=B,point={(X)},solution=2) coordinate (B2); \draw [blue] (X) -- (A1) -- ([turn]0:9cm); \draw [red] (X) -- (B1) -- ([turn]0:5cm); \draw [blue] (X) -- (A2) -- ([turn]0:9cm); \draw [red] (X) -- (B2) -- ([turn]0:5cm); \end{tikzpicture} \end{document}

  • text4ebook: How to include graphics in nested enumerate environments to correctly fit ebook page size?
    by Jack on December 25, 2025 at 12:05 pm

    I am trying to include pictures in a nested enumerate environment and want to make sure they fit the screen size correctly. After playing around a while, I am now using the \adjustbox{\linewidth} command, which works well outside of the environment as well as on the first level of an enumerate environment. However, if I have nested environments, the picture runs out of the screen on the second level (at least with Kindle reader and Google Play Books reader - with Calibri it seems to work still on the second level). Is there a way to correctly fit the size on the second level also for readers like Kindle or Google Play Books? Here is an MWE: \documentclass{book} \usepackage{tex4ebook} \begin{document} First enumerate level: \begin{enumerate} \item On this level, pictures work well \adjustbox{\linewidth}{\includegraphics{Picture.png}} Second enumerate level: \begin{enumerate} \item On this level, pictures run over the screen even with linewidth setting: \adjustbox{\linewidth}{\includegraphics{Picture.png}} \end{enumerate} \end{enumerate} \end{document}

  • nicematrix, \CodeAfter and overlapping
    by projetmbc on December 25, 2025 at 11:11 am

    Is there an automatic way to avoid "TikZ code after" overlap the text? I give a real use case, and not a MWE. \documentclass[12pt]{scrartcl} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage[top=1cm, bottom=1.95cm, left=.9cm, right=.9cm]{geometry} \usepackage{nicematrix} \usepackage[svgnames]{xcolor} \usepackage{tikz] \tikzset{ product/.style = { shorten > = 3.75mm, thick }, product-times/.style = { pos=0.5, circle, fill=white, inner sep=2pt }, arrow/.style = { ->, thick }, rounded-frame/.style = { draw, rounded corners, thick, inner sep = 5pt, anchor = west } } \begin{document} XXX $\begin{NiceArray}{*{9}{c}}[cell-space-limits=3pt] & & & & & & & & C_j^{\,\prime} \\ & & & & & & & & \phantom{X} \\ & & & & & & & & \Vdots[shorten-start=11pt] \\ & & & & & & & & \color{IndianRed}a[k]_{qj} \\ & & & & & & & & \Vdots \\ & & & & & & & & \color{ForestGreen} a[k]_{rj} \\ & & & & & & & & \Vdots[shorten-end=21pt] \\ & & \NotEmpty & & & & \NotEmpty & & \\ L_i & \hspace{3pt} & \Cdots[shorten-start=18pt] & \color{IndianRed} 1 & \Cdots & \color{ForestGreen} 0 & \Cdots[shorten-end=18pt] & \hspace{12.5pt} & a[k{+}1]_{ij} % \CodeAfter % Sous-matrices. \SubMatrix({3-9}{7-9})[slim] \SubMatrix({9-3}{9-7}) \SubMatrix({9-9}{9-9}) % Décorons... \begin{tikzpicture} % Indication pour la ligne et la colonne. \draw[ arrow, shorten > = 8mm, ] (1-9.south) to (4-9.north); \draw[ arrow, shorten < = 1mm, shorten > = 9.5mm, ] (9-1.east) to (9-4.west); % Flèches des produits. \draw[ product, IndianRed, ] (9-4.north) to [bend left] node[ product-times, draw = IndianRed, ] {$\times$} (4-9.west); \draw[ product, ForestGreen, ] (9-6.north) to [bend left] node[ product-times, draw = ForestGreen ] {$\times$} (6-9.west) ; % Signification des entrées. \draw[ arrow, ForestGreen, ] ([yshift=-5mm]9-6.south) to (9-6.south); \node[ rounded-frame, ForestGreen ] at ([yshift=-8.1mm, xshift=-2mm]9-6.south) {Pas de lien direct de $i$ à $r$.}; % \draw[ arrow, IndianRed, ] ([yshift=-13.5mm]9-4.south) to (9-4.south); \node[ rounded-frame, IndianRed ] at ([yshift=-17mm, xshift=-2mm]9-4.south) {Un lien direct de $i$ à $q$.}; % \draw[ arrow, IndianRed ] ([xshift=8.5mm] 4-9.east) to ([xshift=3.5mm] 4-9.east); \node[ rounded-frame, IndianRed, ] at ([xshift=8.5mm] 4-9.east) {Nombre de parcours de longueur $k$ de $q$ à $j$.}; % \draw[ arrow, ForestGreen, ] ([xshift=8.5mm] 6-9.east) to ([xshift=3.5mm] 6-9.east); \node[ rounded-frame, ForestGreen, ] at ([xshift=8.5mm] 6-9.east) {Nombre de parcours de longueur $k$ de $r$ à $j$.}; \end{tikzpicture} \end{NiceArray}$ XXX \end{document}

  • tex4ebook: How to make a table run over more than one page being shown correctly in Google Play Books
    by Jack on December 25, 2025 at 10:27 am

    I am trying to make a long table that may run over more than one page in an ebook using the tabularx package. While the table on the first page is shown correctly in Google Play Books and while it indeed runs over more than one page, the vertical lines of the table suddenly disappear on the second page, i.e. only the horizontal lines are shown on the second page. The text is shown correctly, so it's really only the vertical lines that disappear. Is there a way how to make such a table being displayed correctly? Here is an MWE: \documentclass{book} \usepackage{tabularx} \usepackage{tex4ebook} \begin{document} \begin{tabularx}{\linewidth}{| X | c | X |} \hline \textbf{\textit{Column 1}} & \textbf{\textit{Column 2}} & \textbf{\textit{Column 3}} \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline Some Text & More text & Even more text \\ \hline \end{tabularx} \end{document}

  • Problems using latexdiff with minted
    by Andymang on December 25, 2025 at 1:27 am

    I am trying to get a diff between two versions of my thesis. The first command I tried using is: git latexdiff -v --main thesis.tex -o diff.pdf --flatten --latexmk --latexopt -shell-escape defended HEAD This failed. When I inspected the log, I discovered one of the errors to be: ! Missing $ inserted. <inserted text> $ l.1172 } %DIFDELCMD < }%%% I've inserted a begin-math/end-math symbol since I think you left one out. Proceed, with fingers crossed. Here is an excerpt of the diff.tex where that's from: %DIFDELCMD < \begin{minted}[breaklines]{json} %DIFDELCMD < { %DIFDELCMD < %%% \DIFdel{"interval": }%DIFDELCMD < { %DIFDELCMD < %%% \DIFdel{"start_millis": 0, "end_millis": 13 }%DIFDELCMD < }%%% \DIFdel{, "all": }%DIFDELCMD < { %DIFDELCMD < %%% And here is an excerpt form the old file thesis.tex: \begin{minted}[breaklines]{json} { "interval": { "start_millis": 0, "end_millis": 13 }, "all": { The problem appears to be that underscores were counting as a math symbol once they were taken out of the minted environment and put in a \DIFdel command. I can't just escape the underscores like \_ in the original input, because then the backslashes show up in the PDF. So I asked ChatGPT, which led me to try setting the VERBATIMLINEENV and --append-safecmd options: git latexdiff -v --main thesis.tex -o diff.pdf --flatten --latexmk --config "VERBATIMLINEENV=minted" --append-safecmd=mintinline --append-safecmd=inputminted --latexopt -shell-escape defended-fixed HEAD But that doesn't work, either. Here is one of the error messages that produces: ! Package pgfkeys Error: I do not know the key '/minted/cmd/alsolanguage', to w hich you passed 'DIFcode', and I am going to ignore it. Perhaps you misspelled it. And the diff.tex: %DIFDELCMD < \begin{minted}[breaklines]%%% %DIFAUXCMD NEXT \DIFmodbegin \begin{minted}[breaklines,alsolanguage=DIFcode] %DIF < { %DIF < "interval": { %DIF < "start_millis": 0, %DIF < "end_millis": 13 %DIF < }, %DIF < "all": { It looks like it is trying to pass the alsolanguage option to minted, which doesn't support it. I don't know if this is the fatal error that is causing the pdf not to compile. Here is the next error: ! Argument of \end has an extra }. <inserted text> \par l.1244 \end {minted} I've run across a `}' that doesn't seem to match anything. For example, `\def\a#1{...}' and `\a}' would produce this error. If you simply proceed now, the `\par' that I've just inserted will cause me to report a runaway argument that might be the root of the problem. But if your `}' was spurious, just type `2' and it will go away. I don't know if this next error is caused by the first one or not. What are my options here? I want the differences in the minted block to show up. Minimal Reproducible Example a.tex: \documentclass{article} \usepackage{minted} \begin{document} \begin{minted}{text} something_here \end{minted} \end{document} b.tex: \documentclass{article} \usepackage{minted} \begin{document} \end{document} Commands: latexdiff a.tex b.tex > diff.tex pdflatex -shell-escape diff.tex Output: ! Missing $ inserted. <inserted text> $ l.50 } %DIFDELCMD < \end{minted} ?

  • What are the advantages of environments over macros (and of \NewDocumentEnvironment over \NewDocumentCommand)?
    by Alexey on December 24, 2025 at 9:24 pm

    I noticed that when I start from a custom environment, and then decide to do something slightly non-trivial with its content (like hide it, or typeset in a different color), I end up switching to a custom macro with an argument. Consider, for example, these questions: Hide custom environment content based on boolean Environment hiding its content I have no idea how to make the content of an environment disappear without using packages like comment or version or scontents. On the other hand, this is trivial to do with a custom macro: just (re)define the macro as a no-op: \newcommand\comment[1]{}. It looks to me that any environment could be replaced with a macro, to have \theorem{...} instead of \begin{theorem}...\end{theorem}, etc. On the other hand, I do not know how to make an environment that, for example, duplicates or discards its content, or puts it in a box. What are the advantages of environments over macros that offset the inconveniences? P.S. IMO the environ package takes the correct approach.

  • How can I make an image extend into the line spacing?
    by Draconis on December 24, 2025 at 9:02 pm

    I'm working on a document about an obscure writing system, which means I often need to insert images of the glyphs I'm talking about. So far I've been putting them inline, using the following code: \usepackage{calc} % Calculate the proper height for inline signs \usepackage{graphicx} \graphicspath{{./images/}} \newlength{\normaldepth} \makeatletter \DeclareRobustCommand{\inlinesign}[1]{% \setlength{\normaldepth}{\depthof{p}}% \raisebox{-\normaldepth}{% \includegraphics[height={\f@size pt}]{#1}% }% } \makeatother This makes them extend downward as far as a p and upward as far as a b, which is generally a good size for inline characters. However, some of these glyphs are much more elaborate than English letters, so this is sometimes difficult to see: I would like to make them extend into the inter-line spacing both above and below, to give them just a little bit more space to breathe. Since I seldom have more than three inline signs per paragraph, the odds of one being directly above another are small; I'm willing to live with the risk of that happening. How can I adjust my code to extend into the line spacing: adding twice the line spacing to the \includegraphics height, and subtracting it from the \raisebox depth? MWE: \documentclass[12pt]{article} \usepackage{calc} % Calculate the proper height for inline signs \usepackage{graphicx} \graphicspath{{./images/}} \newlength{\normaldepth} \makeatletter \DeclareRobustCommand{\inlinesign}[1]{% \setlength{\normaldepth}{\depthof{p}}% \raisebox{-\normaldepth}{% \includegraphics[height={\f@size pt}]{#1}% }% } \makeatother \begin{document} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus nec tortor aliquam, scelerisque diam ac, pharetra risus. Etiam est lacus, maximus ut ipsum pulvinar, consectetur tincidunt velit. Proin enim mauris, ullamcorper eu dolor sit amet, rutrum convallis mauris. Vestibulum quis ante nec ex venenatis imperdiet nec vitae erat. Nulla tempus mattis arcu, sit amet euismod metus commodo eu. Morbi blandit odio felis, vitae sodales urna elementum non. Phasellus dolor nibh, volutpat vel justo eu, commodo posuere orci. \inlinesign{umbin_new} Cras sit amet molestie tortor, eget imperdiet dolor. Proin ac ex non justo congue iaculis eget non urna. Integer pretium placerat consectetur. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. In eu libero elit. Fusce eget lacus eu leo pulvinar imperdiet. Praesent dui neque, efficitur sit amet scelerisque vitae, blandit sit amet eros. Donec elit lorem, porta vitae ipsum quis, scelerisque elementum quam. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi vitae urna a lacus sollicitudin vulputate. Nulla at ipsum sed turpis sollicitudin ultrices. \end{document}

  • Unexpected (to me!) behaviour when trying to resume enum item numbers in subsequent enumerate environments
    by dmorg on December 24, 2025 at 8:09 pm

    I have defined a counter (firstcounter) and, in the first column, item numbers display as I'd expect. However, in the middle column with the same code (but a secondcounter to avoid interaction with the first list), I have changed \only<1-> to \only<1-4> and it breaks the numbering. The right hand column (with two separate counters, thirdcounter and fourthcounter), 'works' but unsatisfactorily; I feel I should not need an extra counter for each resumption of enumeration. Can someone explain to me what I'm doing wrong? \documentclass{beamer} \newcounter{firstcounter} \newcommand{\setfirst}{\setcounter{firstcounter}{\value{enumi}}} \newcommand{\contfirst}{\setcounter{enumi}{\value{firstcounter}}} \newcounter{secondcounter} \newcommand{\setsecond}{\setcounter{secondcounter}{\value{enumi}}} \newcommand{\contsecond}{\setcounter{enumi}{\value{secondcounter}}} \newcounter{thirdcounter} \newcommand{\setthird}{\setcounter{thirdcounter}{\value{enumi}}} \newcommand{\contthird}{\setcounter{enumi}{\value{thirdcounter}}} \newcounter{fourthcounter} \newcommand{\setfourth}{\setcounter{fourthcounter}{\value{enumi}}} \newcommand{\contfourth}{\setcounter{enumi}{\value{fourthcounter}}} \begin{document} \begin{frame} %left column \begin{minipage}{0.3\textwidth} \only<1->{ \begin{enumerate} \item 1st \item <2-> 2nd \item <3-> 3rd. \item <4-> 4th \setfirst \end{enumerate} } \only<5->{ \begin{enumerate} \contfirst \item 5th. \item <6-> 6th. \item <7-> 7th. \setfirst \end{enumerate} } \only<8->{ \begin{enumerate} \contfirst \item 8th. \item <9-> 9th. \item <10-> 10th. \end{enumerate} } \end{minipage} % middle column \begin{minipage}{0.3\textwidth} \only<1-4>{ \begin{enumerate} \item 1st \item <2-> 2nd \item <3-> 3rd. \item <4-> 4th \setsecond \end{enumerate} } \only<5->{ \begin{enumerate} \contsecond \item 5th. \item <6-> 6th. \item <7-> 7th. \setsecond \end{enumerate} } \only<8->{ \begin{enumerate} \contsecond \item 8th. \item <9-> 9th. \item <10-> 10th. \end{enumerate} } \end{minipage} % right column \begin{minipage}{0.3\textwidth} \only<1-4>{ \begin{enumerate} \item 1st \item <2-> 2nd \item <3-> 3rd. \item <4-> 4th \setthird \end{enumerate} } \only<5->{ \begin{enumerate} \contthird \item 5th. \item <6-> 6th. \item <7-> 7th. \setfourth \end{enumerate} } \only<8->{ \begin{enumerate} \contfourth \item 8th. \item <9-> 9th. \item <10-> 10th. \end{enumerate} } \end{minipage} \end{frame} \end{document} These are all the same lists and should have the same numbering.

  • Large file size with DocumentMetadata
    by dedded on December 24, 2025 at 8:09 pm

    The pdf produced by the first example below is much larger (3x) than that of the second. Both are PDF version 1.7, and neither are tagged (according to pdfinfo). What accounts for the difference in size, and can the pdf of the the first example be made smaller with another argument to DocumentMetadata? \DocumentMetadata{pdfversion=1.7} \documentclass{article} \begin{document} \section{One} This is section one. \section{Two} This is section two. \end{document} \documentclass{article} \begin{document} \section{One} This is section one. \section{Two} This is section two. \end{document}

  • Clash between cleveref and empheq when labels defined for cleveref?
    by user1362373 on December 24, 2025 at 7:21 pm

    I noticed what appears to be a clash between cleveref and empheq packages when I define labels for cleveref so that references to inequalities are labelled as such and not as equations. Consider the following MWE: \documentclass{article} \usepackage{empheq} \usepackage{cleveref} \crefname{ineq}{ineq}{ineqs} \begin{document} \begin{equation} \label[ineq]{label1} % \label{label1} a < b \end{equation} \cref{label1} \end{document} It produces LaTeX Warning: Reference `label1' on page 1 undefined on input line 15. and Now if I comment \usepackage{empheq}, the warning disappears and the correct output is generated: Alternatively, if I comment \label[ineq]{label1} and uncomment \label{label1}, the warning also disappears, but then the inequality is incorrectly labelled as an equation: The conclusion is that there is a clash between cleveref when labels are defined and empheq. (In my document, I need empheq to label individual equations in the cases environment.) How can I resolve or work around this problem? (I'm running pdfTeX, Version 3.141592653-2.6-1.40.28 (TeX Live 2025) on macOS Sequoia 15.7.1.)

  • How to open multiple TeXstudio windows or instances on macOS?
    by tvk on December 24, 2025 at 5:01 pm

    I often work on two closely related TeX documents at the same time and would like to place one TeXstudio editor window on each of my two displays. However, on macOS, TeXstudio opens multiple .tex files as tabs within a single window rather than in separate windows. Is there a way to open multiple TeXstudio editor windows or run multiple TeXstudio instances on macOS? I am using TeXstudio 4.9.1 on macOS Tahoe 26.2.

  • nicematrix submatrix fails when \Cdots is used
    by projetmbc on December 24, 2025 at 2:52 pm

    The following M(not)WE fails because of the \Cdots used. Is there a quick fix of this bug? The log file indicates the error below if I uncomment the failing sub matrix command. Package nicematrix Error: Impossible delimiter. (nicematrix) It's impossible to draw the right delimiter of (nicematrix) your \SubMatrix because all the cells are empty (nicematrix) in that column. (nicematrix) This \SubMatrix will be ignored. Here is the LaTeX code. \documentclass[border=5pt, varwidth]{standalone} \usepackage{nicematrix} \begin{document} $\begin{NiceArray}{*{7}{c}}[cell-space-limits=3pt] & & & & & & \Vdots \\ & & & & & & a[k]_{mj} \\ & & & & & & \Vdots \\ & & & & & & a[k]_{m'j} \\ & & & & & & \Vdots \\ & & & & & & \phantom{X} \\ \Cdots & 1 & \Cdots & 0 & \Cdots & \hspace{12.5pt} & a[k+1]_{ij} % \CodeAfter \SubMatrix({1-7}{5-7})[slim] % \SubMatrix({7-1}{7-5}) % <-- This fails! \SubMatrix({7-7}{7-7})%[slim] \end{NiceArray}$ $\begin{NiceArray}{*{7}{c}}[cell-space-limits=3pt] & & & & & & \Vdots \\ & & & & & & a[k]_{mj} \\ & & & & & & \Vdots \\ & & & & & & a[k]_{m'j} \\ & & & & & & \Vdots \\ & & & & & & \phantom{X} \\ Cdots & 1 & Cdots & 0 & Cdots & \hspace{12.5pt} & a[k+1]_{ij} % \CodeAfter \SubMatrix({1-7}{5-7})[slim] \SubMatrix({7-1}{7-5}) \SubMatrix({7-7}{7-7})%[slim] \end{NiceArray}$ \end{document} PS: for those who are curious, this is just to demonstrate how to calculate the number of paths of known length using an adjacency matrix.

  • Incompatibility between KOMA-script classes and babel Spanish
    by mlg on December 24, 2025 at 10:57 am

    While using [spanish]babel with a KOMA-script class (I've tried with scrartcl and scrbook) I get the following error: LaTeX hooks: Generic hooks cannot be added to '\@startsection'. How can I fix this? Here is my MWE. \documentclass{scrartcl} \usepackage[spanish]{babel} \begin{document} Buenos días. \end{document}

  • How to get reproducible PDF
    by user2609605 on December 23, 2025 at 9:43 pm

    For quite some span of time, I was sure to have solved that problem. I got the build time from the original PDF file, e.g. via pdfinfo. Then i made the next build with SOURCE_DATE_EPOCH using exactly that time. Also FORCE_SOURCE_DATE must be set. This worked with lualatex and PDF 1.7. Now, adding pdfa/A, tagging, PDF/UA and moving on to PDF2.0, it does not work any more. Some experiments show, the critical feature is tagging. It is a great feature and i dont want to do without it. I search for a way to keep reproducibility even if tagging is present. Well, in fact, reproducibility is no longer trustable, sometimes it works. I observe that sometimes the lengths of the files differ minimally. Visually, they are the same, also XMP data seems the same. But my old simple concept of bytewise equivalence is gone. I tried with uncompress as suggested by DavidCarlisle, << /Type /Namespace /NS (data:,AC8956-1B7-A6A9-1928-C381ECC1E1C) >> << /Type /Namespace /NS (data:,5F48FB81-AC9C-B85B-A0B9-890FA89F45CC) >> is the first difference. The next is in a sequence of xref 0 17537 0000000002 65535 f 0007003671 00000 n 0000000003 00000 f But i cannot interprete these... and remarkable that even the trailer IDs coincide. In my dark thougths I even read the PDF spec and found that the trailer ID may depend on the location of the PDF also... So maybe there is another problem I do face only if there are more developers compiling in different environments. Maybe latex compilers dont use location to create the trailer ID, do they? Any advice on a sound foundation for reproducibiliby also in the future? Future is >PDF1.7, and PDF/A, PDF/UA, including tagging.

  • Is there a reference on how to make tables better, or a more standard way of pre-contemplating them?
    by Jasper on December 23, 2025 at 6:39 pm

    Is there a reference on how to make tables better, or a more standard way of pre-contemplating them? I was trying to tabulate the elementary linear transformations, and noticed that my table was rather unaesthetic. My hope is that someone could guide me on how I could better pre-contemplate these tables, so that they don't come out looking like this: \documentclass[letterpaper]{book} \usepackage{nicematrix} \usepackage{booktabs} \usepackage{tikz} \usepackage{microtype} \usepackage{mathtools} \usepackage{unicode-math} \newcommand{\temp}{% \begin{tikzpicture} \draw (-1,-1) rectangle (1,1); \node at (0,0) {Blah.}; \end{tikzpicture}% } \begin{document} \begin{table} \centering \begin{tabular}{lll} \toprule Linear transformation & Example Matrix & Geometric effect \\ \midrule Scale & \({\begin{bNiceArray}{cc} t & 0 \\ 0 & 1 \end{bNiceArray}}\) & \temp \\ \midrule Shear & \({\begin{bNiceArray}{cc} 1 & t \\ 0 & 1 \end{bNiceArray}}\) & \temp \\ \midrule Swap & \({\begin{bNiceArray}{cc} 0 & 1 \\ 1 & 0 \end{bNiceArray}}\) & \temp \\ \bottomrule \end{tabular} \caption{The elementary matrices are blah blah blah.} \label{table:chap-elem-mat} \end{table} \end{document}

  • Conflict between \hl command from soul package and \linenumbers command from lineno package
    by Orcs River on December 23, 2025 at 5:54 pm

    Activating line numbers on a latex document, causes text highlighted using the \hl command to disappear. Here is a minimal example: \documentclass{article} \usepackage{lipsum} \usepackage{soul} \usepackage{xcolor} \usepackage[left]{lineno} \linenumbers \begin{document} Conflict between \verb|\hl| and \verb|\linenumbers| commands \section{First section} \hl{This text will be hidden when line numbers are activated}. \lipsum[1] \end{document} Here are screenshots before and after activating line numbers. Thanks

  • Commutative diagrams using square boxes
    by ncant on December 23, 2025 at 3:38 pm

    I would like to reproduce the following commutative diagram, consisting of square boxes with mathematical expressions located near the corners, rather than mathematical expressions connected by an arrow. Since this type of diagram only develops vertically, as if it's a single column, I think it is possible to create a command that uses TikZ to draw a square and accepts four arguments, one for each edge of the square. However, I am having difficulty stacking these squares. Can you help me? Thank you EDIT: These are the instructions I'm using for making the square box. These are normally located inside a command that takes four argument, one for each corner. \begin{tikzpicture} \draw[thick] (0,0) rectangle (2,2); \node[left] at (0,2) {$f(t)$}; \node[left] at (0,0) {$e^{at}f(t)$}; \node[right] at (2,2) {$F(s)$}; \node[right] at (2,0) {$F(s-a)$}; \end{tikzpicture} These result in the following figure:

  • angle condition judge error in tikz?
    by Explorer on December 23, 2025 at 2:01 pm

    I have the following code to plot the "outer" semicircle: \documentclass[tikz,border=5pt]{standalone} \usetikzlibrary{calc} % https://tex.stackexchange.com/a/666441/322482 \newcommand*\drawSemicircle[3][]{% \coordinate (mid) at ($(#2)!0.5!(#3)$); \draw[#1] (#2) let \p{A} = ($(#2)-(mid)$), \p{B} = ($(#3)-(mid)$), \n{cross} = {\x{A}*\y{B} - \y{A}*\x{B}}, \n{angA} = {atan2(\y{A},\x{A})}, \n{angB} = {atan2(\y{B},\x{B})}, \n{R} = {veclen(\x{A},\y{A})}, \n{start} = {(\n{cross}>0 ? \n{angA} : \n{angB})}, \n{endraw} = {(\n{cross}>0 ? \n{angB} : \n{angA})}, \n{end} = {(\n{endraw} < \n{start} ? \n{endraw} + 360 : \n{endraw})} in arc[start angle=\n{start},end angle=\n{end},radius=\n{R}]; } \begin{document} \begin{tikzpicture} \foreach \x in {1,...,60}{ \node[circle,draw=magenta,thick] (in-\x) at ({\x*6}:5cm) {}; \node[circle,draw=teal,thick] (out-\x) at ({\x*6}:5.5cm) {}; } \foreach \pstart[evaluate=\pstart as \pend using {int(mod(\pstart+9,60)+1)}] in {1,...,60}{ \drawSemicircle[semithick]{in-\pstart}{out-\pend} % \node[fill=white,circle,label={[label distance=-2em,text=magenta]\pstart*6:\pstart}] at (in-\pstart) {};%<-not elegant here % \node[fill=white,circle,label={[label distance=+1em,text=teal]\pstart*6:\pstart}] at (out-\pend) {}; } \end{tikzpicture} \end{document} Which gives: However, when I substitute: \node[circle,draw=teal,thick] (out-\x) at ({\x*6}:5.5cm) {}; with \node[circle,draw=teal,thick] (out-\x) at ({\x*6}:6cm) {}; Things broken, I guess that it's something like angle float error.... But I don't know how to fix this:

  • How to write a cube root correctly inside a theorem environment
    by keith77777 on December 23, 2025 at 12:15 pm

    \documentclass[% openright, % doublepage cleaning ends up right side 11pt, % font size ]{book}% \usepackage[fleqn]{amsmath}% \usepackage{amssymb}% \usepackage{amsthm}% \usepackage{mwe} \usepackage[paperheight=240mm,paperwidth=175mm,bindingoffset=12.5mm,showcrop]{geometry} \usepackage[a4,cam,center]{crop} % \newtheoremstyle{equationtype} % 1 name {5pt plus 0pt minus 0pt} % 2 {5pt plus 0pt minus 0pt} % 3 {\normalfont} % 4 main body text (lots of it) and is {-4.8pt} % 5 indent amount of header text {\bfseries} % 6 theorem head font {\\[4pt]} % punctuation after theorem head { } % 8 space after theorem head { \fontsize{11.25}{12}\selectfont{ \thmname{#1}} \thmnumber{#2} {\normalfont\fontsize{11.35}{12}\selectfont{\thmnote{#3}}} } % 9 \theoremstyle{equationtype} \newtheorem*{example}{Theorem\hspace{3pt}\ldots} \begin{document} \section*{Square and cube roots inside theorem} Would like the one-line presentation not to be altered. \vspace{6pt} express in index form\hspace{1pt}: \hspace{1pt}$4\hspace{1.0pt}\big\{\sqrt{\hspace{1.6pt}x^{\hspace{1.6pt}4\hspace{1.0pt}}}\big\}$ \vspace{6pt} \begin{example} [in index form\hspace{1pt}: \hspace{1pt}$4\hspace{1.0pt}\big\{\sqrt{\hspace{1.6pt}x^{\hspace{1.6pt}4\hspace{1.0pt}}}\big\}$] \hspace{4pt}correct, presumably because no square brackets are involved \end{example} \vspace{12pt} express in index form\hspace{1pt}: \hspace{1pt}$4\hspace{1.0pt}\big\{\sqrt[\leftroot{0}\uproot{3}\scriptstyle 3]{\hspace{1.6pt}x^{\hspace{1.6pt}4\hspace{1.0pt}}}\big\}$ \hspace{4pt}(as hoped for) \vspace{6pt} \begin{example} [in index form\hspace{1pt}: \hspace{1pt}$4\hspace{1.0pt}\big\{\sqrt[\leftroot{0}\uproot{3}\scriptstyle 3]{\hspace{1.6pt}x^{\hspace{1.6pt}4\hspace{1.0pt}}}\big\}$] \end{example} \end{document}

  • Tikz to plot a part of a cone
    by Latexfan on December 23, 2025 at 10:30 am

    I try to use tikz to plot the following image ... \documentclass[border=0.2cm]{standalone} \usepackage{pgfplots} \usepgfplotslibrary{colormaps} \pgfplotsset{compat = newest} \begin{document} \begin{tikzpicture} \begin{axis}[ axis equal image, grid = both, minor tick num = 2, xlabel = {$x$}, ylabel = {$y$}, zlabel = {$z$}, major grid style = {draw = lightgray}, minor grid style = {draw = lightgray!25}, xmin = 0, xmax = 1, ymin = 0, ymax = 1, zmin = 0, zmax = 2, scale = 3, view = {60}{30}, samples = 30, samples y = 30, z buffer = sort, ] % Kjeglesektor \addplot3[ surf, shader = interp, opacity = 0.75, colormap/viridis, ] ({x},{y},{sqrt(3)*sqrt(x^2+y^2)}); \end{axis} \end{tikzpicture} \end{document} But I do not get similar image ... can you please help me?

  • Nested revealing of (correctly sized) blanks
    by scottkosty on December 23, 2025 at 1:53 am

    I am using an implementation to first show an underline with a questionmark in the middle that takes up the same space as the revealed text, from this answer: An alt fill-in-the-blank with question in the middle However, it does not work as expected when I nest them. It almost works, but it has an extra overlay. Here's an example: \documentclass{beamer} % needed to reproduce \beamerdefaultoverlayspecification{<alert@+|+->} \begin{document} % This implementation is thanks to Sam: % https://tex.stackexchange.com/questions/682149/an-alt-fill-in-the-blank-with-question-in-the-middle \newlength{\gapwidth} \newcommand{\blankQ}[1]{% \ifmmode \if@display \settowidth{\gapwidth}{$\displaystyle #1$}% \else \settowidth{\gapwidth}{$#1$}% \fi \else \settowidth{\gapwidth}{#1}% \fi \alert<.(1)|handout:0>{% \alt<+->{% #1% }{% \vphantom{#1}\smash{\underline{\makebox[\gapwidth]{?}}}% }% }% } \begin{frame} \begin{itemize} \item hello \item $P(X + 1 < 4) = \blankQ{P(X < 3) = \blankQ{0.3.}}$ \end{itemize} \end{frame} \end{document} It almost works except that there's an extra overlay. I use this type of setup a lot, so I would need any fix to be a drop-in for the macro definition. i.e., I don't want to change the \beamerdefaultoverlayspecification command or specify overlays in the itemize environment, etc. Here is a sequence of the desired result. This was made by removing the 3rd pdf page from the pdf created from the .tex file above:

  • Graph of a projection function
    by Octavius on December 22, 2025 at 9:49 pm

    I have the following code, but I can’t manage to replicate the figure shown in the attached image. Could you help me with the code and provide the figure? Thank you very much. \documentclass[12pt]{article} % --- Márgenes (opcional) --- \usepackage[margin=2.2cm]{geometry} % --- Idioma y acentos --- \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage[spanish]{babel} % --- Matemática y TikZ --- \usepackage{amsmath,amssymb} \usepackage{xcolor} \usepackage{tikz} \usetikzlibrary{arrows.meta,calc,3d} \pagestyle{empty} \begin{document} \begin{center} % --- TU FIGURA --- \begin{tikzpicture}[ scale=1.15, line cap=round, line join=round, x={(-0.95cm,-0.55cm)}, % Eje X: oblicuo hacia abajo-izquierda y={(1.15cm,0cm)}, % Eje Y: horizontal z={(0cm,1.15cm)} % Eje Z: vertical ] % Colores/estilos \definecolor{axisblue}{RGB}{20,90,130} \tikzset{ axis/.style={very thick, draw=axisblue, -Latex}, proj/.style={dashed, black, line width=0.8pt}, edge/.style={black, line width=0.9pt}, face/.style={draw=black, fill=gray!35, opacity=0.55}, topface/.style={draw=black, fill=gray!25, opacity=0.55}, frontface/.style={draw=black, fill=gray!45, opacity=0.55} } % Ejes \draw[axis] (0,0,0) -- (4.8,0,0) node[below left] {Eje X}; \draw[axis] (0,0,0) -- (0,5.4,0) node[right] {Eje Y}; \draw[axis] (0,0,0) -- (0,0,4.8) node[above] {Eje Z}; % Título \node[anchor=west] at (0.9,2.4,4.0) {\Large Gráfico de $g(x,y)=x$}; % -------- PRISMA 1: x in [0,1], y in [-1,1], altura 1 -------- \def\xa{0}\def\xb{1} \def\ya{-1}\def\yb{1} \def\hA{1} % Vértices base \coordinate (A1) at (\xa,\ya,0); \coordinate (B1) at (\xb,\ya,0); \coordinate (C1) at (\xb,\yb,0); \coordinate (D1) at (\xa,\yb,0); % Vértices top \coordinate (A1t) at (\xa,\ya,\hA); \coordinate (B1t) at (\xb,\ya,\hA); \coordinate (C1t) at (\xb,\yb,\hA); \coordinate (D1t) at (\xa,\yb,\hA); % Proyecciones (sombras) al plano z=0 \draw[proj] (A1) -- (A1t); \draw[proj] (B1) -- (B1t); \draw[proj] (C1) -- (C1t); \draw[proj] (D1) -- (D1t); % Caras visibles \filldraw[frontface] (A1) -- (B1) -- (B1t) -- (A1t) -- cycle; % cara "frontal" \filldraw[face] (B1) -- (C1) -- (C1t) -- (B1t) -- cycle; % cara derecha \filldraw[topface] (A1t) -- (B1t) -- (C1t) -- (D1t) -- cycle; % tapa % Aristas principales \draw[edge] (A1) -- (B1) -- (C1) -- (D1) -- cycle; \draw[edge] (A1t) -- (B1t) -- (C1t) -- (D1t) -- cycle; \draw[edge] (A1) -- (A1t); \draw[edge] (B1) -- (B1t); \draw[edge] (C1) -- (C1t); \draw[edge] (D1) -- (D1t); % Etiquetas \node at (\xa,\ya,\hA) [above left] {$1$}; \node at (0.55,0, -0.02) [below, yshift=-2pt] {$[0,1]\times(-1,1)$}; % -------- PRISMA 2: x in [2,3], y in [-1,1], altura 2 -------- \def\xc{2}\def\xd{3} \def\hB{2} \coordinate (A2) at (\xc,\ya,0); \coordinate (B2) at (\xd,\ya,0); \coordinate (C2) at (\xd,\yb,0); \coordinate (D2) at (\xc,\yb,0); \coordinate (A2t) at (\xc,\ya,\hB); \coordinate (B2t) at (\xd,\ya,\hB); \coordinate (C2t) at (\xd,\yb,\hB); \coordinate (D2t) at (\xc,\yb,\hB); % Proyecciones \draw[proj] (A2) -- (A2t); \draw[proj] (B2) -- (B2t); \draw[proj] (C2) -- (C2t); \draw[proj] (D2) -- (D2t); % Caras \filldraw[frontface] (A2) -- (B2) -- (B2t) -- (A2t) -- cycle; \filldraw[face] (B2) -- (C2) -- (C2t) -- (B2t) -- cycle; \filldraw[topface] (A2t) -- (B2t) -- (C2t) -- (D2t) -- cycle; % Aristas \draw[edge] (A2) -- (B2) -- (C2) -- (D2) -- cycle; \draw[edge] (A2t) -- (B2t) -- (C2t) -- (D2t) -- cycle; \draw[edge] (A2) -- (A2t); \draw[edge] (B2) -- (B2t); \draw[edge] (C2) -- (C2t); \draw[edge] (D2) -- (D2t); % Etiquetas \node at (\xc,\ya,\hB) [above left] {$2$}; \node at (2.55,0,-0.02) [below, yshift=-2pt] {$[2,3]\times(-1,1)$}; % Marcas -1 y 1 sobre eje Y (opcional) \node at (0,-1,0) [below] {$-1$}; \node at (0, 1,0) [below] {$1$}; \end{tikzpicture} \end{center} \end{document}

  • Booktabs cmidrule creates unwanted vertical space
    by profj on December 22, 2025 at 7:30 pm

    I am making the following table using LaTeX. One way to do it is to make a separate row for the "Top Header" header. However, this results in space below that header and the "sub headers": \documentclass{article} \usepackage{booktabs} \begin{document} \begin{table} \centering \begin{tabular}{ll rr} \toprule (1) & (2) & (3) & (4) \\ \midrule & & \multicolumn{2}{c}{Top Header} \\ \cmidrule(lr){3-4} Main & Main & \\ Header 1 & Header 2 & Sub 1 & Sub 2 \\ \midrule 0.01 & 0.25 & 0.05 & 0.00 \\ 0.02 & 0.25 & 0.11 & 0.03 \\ 0.05 & 0.25 & 0.16 & 0.09 \\ \bottomrule \end{tabular} \end{table} \end{document} An alternative way is to include "Top Header" on the same line as the top line of the "Main Headers", but the use of \cmidrule creates awkward space for the two "Main Headers": \documentclass{article} \usepackage{booktabs} \begin{document} \begin{table} \centering \begin{tabular}{ll rr} \toprule (1) & (2) & (3) & (4) \\ \midrule Main & Main & \multicolumn{2}{c}{Top Header} \\ \cmidrule(lr){3-4} Header 1 & Header 2 & Sub 1 & Sub 2 \\ \midrule 0.01 & 0.25 & 0.05 & 0.00 \\ 0.02 & 0.25 & 0.11 & 0.03 \\ 0.05 & 0.25 & 0.16 & 0.09 \\ \bottomrule \end{tabular} \end{table} \end{document} A third way, with no \cmidrule gets the vertical spacing right, but I do want a to use \cmidrule to get a line under "Top Header": \documentclass{article} \usepackage{booktabs} \begin{document} \begin{table} \centering \begin{tabular}{ll rr} \toprule (1) & (2) & (3) & (4) \\ \midrule Main & Main & \multicolumn{2}{c}{Top Header} \\ Header 1 & Header 2 & Sub 1 & Sub 2 \\ \midrule 0.01 & 0.25 & 0.05 & 0.00 \\ 0.02 & 0.25 & 0.11 & 0.03 \\ 0.05 & 0.25 & 0.16 & 0.09 \\ \bottomrule \end{tabular} \end{table} \end{document} How can I get columns 1 and 2 to behave as in the first table, but columns 3 and 4 to behave as in the second table? In other words, I'd like the headers to take up two lines, as in the second table, and I'd like to use the \cmidrule command for columns 3 and 4, but I don't want the the extra space in between "Main" and "Header 1" and "Main" and "Header 2" that we see in the second table.

  • circuitikz: anchoring a circular path symbol
    by cis on December 21, 2025 at 1:02 pm

    How do I choose the anchor so that the line starts exactly at the edge at a path-source to[american current source]? \documentclass[margin=5pt, multi=circuitikz]{standalone} \usepackage{circuitikz} \begin{document} \begin{circuitikz}[] %\ctikzset{bipoles/border margin=0.0}% no effect \draw[] (0,0) to[american current source, o-o, name=GS] (2,0); \draw[->] (GS.north east) -- +(45:1); \end{circuitikz} \end{document}

  • \prime \dprime \tprime (not so much) \qprime (looks good) STIX TWO
    by Steven Thomas Hatton on December 21, 2025 at 6:20 am

    The motivation Pfaff, Johann Friedrich: Methodus generalis, aequationes differentiarum partialium, nec non aequationes differentiales vulgares, utrasque primi ordinis inter quotcunque variabiles, complete integrandi The Problem \documentclass[a4paper,10pt]{article} \usepackage{amsmath} \usepackage{mathtools} \usepackage{unicode-math} \setmainfont{STIX Two Text} \setmathfont{STIX Two Math} \newcommand{\tprime}{\char"2034} % ‴ \newcommand{\qprime}{\char"2057} % ⁗ \begin{document} Prime notation: $x^{\prime},x^{\dprime},x^{\tprime},x^{\qprime}$ \end{document} Obviously, the desired result would be for the triple prime to look like the double prime with one more prime, and to look like the quadruple prime with one less prime. This appears to be a feature of unicode since it appears in browsers, in Kate, in Emacs, (differently un-uniform) in xterm. Is there a way to produce a uniform set of prime, double prime, triple prime, quadruple prime using LuaLaTeX? Preferably with STIX Two. Post Script. I was unaware that $x'''$ would work. I learned to author LaTeX using LyX which is WYSIWYM not WYSIWYG. I rarely compiled what I was writing. My reality was what I saw in LyX.

  • Striking out an entire exercise using amsart environments
    by Sebastiano on December 20, 2025 at 1:57 pm

    Suppose I am writing an exercise with a amsart enviroment like the one shown in the MWE below, \documentclass[12pt,a4paper]{article} \usepackage{geometry} \usepackage{amsmath} \usepackage{amssymb} \begin{document} Studiare in $(0, 0)$ la continuità, l'esistenza delle derivate parziali e la differenziabilità della funzione \[ f(x, y) = \begin{cases} \dfrac{x^3 + 3x^2y + y^4}{x^2 + y^2} & \text{se } (x, y) \neq (0, 0) \\ 0 & \text{se } (x, y) = (0, 0). \end{cases} \] Studiamo la continuità in $(0,0)$. Si ha \[ |f(x,y)| = \left| \frac{x^3 + 3x^2y + y^4}{x^2+y^2} \right| \leq |x|+3|y|+|y|^2 \] e quando $(x,y)\to(0,0)$ l'ultima diseguaglianza tende a $0$ e anche la funzione di partenza lo sarà. Quindi \[ \lim_{(x,y)\to(0,0)} f(x,y) = 0 = f(0,0), \] cioè $f$ è continua in $(0,0)$. \end{document} and I want to strike out the entire exercise, while preserving any environments created with amsart, as in the image below. I'm searching something without use tcolorbox (mdframed or similar) using simple commands (without package) to create an "oblique rule" .

  • Custom 3D line plot in plain tikz and/or luadraw
    by Dr. Manuel Kuehner on December 19, 2025 at 12:30 pm

    Disclaimer This question is a bit of "do it for me" but there is a histrory behind it, see this question. User Jasper offered me a solution without using pgfplots. I plan to add a bounty as soon as it is possible. Question I want to create diagram with a 3D line plots. The main feature is to have several x axes that share the same y axis. Each x axis has its own F (or z) axis. There are only data points on specific y values (in the example below at +30, +15, 0, -15). In addition, the y axis is reversed (+ and - direction reversed). I need a grid in each F-x plane. Important ist also, that all F axes share the same min and max. Each axis should have a label and the diagram should have a title. The data is given in separate csv files, see example below. The MWE contains the data and plots the data (for testing) using pgfplots. Goal: The goal is to have a plain tikz solution and maybe in addition, a solution based on luadraw or lua-tikz3dtools respectively. I am looking for a easy-to-use custom interface for my plot task. If the result looks as it is created with pgfplots, then I am happy. S!#i, I forgot a key feature (not shown in the hand drawing) In addition to the x-F plots described above, there is ONE plot in the y-F plane (= from left to right). This works, because all F axes share the same min and max. \begin{filecontents*}{y_F_data.csv} y,F -15,20 -14,8 30,-4 \end{filecontents*} \documentclass{article} \usepackage{pgfplots} % ------------------------------- \begin{filecontents*}{x_zero.csv} x,F -30,12 -29,8 30,-4 \end{filecontents*} \begin{filecontents*}{x_neg_one.csv} x,F -30,12 -29,8 30,-4 \end{filecontents*} \begin{filecontents*}{x_pos_one.csv} x,F -30,12 -29,8 30,-4 \end{filecontents*} \begin{filecontents*}{x_pos_two.csv} x,F -30,12 -29,8 30,-4 \end{filecontents*} % ------------------------------- \begin{document} \begin{tikzpicture} \begin{axis}[ axis lines = center, title = {$x_0$}, xlabel = {$x_0$}, ylabel = {$F_0$}, xmin = -30, xmax = 30, ymin = -100, ymax = 100, ] \addplot table [x=x, y=F, col sep = comma] {x_zero.csv}; \end{axis} \end{tikzpicture} \begin{tikzpicture} \begin{axis}[ axis lines = center, title = {$x_{-1}$}, xlabel = {$x_{-1}$}, ylabel = {$F_{-1}$}, xmin = -30, xmax = 30, ymin = -100, ymax = 100, ] \addplot table [x=x, y=F, col sep = comma] {x_neg_one.csv}; \end{axis} \end{tikzpicture} \begin{tikzpicture} \begin{axis}[ axis lines = center, title = {$x_{1}$}, xlabel = {$x_{1}$}, ylabel = {$F_{1}$}, xmin = -30, xmax = 30, ymin = -100, ymax = 100, ] \addplot table [x=x, y=F, col sep = comma] {x_pos_one.csv}; \end{axis} \end{tikzpicture} \begin{tikzpicture} \begin{axis}[ axis lines = center, title = {$x_{2}$}, xlabel = {$x_{2}$}, ylabel = {$F_{2}$}, xmin = -30, xmax = 30, ymin = -100, ymax = 100, ] \addplot table [x=x, y=F, col sep = comma] {x_pos_two.csv}; \end{axis} \end{tikzpicture} \end{document}