Week
- Multiple independent compound numbering series in `chemnum` (generalizing two-series solution)by monty01 on February 13, 2026 at 9:48 pm
I am using the chemnum package together with chemstyle to label compounds in reaction schemes. By default, chemnum only provides a single global counter (cmpdmain), so compounds are numbered like: 1, 2, 3a, 3b, 4 … However, I need multiple independent numbering series, for example: literature compounds -> 1, 2, 3… target compounds -> T1, T2… intermediates -> INT1, INT2… supplementary information -> S1, S2… So effectively I want arbitrary named numbering series: \seriesBegin{EG} \replacecmpd{a} \seriesEnd \seriesBegin{INT} \replacecmpd{b} \seriesEnd and each series should continue later in the document without resetting. What I already found This answer provides a clever workaround for two parallel numbering series by saving and restoring cmpdmain: https://tex.stackexchange.com/a/759086/433835 code \documentclass{article} \usepackage{graphicx} \usepackage{chemstyle} % Provides the 'scheme' float environment (and general chem document styling) \usepackage{chemnum} % Provides compound numbering + psfrag-like replacement via \replacecmpd / \cmpd % --- Two "parallel" compound series trick ------------------------------------ % chemnum internally uses ONE main counter: cmpdmain. % To emulate two independent series (literature vs EG), we: % 1) save the current main counter value % 2) swap in the saved EG counter state % 3) turn on the "EG" prefix % 4) after the EG block, save the updated EG state and restore the main counter \newcounter{cmpdMainSaved} % temp storage: saves the current literature/main cmpd counter \newcounter{cmpdEGstate} % persistent storage: remembers where the EG series left off \newcommand{\EGseriesBegin}{% % Save the current "main" (literature) compound counter: \setcounter{cmpdMainSaved}{\value{cmpdmain}}% % Switch cmpdmain to the last saved EG state (so EG numbering continues): \setcounter{cmpdmain}{\value{cmpdEGstate}}% % Turn on a bold "EG" prefix for printing compound labels (EG1, EG2, ...): \setchemnum{pre-label-code=\textbf{EG}}% } \newcommand{\EGseriesEnd}{% % Save the updated EG state (so the next EG block continues where we stopped): \setcounter{cmpdEGstate}{\value{cmpdmain}}% % Turn off the EG prefix (back to plain numbers): \setchemnum{pre-label-code=}% % Restore the literature/main counter exactly where it was before EG mode: \setcounter{cmpdmain}{\value{cmpdMainSaved}}% } \begin{document} % --- Literature compounds: should print as 1,2 -------------------------------- \begin{scheme}[H] \replacecmpd{lit:a.1} % Register/replace the placeholder in the graphic with compound "1a" \replacecmpd{lit:b} % Register/replace the placeholder in the graphic with compound "2" \includegraphics[width=.5\linewidth]{PhH-and-PhMe} \caption{Normal numbering} \end{scheme} % --- Your target compounds: should print as EG1, EG2 --------------------------- \EGseriesBegin % Switch into EG-series mode (prefix + separate counter state) \begin{scheme}[H] \replacecmpd{eg:a.1} % Register/replace placeholder with "EG1a" \replacecmpd{eg:b} % Register/replace placeholder with "EG2" \includegraphics[width=.5\linewidth]{PhH-and-PhMe} \caption{EG numbering} \end{scheme} \EGseriesEnd % Leave EG mode and restore literature numbering \cmpd{eg:a.1}, \cmpd{eg:b} \cmpd{lit:a.1}, \cmpd{lit:b} % --- Continue EG series: should now print as EG3, EG4 -------------------------- \EGseriesBegin \begin{scheme}[H] \replacecmpd{eg:d} % Expected: EG3 \replacecmpd{eg:e} % Expected: EG4 \includegraphics[width=.5\linewidth]{PhH-and-PhMe} \end{scheme} \EGseriesEnd \cmpd{eg:e} % --- Back to literature series: continues as 3,4 ------------------------------- \begin{scheme}[H] \replacecmpd{lit:c} % Expected: 3 \replacecmpd{lit:d} % Expected: 4 \includegraphics[width=.5\linewidth]{PhH-and-PhMe} \caption{Normal numbering} \end{scheme} \cmpd{lit:c} % --- Later EG block: continues again (no reset) -------------------------------- % NOTE: If you ever want to restart the EG series at EG1, you can reset the state: % \setcounter{cmpdEGstate}{0} \EGseriesBegin \begin{scheme}[H] \replacecmpd{eg:f} \replacecmpd{eg:g} \includegraphics[width=.5\linewidth]{PhH-and-PhMe} \end{scheme} \EGseriesEnd \end{document}
- Any better suggestions on the arrow on the arc of these kinds of contour figure with tikz?by Explorer on February 13, 2026 at 12:25 pm
This question is similar to this link, but not exactly the same focues. What I want, is something like: But I want a better looking and better syntax of the arrow: The figure above is produced by: \documentclass[tikz,border=5pt]{standalone} % https://tex.stackexchange.com/a/656167/322482 \usetikzlibrary{bending,decorations.markings,arrows.meta,calc,spath3} \usepackage{amsmath} \begin{document} \begin{tikzpicture}[ >={Kite[inset=0pt,length=.32cm,bend]}, baz/.style={spath/save=curve}, foo/.style={ draw,tips=true,->, spath/remove empty components={curve}, spath/split at keep start={curve}{#1}, spath/use=curve }, foo/.default=0.5, ] \filldraw[thick,fill=gray!40] (4,0) node[below]{$R$} arc (0:180:4) node[below]{$-R$} -- (-3,0) arc(180:0:1) -- (1,0) arc(180:0:1) -- cycle; \path[baz] (4,0) arc (0:90:4);\path[foo=.4]; \path[baz] (0,4) arc (90:180:4);\path[foo]; \path[baz] (-3,0) arc (180:0:1);\path[foo=.55]; \path[baz] (1,0) arc (180:0:1);\path[foo=.55]; \draw[-Stealth] (-5,0) -- (5,0) node[below]{$\Re$}; \draw[-Stealth] (0,0) -- (0,5) node[right]{$\Im$}; \path node[below] {$O$} (60:4) node[above=3pt] {$C_{R}$}; \end{tikzpicture} \end{document} which learning from Andrew Stacey's elegant solution (off-topic: I seemed to find some out-of-my-intuition features with spath3 and reported at here). I have two questions(actually could be regards only one) here, the best practice to typeset these kinds of contour figure: What kind of bending arrow on the arc in there cases could be more acceptable and beautiful?(maybe that is option-based, but I was still wonder how would you choose)? I don't think spath3 library is the only approach to do this, and IMHO, that is such a common requirement to add arrows on the curve, why there looks no too much tikz solution in this post? Any possible better practice to show the arrow shape with neater syntax?
- Bold math with unicode-math and siunitxby pejsek on February 12, 2026 at 5:42 pm
I am creating a table that needs a bold header. In the header I want to typeset units using siunitx. I want the units to be inside parentheses. I am also using the unicode-math package and compiling with LuaLaTeX. \documentclass{article} \usepackage{fontspec} \usepackage{unicode-math} \usepackage{booktabs} \usepackage{siunitx} \begin{document} \centering \setlength{\tabcolsep}{5mm} \renewcommand{\arraystretch}{1.1} \begin{tabular}{@{} l c @{}} \toprule \textbf{Material} & \textbf{Density} \(\symbf{ \left( \unit[per-mode=fraction]{\gram\per\centi\metre\cubed} \right) }\) \\ \midrule Air & \num{0.0012} \\ Water & \num{1} \\ \bottomrule \end{tabular} \end{document} The output looks like this: I want all of the header to be bold, including the scalable parentheses and all of the units. Like this: \documentclass{article} \usepackage{fontspec} %\usepackage{unicode-math} \usepackage{booktabs} \usepackage{siunitx} \begin{document} \centering \setlength{\tabcolsep}{5mm} \renewcommand{\arraystretch}{1.1} \begin{tabular}{@{} l c @{}} \toprule \textbf{Material} & \textbf{Density} \boldmath\( \left( \unit[reset-math-version=false,per-mode=fraction]{\gram\per\centi\metre\cubed} \right) \) \\ \midrule Air & \num{0.0012} \\ Water & \num{1} \\ \bottomrule \end{tabular} \end{document} I experimented with some variations of this question but without much success. Thank you for any help.
- Character variant applied only to initialby Apothikon on February 12, 2026 at 5:14 pm
I am trying to achieve exactly the same result as this question butwith LuaLaTex (so,possibly using Lua OTF handler): Can one set a specific character variant in xelatex for the word first letter only? EDIT: Another approach may be to use a Babel transformation, even though this would make the feature language-related. Any advice? I give here a (very) minimal working example: \documentclass{article} \usepackage{fontspec} \setmainfont{EBGaramond12-Italic.otf} % I want to add: [CharacterVariant=5:0] only to initial v % probably using \directlua {fonts.handlers.otf.addfeature \begin{document} Ha visto un valvassore vivere come un valvassino invidioso che gridava evviva! \end{document}
- Bold small caps in Times New Romanby rensemil on February 12, 2026 at 2:27 pm
I am using fontspec in order to write in Times New Roman. The authors of cited literature are always set in small caps. This initially made problems because the font has no small caps, but I solved those by googling and finding a solution on stackexchange. However, the small caps don't work when they are also bold, e.g. in a section heading. This is my MWE: \documentclass[12pt]{article} \usepackage[utf8]{inputenc} \usepackage[ngerman]{babel} \usepackage{fontspec} \setmainfont{Times New Roman}[ SmallCapsFont={TeX Gyre Termes}, SmallCapsFeatures={Letters=SmallCaps}, ] \begin{document} \section{Regel von \textsc{Ritschl}} Regel von \textsc{Ritschl} \end{document} Which produces: As you can see, the small caps in the text body work just fine. In the heading, however, the small caps are not set bold. When using the ebgaramond package, this issue does not occur and everything looks as it should and very pretty, but, of course, in Garamond: I actually prefer the looks of Garamond but unfortunately I have to write in Times New Roman. Does anyone know how this could be fixed? Thanks in advance! If relevant: I am using LaTeX with LaTeX workshop in VSCode on a MacBook Air.
- Formatting ToC and chapters in a tagged PDFby wsmith on February 12, 2026 at 4:54 am
I have been tasked with designing a template for creating a tagged PDF that meets certain formatting requirements. The only major obstacle I have encountered is in generating a Table of Contents that meets these (rather stringent) demands. Normally, I would use tocloft for this; however, as it has been pointed out in other posts, this is currently not an option. I have tried working around this, but I must admit that I am out of my depth. Between the default settings and some things I have found on this forum, I have been able to get the ToC to a place that I like. There are three things I still can't figure out: I would like to set the font (italic or boldface) for the chapters, sections, subsection, etc. I would like to force chapter titles to appear uppercase in the ToC. I need to add the word "Page" above the page numbers in the ToC, list of figures, and list of tables. I have a cheap workaround for (2) which is just to make a new command: \newcommand{\Chapter}[1]{\chapter[\MakeUppercase{#1}]{#1}} but this is quite stupid. To acheive (3), I write \makeatletter \newcommand{\pageheaderlabel}{ \hfill\makebox[\@pnumwidth][c]{Page}\par\smallskip } \let\old@starttoc\@starttoc \renewcommand{\@starttoc}[1]{ \pageheaderlabel \old@starttoc{#1} } \makeatother but this is quite hacky (and is slightly off-center). On a somewhat related note, I have been using titlesec as I normally would; e.g, \usepackage[rm, tiny, center, compact]{titlesec} \titleformat{\chapter} {\ifdefined\boldheadings\bfseries\fi\centering\normalsize} {\thechapter.}{1em}{\makeuppercase} \titlespacing*{\chapter} {0pt} {0pt} {20pt} and I have not encountered any issues, despite the fact it is currently marked as incompatible with tagging. If it is breaking something, I cannot tell what. If there are any known workarounds to achieve this without titlesec, that would be much appreciated. ADDENDUM: Here is a stripped down example: % !TeX program = lualatex \DocumentMetadata{uncompress,lang=en, tagging=on, pdfstandard=ua-2,pdfstandard=a-4f} \documentclass[12pt]{report} \usepackage{lipsum} \usepackage[hidelinks]{hyperref} \usepackage{etoolbox} \usepackage[doublespacing]{setspace} \usepackage[letterpaper]{geometry} \geometry{verbose, margin=1in} \usepackage[rm, tiny, center, compact]{titlesec} % FORMATTING OPTIONS: %\def\BoldHeadings{} % <- uncomment to make chapters boldface (Goal: toggle consistently with ToC) \titleformat{\chapter} {\ifdefined\BoldHeadings\bfseries\fi\centering\normalsize} {\thechapter.}{1em}{\MakeUppercase} \titlespacing*{\chapter} {0pt} {0pt} {20pt} % To make "Page" appear above page #'s in TOC \makeatletter \newcommand{\pageheaderlabel}{ \hfill\makebox[\@pnumwidth][c]{Page}\par\smallskip } \let\old@starttoc\@starttoc \renewcommand{\@starttoc}[1]{ \pageheaderlabel \old@starttoc{#1} } \makeatother % add dots, courtesy of linked post \AddToHookWithArguments{contentsline/text/after}{ \ifnum#1=0 \dotfill \fi } % stupid trick to force chapter titles to be uppercase in TOC \newcommand{\Chapter}[1]{\chapter[\MakeUppercase{#1}]{#1}} \begin{document} \chapter*{TABLE OF CONTENTS} \addcontentsline{toc}{chapter}{TABLE OF CONTENTS} \begin{singlespace} \renewcommand\contentsname{\normalfont} {} \begingroup \let\clearpage\relax \let\cleardoublepage\relax \tableofcontents \endgroup \end{singlespace} \newpage % similar for LoF, LoT \Chapter{Fake Chapter} \section{Fake Section} \subsection{Fake Subsection 1} \subsubsection{Fake Subsubsection} \lipsum[3] \subsection{Fake Subsection 2} \lipsum[1] \end{document}
- How can I geometrically translate a line segment on a line?by Jasper on February 12, 2026 at 4:17 am
How can I geometrically translate a line segment on a line? I want to move the pink segment so that it starts at three and goes to four. I don't just want to teleport it. I want a geometric construction for this - Euclidean style. \documentclass[tikz,border=1cm]{standalone} \begin{document} \begin{tikzpicture} \draw[thick,->] (-1,0) -- (5,0) node[below left] {\(x\)}; \draw[ preaction = { draw = black, line width = 4pt }, postaction = { draw = pink, line width = 2pt } ] (0,0) -- (1,0); \fill (0,0) circle[radius = 3pt] node[below=3pt] {\(0\)}; \fill (1,0) circle[radius = 3pt] node[below=3pt] {\(1\)}; \fill (3,0) circle[radius = 3pt] node[below=3pt] {\(3\)}; \end{tikzpicture} \end{document}
- Crop certain percent from each side of the figureby monty01 on February 11, 2026 at 8:20 pm
I would like to crop x percent from each side from the img. \documentclass{article} \usepackage{graphicx} \begin{document} \begin{figure}[h] \centering \includegraphics[scale=0.3]{example-image-a} \caption{Caption} \label{fig:placeholder} \end{figure} \end{document} insted of using \includegraphics[scale=0.3]{example-image} I would like to call \cropimg{scale}{img}{crop percentage}
- Biblatex: First citation as full author + title; following citations ibid. or - when interrupted - short author-title citationby alcuinus on February 11, 2026 at 7:30 pm
The journal I am writing for requires: Whenever a bibliography entry is cited the first time: given name, family name, title, page -- no other data as publisher and so on When it is used again with other entries in between it will be shown as: familyname, title, page When it is used again without other entries in between it will be shown as"Ibid." With ext-verbose-trad1, citetracker=true I get "cit." which is not required. MWE: \documentclass[a4paper]{article} \usepackage[style=ext-verbose-trad1, citetracker=true,backend=biber]{biblatex} \begin{filecontents*}{\jobname.bib} @Book{A1, author = {Author, Anton}, title = {The First Very Long Title}, subtitle = {The Subtitle}, shorttitle = {The First}, year = {1900}, publisher = {The Printer}, address = {Printtown} } @Book{B2, Author = {Black, Berth}, Title = {The Second Title}, Year = {2000}, publisher = {The Typesetter}, address = {Typetown} } \end{filecontents*} \addbibresource{\jobname.bib} \begin{document} First title:\autocite[34]{A1}. Second citation (same title other page)\autocite[70]{A1}. Second title\autocite[12]{B2}. Back to first book (other page)\autocite[50]{A1}. Back to the first book (other page)\autocite[60]{A1}. Back to the first book (same page)\autocite[60]{A1}. Second title again\autocite[21]{B2}. \printbibliography \end{document} Question. How to substitute "cit." with shorttitle or title? See notes 4 and 7. The first and third note should print only given name + family name + title, but I will ask this in another post. Thanks for any help.
- pgfplots: Adjust groupplot to text widthby cis on February 11, 2026 at 9:28 am
I have a 2×2 groupplot (where the first plot should be replaced by a title "Supertitle") with titles in boxes. These "title boxes" should all have the same width, and boxes in the same row should have the same height. I achieved this using \vphantom{} because I didn't find a better method. How can I configure the settings such that the entire groupplot has a width of \textwidth? And a horizontal space between the columns like \tabcolsep (or something similar)? Is there a elegant way to do this by package keys? (resizebox etc. would certainly work, but that would be less elegant.) Ideally, it should stay a groupplot. PS: I'm using DIN A5 format here, but that shouldn't matter if the keys are set correctly. \documentclass[paper=a5]{scrartcl} \usepackage[margin=14mm, showframe]{geometry} \usepackage{pgfplots} \usepgfplotslibrary{groupplots} \pgfplotsset{compat=1.18} \begin{document} \section{Plots with Titles and Supertitle} \pgfmathsetlengthmacro\plotwidth{0.5*\textwidth-\the\arraycolsep} \begin{tikzpicture}[font=\footnotesize] \begin{groupplot}[ % Grouupplot settings ================== group style={ group size=2 by 2, % 2 columns, 2 rows vertical sep=25mm, horizontal sep=15mm, }, % Styles applied to all subplots ============== width=\plotwidth, height=30mm, % Title Styles ========================== title style={% at={(0,1)}, xshift=-3ex, align=left, anchor=south west, inner xsep=2pt, draw, fill=none, text width=0.925*\pgfkeysvalueof{/pgfplots/width}, },% ] % Title (Row 1, Col 1) \nextgroupplot[ % I don't know how to get this box to the same height without this trick: title={\vphantom{Plot 0} \\ \vphantom{000} \\ \vphantom{000}}, title style={name=super}, hide axis, ] \addplot[draw=none, samples={0}]{x}; % Plot 0 (Row 1, Col 2) \nextgroupplot[title={Title 0 \\ 000 \\ 000}] \addplot{x}; % Plot 1 (Row 2, Col 1) \nextgroupplot[title={Title 1 \\ 2-111 \\ 3-111 \\ 4-111}] \addplot{x^2}; % Plot 2 (Row 2, Col 2) \nextgroupplot[title={Title 2 \\ 2-222 \\ 3-222 \\ \vphantom{4-111}}] \addplot{x^3}; \end{groupplot} %% Supertitle \node[font=\bfseries\Large] at (super){Supertitle}; \node[anchor=north west, draw=none, align=left,] at (super.south west){ Some notes \\ below Supertitle}; \draw[cyan, very thick, |-|] (group c1r2.west) -- +(\plotwidth,0) node[midway, below, fill=yellow]{plotwidth =\plotwidth}; %% This gives a 'Overfull \hbox ' warning ================== \draw[red, thick, |-|, ] ([yshift=5mm]group c1r2.west) -- +(2*\plotwidth,0) node[midway, above, fill=yellow]{2*plotwidth =\plotwidth}; \end{tikzpicture} \end{document}
- Highlighting matrix multiplicationby Dimitrios ANAGNOSTOU on February 10, 2026 at 11:58 pm
I know there are several relevant questions on TeX Stack Exchange about nicely highlighting matrix multiplication, and some of them have excellent answers. I apologize if my question is a duplicate. I have managed to highlight the various entries manually, but it requires quite a bit of work. Is there a way to automate this procedure? \documentclass{article} \usepackage{amsmath, amssymb} \usepackage{xcolor} \usepackage[margin=1.5cm]{geometry} \begin{document} \section*{Matrix Multiplication} We want to compute the product \(AB\) for \[ A = \begin{bmatrix} 3 & 1 & -1 \\ -1 & 0 & 4 \end{bmatrix}, \quad B = \begin{bmatrix} 2 & 1 & 3 \\ -1 & 3 & 4 \\ 0 & 2 & 5 \end{bmatrix}. \] We can illustrate the multiplication as follows, highlighting each row of \(A\) and each column of \(B\): \[ \begin{array}{c@{\hspace{2em}}c@{\hspace{1em}}c} & \begin{bmatrix} \color{blue}{2} & \color{orange}{1} & \color{purple}{3} \\ \color{blue}{-1} & \color{orange}{3} & \color{purple}{4} \\ \color{blue}{0} & \color{orange}{2} & \color{purple}{5} \end{bmatrix} & \\[1em] % \begin{bmatrix} \color{red}{3} & \color{red}{1} & \color{red}{-1} \\ \color{green}{-1} & \color{green}{0} & \color{green}{4} \end{bmatrix} & = & \begin{bmatrix} \underbrace{\color{red}{3}\cdot \color{blue}{2} + \color{red}{1}\cdot \color{blue}{-1} + \color{red}{-1}\cdot \color{blue}{0}}_{\color{black}{5}} & \underbrace{\color{red}{3}\cdot \color{orange}{1} + \color{red}{1}\cdot \color{orange}{3} + \color{red}{-1}\cdot \color{orange}{2}}_{\color{black}{4}} & \underbrace{\color{red}{3}\cdot \color{purple}{3} + \color{red}{1}\cdot \color{purple}{4} + \color{red}{-1}\cdot \color{purple}{5}}_{\color{black}{8}} \\[0.5em] % \underbrace{\color{green}{-1}\cdot \color{blue}{2} + \color{green}{0}\cdot \color{blue}{-1} + \color{green}{4}\cdot \color{blue}{0}}_{\color{black}{-2}} & \underbrace{\color{green}{-1}\cdot \color{orange}{1} + \color{green}{0}\cdot \color{orange}{3} + \color{green}{4}\cdot \color{orange}{2}}_{\color{black}{7}} & \underbrace{\color{green}{-1}\cdot \color{purple}{3} + \color{green}{0}\cdot \color{purple}{4} + \color{green}{4}\cdot \color{purple}{5}}_{\color{black}{17}} \end{bmatrix} \end{array} \] Thus, the final product is \[ AB = \begin{bmatrix} 5 & 4 & 8 \\ -2 & 7 & 17 \end{bmatrix}. \] \bigskip \textit{Note:} \(BA\) is not defined because \(B\) is \(3\times 3\) and \(A\) is \(2\times 3\); the number of columns of \(B\) (3) does not match the number of rows of \(A\) (2). In general, \(AB \neq BA\). \end{document}
- Another way to write powers?by Lara de Assumpcao Maffei Piero on February 10, 2026 at 10:43 pm
My new keyboard writes ^ as ˆ, and overleaf doesn't recognize these the same way. Is there an alternative symbol in latex for writting powers and indexes or some way to make overleaf recognize ˆ as ^?
- Numbering equations in dcases without \usepackage{empheq}by Sebastiano on February 10, 2026 at 9:09 pm
At the moment, I don't remember how to number the equations inside dcases , with the amsart class, without empheq, in order to assign a label to each one. \documentclass{amsart} \usepackage{mathtools} \begin{document} \begin{subequations} \begin{equation} \begin{dcases} 0 \le \frac{u+v}{2} \le 1 \\ 0 \le \frac{v-u}{2} \le 1 - \frac{u+v}{2} \end{dcases} \iff \begin{dcases} 0 \le u+v \le 2 \\ \label{Psojjn} 0 \le v-u \le 2 - (u+v) \end{dcases} \end{equation} \end{subequations} \end{document} Addendum: My desidered output.
- Creating Circular Domains with TikZ [closed]by Assuério Cavalcante on February 10, 2026 at 3:45 pm
First, apologies if this question has been asked before. I'm trying to create an image of a particular circular domain, but my limited TikZ knowledge has made this quite challenging. I've searched for similar examples online without success. Any guidance would be greatly appreciated!
- Interesting dashed linesby Dhairya Kumar on February 10, 2026 at 10:50 am
While writing down the above expression on Overleaf, I encountered the problem of drawing the dashed line in between the Left Hand Side and the Right Hand Side expressions. Do help me in writing it exactly that way. (I had written it in my own unique way, but without the dashed line, and would be intrigued to know if such a function existed.) My code & Output: \documentclass{article} \usepackage{amsmath} \begin{document} ARCTAN TERMS: \[\boxed{\sqrt{2}\zeta_1+1 \to \infty \implies \tan^{-1}(\sqrt{2}\zeta_1+1)\rightarrow \dfrac{\pi}{2}}\text{ and } \boxed{\sqrt{2}\zeta_1+1 \rightarrow -\infty \implies \tan^{-1}(\sqrt{2}\zeta_1+1)\to \dfrac{-\pi}{2}}\] \[\boxed{\sqrt{2}\zeta_1-1 \to \infty \implies \tan^{-1}(\sqrt{2}\zeta_1-1)\rightarrow \dfrac{\pi}{2}}\text{ and } \boxed{\sqrt{2}\zeta_1-1 \rightarrow -\infty \implies \tan^{-1}(\sqrt{2}\zeta_1-1)\to \dfrac{-\pi}{2}}\] Hence, \[\text{ Arctan terms evaluates to } \frac{\sqrt{2}}{4}\left(\frac{\pi}{2}+\frac{\pi}{2}-\left(\frac{-\pi}{2}-\frac{\pi}{2}\right)\right)=\frac{\pi}{\sqrt2}\] \end{document} Output:
- Rows of 'cases' environment too close to each otherby Dhairya Kumar on February 10, 2026 at 6:10 am
I have an issue in typing the above equation in LaTeX, where the two rows of the cases environment are so close that they almost touch. Help me do it in a clean way. Code: \[ \boxed{ \displaystyle\int\limits_{0}^{\pi/2}\sin^{n}{x}dx= \displaystyle\int\limits_{0}^{\pi/2}\cos^{n}{x}dx= \begin{cases} \dfrac{n-1}{n}\cdot\dfrac{n-3}{n-2}\cdots \dfrac45 \cdot\dfrac23 \text{ if $n$ is odd}\\ \dfrac{n-1}{n}\cdot\dfrac{n-3}{n-2}\cdots \dfrac34 \cdot\dfrac12\cdot \dfrac{\pi}{2}\text{ if $n$ is even} } \]
- How can the roots of a quadratic equation be written in radical form?by Laurenso on February 10, 2026 at 3:52 am
I am trying to express the roots of a quadratic equation `t^2-3t-7=0' in radical form. I tried \documentclass[12pt]{article} \usepackage{polexpr} \usepackage{xint} \begin{document} \poldef f(t) = t^2-3t-7; \xintdefvar a = (f(2)-2*f(1)+f(0))/2; \xintdefvar c = f(0); \xintdefvar b = reduce(f(1)-a-c); \xintdefvar delta = b^2 - 4*a*c; \xintdefvar t1=reduce((-b+sqrt(delta))/2/a); \xintdefvar t2=reduce((-b-sqrt(delta))/2/a); \[\xinteval{t1}, \quad \xinteval{t2}\] \[t=\frac{1}{2} \left(3-\sqrt{37}\right)\lor t=\frac{1}{2} \left(3+\sqrt{37}\right).\] \end{document} I got How can I get?
- TikZ curved arrow bisecting text - how to increase arc height to clear obstacle?by Oregon Math Tutor on February 9, 2026 at 8:19 pm
I'm annotating a fraction with TikZ arrows pointing to specific parts. The blue arrow works fine, but the red curved arrow is bisecting the "3" in the denominator instead of arcing over it. Current behavior: The red arrow cuts straight through the middle of "3" Desired behavior: The red arrow should arc upward and over the "3" with clear space. I initially tried adjusting the out angle from 160° to 120° to make it launch upward, but this still results in the arrow bisecting the number. How do I increase the arc height to make the curve clear the "3" completely as shown in the 2nd image? Note: I'm still learning TikZ best practices. If you spot any obvious improvements to the code structure, please mention them. MWE \usepackage{mathtools} \usetikzlibrary{calc, arrows.meta} \definecolor{textBlue}{RGB}{50, 50, 255} \definecolor{deepRed}{RGB}{200, 40, 40} \begin{document} \begin{tikzpicture} % Math fraction \node (fraction) at (0,0) { \scalebox{1.8}{% $\displaystyle \frac{2x^3 - 5x^2 - x + 3}{x + 3}$ } }; % Blue annotation (works fine) \node[ellipse, draw=textBlue, dashed, minimum width=0.3cm, minimum height=0.6cm, xshift=-0.4cm, yshift=0.4cm] (blueCircle) at ($(fraction.south) + (-0.65, 0.28)$) {}; \node[draw=textBlue, text=textBlue, align=center, anchor=north] (blueLabel) at ($(blueCircle.south) + (0, -0.6)$) {coefficient\\must be 1}; \draw[textBlue, ->, >=latex] (blueLabel.north) -- (blueCircle.south); % Red annotation (PROBLEM: arrow bisects the "3") \node[circle, draw=deepRed, dashed, minimum size=0.2cm, xshift=-0.2cm, yshift=0.3cm] (redCircle) at ($(fraction.south) + (-0.2, 0.55)$) {}; \node[draw=deepRed, text=deepRed, align=left, anchor=west] (redLabel) at ($(fraction.south) + (0.8, 0.3)$) {exponent\\must be 1}; % This arrow bisects "3" - how to make it arc higher? \draw[deepRed, ->, >=latex] (redLabel.west) to[out=120, in=0] (redCircle.east); \end{tikzpicture} \end{document}``` [1]: https://i.sstatic.net/zirlpD5n.png [2]: https://i.sstatic.net/BOIovYSz.png
- Format enumitem inline listby user1 on February 9, 2026 at 2:18 pm
Outgoing from the question Dropping separator at line break in an inline list I want to achieve some more things: Line breaks should (if possible) only be placed between items The list should have a left and right margin (maybe it is easier to not use an inline list?) The list should be centered There should be no vspace inserted above or below the list Note that \textperiodcentered is a separator, not a label (aka. bullet point) The list should be startet at a new line and end with a line break (Done, but I guess (2.) solves this automatically. MWE: \documentclass[a4paper]{article} \usepackage{showframe} \newcommand{\middot}{~\textperiodcentered~} \usepackage{enumitem} \newlist{skills}{itemize*}{1} \setlist[skills]{label={}, afterlabel={}, leftmargin=2cm, rightmargin=2cm, before={\newline}, after={\newline}, itemjoin=\discretionary{}{}{\hbox{\middot}}} %TODO leftmargin and rightmargin have no effect \setlength{\parindent}{0pt} \begin{document} Text before \begin{skills} \item This \item list \item should \item only \item break \item between \item items \item and not inside a longer item \item Also \item this \item list \item should \item be \item centered \item and \item indented \end{skills} text after \vspace{2cm} The desired output is: Text before (no vspace before the list) \vspace{-3mm} \begin{center} This\hbox{\middot}list\hbox{\middot}should\hbox{\middot}only\hbox{\middot}break\hbox{\middot}between \hbox{\middot}items and not inside a longer item\hbox{\middot}Also\hbox{\middot}this\hbox{\middot}list\hbox{\middot}should\hbox{\middot}be centered\hbox{\middot}and\hbox{\middot}indented \end{center} \vspace{-3mm} text after (no vspace after the list) \end{document}
- Standard practices in label decluttering: overcoming overlapping label linesby Jasper on February 8, 2026 at 11:59 pm
I have a situation where I want to lable the sample points of a line segment, and also label the smaller line segments connecting those sample points. My labels are really cluttered right now. How can I make this more proper? \documentclass[tikz,border=1cm]{standalone} \begin{document} \begin{tikzpicture} \draw[thick,->] (-1,0) -- (5,0) node[below left] {\(x\)}; \fill (0.5,0) circle[radius = 3pt] node[above] {point}; \fill[gray] (0.5,0) circle[radius = 1.5pt]; \draw[] (0.5,0) -- (0.5,-2) -- (5,-2) node[right] {individual sample point}; \draw[line width = 6pt] (2,0) -- (3.5,0) node[above,pos=0.5]{line segment}; \foreach[count = \c from 1] \x in {2,2.5,...,3.5} { \fill[gray] (\x,0) circle[radius = 1.5pt]; \draw[] (\x,0) -- (4,-1); \ifnum\c=4\else\draw[thick,gray] (\x,0) -- ++(0.5,0);\fi } \draw[](4,-1) -- (5,-1) node[right] {multiple sample points}; \foreach[count = \c from 1] \x in {2.25,2.75,...,3.25} { \draw[] (\x,0) -- (4,-1.5); } \draw[](4,-1.5) -- (5,-1.5) node[right] {one or more line segments}; \end{tikzpicture} \end{document}
- Twisted Equalityby Entropy on February 8, 2026 at 8:14 pm
I am trying to create a new math symbol. Could someone please help me with it? My current code: \documentclass[12pt]{report} \RequirePackage{tikz} \newcommand{\eq}{\begin{tikzpicture}% [scale=.175, line width=0.5pt] \draw (-1,1) -- (0,0); \draw (0,1) -- (-0.5,0.5); \draw (0,-1) -- (-1,0); \draw (-0.5,-0.5) -- (-1,-1); \end{tikzpicture}} \begin{document} \[ u - \eq - u \] \end{document} However, the symbol I am actually going for is this: I was using it for something like this:
- pgfplots: axis-enlargement at a ybar plot (example: binomial distribution)by cis on February 8, 2026 at 4:34 pm
I wanted to adapt this nice solution for my purposes. • I want to extend the x- and y-axes a bit. But, when I set enlarge y limits={upper, abs=0.125} it creates a strange gap (ymin=0 is no longer respected, and restrict y to domain=0:1 seems to have no effect). • Secondly, what's the best way to configure it so that bars with very small y-values are also visible here? • Unfortunately, I saw this too late: I would also like to eliminate this x-gap between the first bar and the y-axis! \documentclass[margin=5pt]{standalone} \usepackage{pgfplots} \pgfplotsset{compat=1.18} \begin{document} \begin{tikzpicture}[font=\footnotesize, declare function={ binom(\n,\p,\k)=\n!/(\k!*(\n-\k)!)*\p^\k*(1-\p)^(\n-\k); } ] \begin{axis}[%y=8mm, no effect ymin=0, xmin=0, axis lines=left, axis line style={-latex}, xlabel={$k$}, ylabel={$P(X=k)$}, x label style={at={(axis description cs:1,0)}, anchor=south east, inner xsep=0pt }, y label style={at={(axis description cs:0,1)}, rotate = -90, anchor=north west, inner ysep=0pt, }, yticklabel style={ /pgf/number format/fixed, /pgf/number format/fixed zerofill, /pgf/number format/precision=2 }, ybar=0pt, bar width=1, bar shift=0pt, samples at={0,...,13}, variable=\k, enlarge x limits={upper, abs=0.785}, enlarge y limits={upper, abs=0.125}, %restrict y to domain=0:1,% no effect.... ] \addplot [fill=gray!25] {binom(13, 0.4, k)}; %\addplot [fill=orange, samples at={0,...,4}] {binom(12,0.4,k)}; %\addplot [fill=cyan, samples at={7}] {binom(12,0.4,k)}; \end{axis} \end{tikzpicture} \end{document}
- How can I draw a coloured factorization diagram?by Bayaraa Surenjav on February 8, 2026 at 4:11 pm
My code is: \documentclass[tikz,border=10pt]{standalone} \usepackage[utf8]{inputenc} \usepackage[mongolian]{babel} \usepackage{amsmath} \usetikzlibrary{calc, positioning, arrows.meta, backgrounds, shapes.geometric} \begin{document} \begin{tikzpicture}[ num node/.style={ font=\Large\bfseries\rmfamily, % Serif font, Bold anchor=east, inner sep=3pt, minimum height=0.65cm }, div node/.style={ font=\Large\rmfamily, anchor=east, inner sep=3pt }, arrow style/.style={ ->, >=latex, draw=cyan!80!blue, line width=0.8pt }, label text/.style={ text=cyan!80!blue, font=\itshape, align=right }, % Үйлдлийн тэмдэг (div 2) op label/.style={ text=cyan!80!blue, font=\large, anchor=west, xshift=2pt } ] \def\rowh{0.9} \node[div node] (d1) at (0,0) {2)}; \node[num node] (n1) at (1.8,0) {120}; \draw[thick] (d1.south east) -- (n1.south east); \node[div node] (d2) at (0,-\rowh) {2)}; \node[num node] (n2) at (1.8,-\rowh) {60}; \draw[thick] (d2.south east) -- (n2.south east); \node[div node] (d3) at (0,-2*\rowh) {2)}; \node[fill=cyan!25, inner sep=2pt, minimum height=0.6cm, minimum width=0.8cm, anchor=east] at (1.85,-2*\rowh) {}; \node[num node, text=magenta] (n3) at (1.8,-2*\rowh) {30}; \draw[thick] (d3.south east) -- (n3.south east); \node[div node] (d4) at (0,-3*\rowh) {3)}; \node[num node] (n4) at (1.8,-3*\rowh) {15}; \draw[thick] (d4.south east) -- (n4.south east); \node[num node] (n5) at (1.8,-4*\rowh) {5}; \begin{scope}[on background layer] % Зүүн талын босоо багана (Хуваагчдыг хамарсан) \fill[cyan!15] (-0.8, 0.4) rectangle (0.2, -4.5*\rowh); \fill[cyan!15] (-0.8, -3.65*\rowh) rectangle (2.2, -4.5*\rowh); \end{scope} \def\arm{0.5} \draw[arrow style] (n1.east) -- ++(\arm,0) |- node[pos=0.25, op label] {$\div 2$} (n2.east); \draw[arrow style] (n2.east) -- ++(\arm,0) |- node[pos=0.25, op label] {$\div 2$} (n3.east); \draw[arrow style] (n3.east) -- ++(\arm,0) |- node[pos=0.25, op label] {$\div 2$} (n4.east); \draw[arrow style] (n4.east) -- ++(\arm,0) |- node[pos=0.25, op label] {$\div 3$} (n5.east); \node[label text] (txt1) at (-3.5, 0) {анхны тоогоор хуваах}; \draw[arrow style] (txt1) -- (d1.west); \node[label text] (txt2) at (-4, -4*\rowh) {анхны тоо гартал үргэлжлүүлнэ}; \draw[arrow style] (txt2) -- (n5.west); \end{tikzpicture} \end{document} Current: Intended:
- Equation with captionby palloc on February 8, 2026 at 12:01 pm
I would like to add caption to my equation, how could I do that? \documentclass{article} \begin{document} \begin{equation} E = mc^2 \label{eq:emc} \end{equation} \ref{eq:emc} \end{document}
- I would like to number subcases as well with 1a, 1bby palloc on February 8, 2026 at 11:12 am
I have the following code, I would like to number the subcases with 1a, 1b, so not just one big case with (1). \documentclass{article} \usepackage{amsmath} \begin{document} \begin{equation} f(x) = \begin{cases} x^2& x \ge 0,\\ -x & x < 0. \end{cases} \end{equation} \end{document}
- Configure `keytheorems` so that it produces the same output as `ntheorem`by Denis Bitouzé on February 8, 2026 at 9:48 am
For a class of mine, I'm in the process to switch from ntheorem to keytheorems but, for compatibility reason, I would like to make the output of “theorems” as identical as possible. Unfortunately, it is not the case, as shown in the following M( non realistic )CE: \RequirePackage{comment} \includecomment{kt}\excludecomment{nt} % \includecomment{nt}\excludecomment{kt} \documentclass{article} \usepackage[ textwidth=12.75cm, paperwidth=14cm, paperheight=2cm, showframe ]{geometry} \begin{kt} \usepackage{keytheorems} \newkeytheoremstyle{rmk-style}{ inherit-style=definition, notefont=\bfseries, headpunct={~--} } \newkeytheorem{rmk}[style=rmk-style,name=Remark] \end{kt} \begin{nt} \usepackage{ntheorem} \theoremstyle{plain} \theoremheaderfont{\normalfont\bfseries} \theorembodyfont{\normalfont} \theoremseparator{~--} \theoremsymbol{} \newtheorem{rmk}{Remark} \end{nt} \begin{document} \begin{rmk}[Euler's identity] One of the most beautiful mathematical equation: \[ e^{i\pi}+1=0 \] \end{rmk} \end{document} As it is (keytheorems in force), the output is the following: whereas, if the second line is commented and the third one is uncommented (ntheorem in force), the output is the following: How could I configure keytheorems in order it produces the same output as ntheorem?
- Why do I keep getting "database doesn't exist" error when I try to read a csv with datatool \DTLread[name=gradesDB,format=csv]{data.csv}?by nt54 on February 8, 2026 at 5:33 am
I'm trying to read a simple csv into a datatool database and then populate a table with this data. The persistent error is reported as "Package datatool error: Database 'gradesDB doesn't exist' in the TeXworks console output. I'm using the current TeXworks 2025 full/complete installation. The csv was encoded as uft-8. This csv file is named data.csv (NOTE: In the preview of this post this file appears in a single row format. It is actually written as a 4 row x 3 column form with the first three rows terminated by CRLF) Name,Surname,Grade Albert,Einstein,147 Marie,Curie,159 Thomas,Edison,179 I've consulted online AI and version 3.4.3 2025-12-04 of The Datatool Bundle: Databases and Data Manipulation from Dickimaw Books for documentation. This package is new to me and I have a feeling is there is a simple error I'm not catching. I greatly appreciate any help you might offer. Thanks in advance. \documentclass{article} \usepackage{datatool} \usepackage{booktabs} % Optional: provides better horizontal lines (\\toprule, \\midrule, \\bottomrule) \usepackage[utf8]{inputenc} \DTLloaddb{gradesDB}{data.csv} \begin{document} \section{Student Grades} % Load the CSV file into a database named 'gradesDB' %% Note the following command is now deprecated according to docs %% \DTLloaddb[autonum=false]{gradesDB}{data.csv} \DTLnewdb{gradesDB} \DTLread[name=gradesDB,format=csv]{data.csv} % Begin the table environment \begin{table}[h] \centering \caption{Grades of Students} \label{tab:grades} % Begin the tabular environment with column specifications \begin{tabular}{c c c } \toprule \textbf{Name} & \textbf{Surname} & \textbf{Grade} \\ \midrule % Iterate through each row in the 'gradesDB' database \DTLforeach*{gradesDB}{% \Name=Name,% \Surname=Surname,% \Grade=Grade% }{% % Format each row \Name & \Surname & \Grade \\ } \bottomrule \end{tabular} \end{table} \end{document} The log file: This is pdfTeX, Version 3.141592653-2.6-1.40.28 (TeX Live 2025) (preloaded format=pdflatex 2026.2.7) 8 FEB 2026 00:19 entering extended mode restricted \write18 enabled. %&-line parsing enabled. **test_read.tex (./test_read.tex LaTeX2e <2025-11-01> L3 programming layer <2026-01-19> (c:/texlive/2025/texmf-dist/tex/latex/base/article.cls Document Class: article 2025/01/22 v1.4n Standard LaTeX document class (c:/texlive/2025/texmf-dist/tex/latex/base/size10.clo File: size10.clo 2025/01/22 v1.4n Standard LaTeX file (size option) ) \c@part=\count275 \c@section=\count276 \c@subsection=\count277 \c@subsubsection=\count278 \c@paragraph=\count279 \c@subparagraph=\count280 \c@figure=\count281 \c@table=\count282 \abovecaptionskip=\skip49 \belowcaptionskip=\skip50 \bibindent=\dimen148 ) (c:/texlive/2025/texmf-dist/tex/latex/datatool/datatool.sty Package: datatool 2025/12/04 v3.4.3 (NLCT) (c:/texlive/2025/texmf-dist/tex/latex/base/ifthen.sty Package: ifthen 2024/03/16 v1.1e Standard LaTeX ifthen package (DPC) ) (c:/texlive/2025/texmf-dist/tex/latex/xfor/xfor.sty Package: xfor 2009/02/05 v1.05 (NLCT) ) (c:/texlive/2025/texmf-dist/tex/latex/etoolbox/etoolbox.sty Package: etoolbox 2025/10/02 v2.5m e-TeX tools for LaTeX (JAW) \etb@tempcnta=\count283 ) (c:/texlive/2025/texmf-dist/tex/latex/tracklang/tracklang.sty Package: tracklang 2025/03/11 v1.6.6 (NLCT) Track Languages (c:/texlive/2025/texmf-dist/tex/generic/tracklang/tracklang.tex)) (c:/texlive/2025/texmf-dist/tex/latex/datatool/datatool-base.sty Package: datatool-base 2025/12/04 v3.4.3 (NLCT) (c:/texlive/2025/texmf-dist/tex/latex/amsmath/amsmath.sty Package: amsmath 2025/07/09 v2.17z AMS math features \@mathmargin=\skip51 For additional information on amsmath, use the `?' option. (c:/texlive/2025/texmf-dist/tex/latex/amsmath/amstext.sty Package: amstext 2024/11/17 v2.01 AMS text (c:/texlive/2025/texmf-dist/tex/latex/amsmath/amsgen.sty File: amsgen.sty 1999/11/30 v2.0 generic functions \@emptytoks=\toks17 \ex@=\dimen149 )) (c:/texlive/2025/texmf-dist/tex/latex/amsmath/amsbsy.sty Package: amsbsy 1999/11/29 v1.2d Bold Symbols \pmbraise@=\dimen150 ) (c:/texlive/2025/texmf-dist/tex/latex/amsmath/amsopn.sty Package: amsopn 2022/04/08 v2.04 operator names ) \inf@bad=\count284 LaTeX Info: Redefining \frac on input line 233. \uproot@=\count285 \leftroot@=\count286 LaTeX Info: Redefining \overline on input line 398. LaTeX Info: Redefining \colon on input line 409. \classnum@=\count287 \DOTSCASE@=\count288 LaTeX Info: Redefining \ldots on input line 495. LaTeX Info: Redefining \dots on input line 498. LaTeX Info: Redefining \cdots on input line 619. \Mathstrutbox@=\box53 \strutbox@=\box54 LaTeX Info: Redefining \big on input line 721. LaTeX Info: Redefining \Big on input line 722. LaTeX Info: Redefining \bigg on input line 723. LaTeX Info: Redefining \Bigg on input line 724. \big@size=\dimen151 LaTeX Font Info: Redeclaring font encoding OML on input line 742. LaTeX Font Info: Redeclaring font encoding OMS on input line 743. \macc@depth=\count289 LaTeX Info: Redefining \bmod on input line 904. LaTeX Info: Redefining \pmod on input line 909. LaTeX Info: Redefining \smash on input line 939. LaTeX Info: Redefining \relbar on input line 969. LaTeX Info: Redefining \Relbar on input line 970. \c@MaxMatrixCols=\count290 \dotsspace@=\muskip17 \c@parentequation=\count291 \dspbrk@lvl=\count292 \tag@help=\toks18 \row@=\count293 \column@=\count294 \maxfields@=\count295 \andhelp@=\toks19 \eqnshift@=\dimen152 \alignsep@=\dimen153 \tagshift@=\dimen154 \tagwidth@=\dimen155 \totwidth@=\dimen156 \lineht@=\dimen157 \@envbody=\toks20 \multlinegap=\skip52 \multlinetaggap=\skip53 \mathdisplay@stack=\toks21 LaTeX Info: Redefining \[ on input line 2950. LaTeX Info: Redefining \] on input line 2951. ) \l__datatool_tmpa_int=\count296 \l__datatool_tmpb_int=\count297 \l__datatool_tmpc_int=\count298 \l__datatool_tmpd_int=\count299 \l__datatool_count_int=\count300 \l__datatool_tmp_datatype_int=\count301 \l__datatool_tmpa_dim=\dimen158 \l__datatool_tmpb_dim=\dimen159 (c:/texlive/2025/texmf-dist/tex/latex/datatool/datatool-l3fp.def File: datatool-l3fp.def 2025/12/04 v3.4.3 (NLCT) ) \@dtl@toks=\toks22 \@dtl@tmpcount=\count302 \dtl@tmplength=\skip54 \l__datatool_measure_box=\box55 \dtl@sortresult=\count303 (c:/texlive/2025/texmf-dist/tex/latex/datatool/datatool-utf8.ldf File: datatool-utf8.ldf 2025/12/04 v3.4.3 (NLCT) ) \@dtl@datatype=\count304 \c_datatool_unknown_int=\count305 \l__datatool_year_int=\count306 \l__datatool_month_int=\count307 \l__datatool_day_int=\count308 \l__datatool_hour_int=\count309 \l__datatool_minute_int=\count310 \l__datatool_second_int=\count311 \l__datatool_tzhour_int=\count312 \l__datatool_tzminute_int=\count313 \l__datatool_julian_int=\count314 \l__datatool_local_julian_int=\count315 \l__datatool_prefix_int=\count316 \l__datatool_suffix_int=\count317 \@dtl@foreach@level=\count318 \dtl@codeA=\count319 \dtl@codeB=\count320 ) \l__datatool_max_cols_int=\count321 \l__datatool_col_idx_int=\count322 \l__datatool_row_idx_int=\count323 \l__datatool_item_type_int=\count324 \l__datatool_action_column_int=\count325 \l__datatool_action_column_ii_int=\count326 \l__datatool_action_row_int=\count327 \l__datatool_action_row_ii_int=\count328 \l__datatool_action_type_int=\count329 \l__datatool_action_datum_round_int=\count330 \dtlcolumnnum=\count331 \dtlrownum=\count332 \@dtl@before=\toks23 \@dtl@after=\toks24 \@dtl@colhead=\toks25 \dtlcurrentrow=\toks26 \dtlbeforerow=\toks27 \dtlafterrow=\toks28 \l__datatool_map_data_max_cols_int=\count333 \l__datatool_map_data_edit_column_int=\count334 \dtlforeachlevel=\count335 \c@DTLrow=\count336 \c@DTLrowi=\count337 \c@DTLrowii=\count338 \c@DTLrowiii=\count339 \dtl@rowi=\count340 \dtl@rowii=\count341 \dtl@rowiii=\count342 \g__filtered_row_i_int=\count343 \g__filtered_row_ii_int=\count344 \g__filtered_row_iii_int=\count345 \@dtl@curi=\toks29 \@dtl@previ=\toks30 \@dtl@nexti=\toks31 \@dtl@curii=\toks32 \@dtl@previi=\toks33 \@dtl@nextii=\toks34 \@dtl@curiii=\toks35 \@dtl@previii=\toks36 \@dtl@nextiii=\toks37 \l_datatool_display_per_row_int=\count346 \l_datatool_display_tab_rows_int=\count347 \@dtl@toksA=\toks38 \@dtl@toksB=\toks39 \@dtl@elements=\count348 \__datatool_sort_data_sortcol_int=\count349 \__datatool_sort_data_grpcol_int=\count350 \dtl@omitlines=\count351 \l__datatool_line_int=\count352 ) (c:/texlive/2025/texmf-dist/tex/latex/booktabs/booktabs.sty Package: booktabs 2020/01/12 v1.61803398 Publication quality tables \heavyrulewidth=\dimen160 \lightrulewidth=\dimen161 \cmidrulewidth=\dimen162 \belowrulesep=\dimen163 \belowbottomsep=\dimen164 \aboverulesep=\dimen165 \abovetopsep=\dimen166 \cmidrulesep=\dimen167 \cmidrulekern=\dimen168 \defaultaddspace=\dimen169 \@cmidla=\count353 \@cmidlb=\count354 \@aboverulesep=\dimen170 \@belowrulesep=\dimen171 \@thisruleclass=\count355 \@lastruleclass=\count356 \@thisrulewidth=\dimen172 ) (c:/texlive/2025/texmf-dist/tex/latex/l3backend/l3backend-pdftex.def File: l3backend-pdftex.def 2025-10-09 L3 backend support: PDF output (pdfTeX) \l__color_backend_stack_int=\count357 ) (./test_read.aux) \openout1 = `test_read.aux'. LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for TS1/cmr/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. \dtldb@grades=\toks40 \dtlkeys@grades=\toks41 \dtlrows@grades=\count358 \dtlcols@grades=\count359 ! Package datatool Error: Database `gradesDB' doesn't exist. See the datatool package documentation for explanation.
- xypic loop errorby underwhelmer on February 7, 2026 at 6:51 pm
Here are two different bits of code that difer by exactly one letter: Number 1: \documentclass{amsart} \usepackage[all]{xy} \begin{document} \begin{displaymath} \xymatrix{ { \begin{tabular}{c|c} \hline $x_2$ & 7 \\ \hline $x_3$ & 4 \\ \hline \end{tabular} } \ar@(ul,dl)[]_{\pi^0} } \end{displaymath} \end{document} Number 2: \documentclass{amsart} \usepackage[all]{xy} \begin{document} \begin{displaymath} \xymatrix{ { \begin{tabular}{c|c} \hline $x_2$ & 7 \\ \hline $x_3$ & 4 \\ \hline \end{tabular} } \ar@(l,dl)[]_{\pi^0} } \end{displaymath} \end{document} The difference is that in number 2, the arrow is modified with @(l,dl) while in number 1 it is modified with @(ul,dl) Number 1 doesn't compile. Number 2 does but looks ugly. I'd like Number 1 to compile and look better than Number 2 in the way it should. Since I know it will come up: no, I'm not willing to switch to tikz. Yes, I know tikz is better. But I know the syntax for xypic and have been using it for sneaking up on twenty years and I just turned 40 and am thus officially allowed to be a stick in the mud about things.
- MakeLowercase not working with lipsumby Jonathan Webley on February 7, 2026 at 9:34 am
This MWE: \documentclass{article} \usepackage{lipsum} \begin{document} \MakeLowercase{\lipsum[1][1]} \end{document} generates: Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
- Where is the l3benchmark.sty file located?by Alain Matthes on February 7, 2026 at 8:24 am
I wanted to test an old file, but I got an error. ! LaTeX Error: File `l3benchmark.sty' not found. My distribution is up to date, so I assume this file has been removed. What can I replace it with? \RequirePackage{l3benchmark} \ExplSyntaxOn \AtEndDocument { \benchmark_toc: } \benchmark_tic: \ExplSyntaxOff \documentclass{article} \usepackage{tikz} \begin{document} \directlua{ function f(t0, t1, n) local filename = tex.jobname .. ".table" local out = assert(io.open(filename, "w")) for t = t0, t1, (t1 - t0) / n do local x = math.sin(5*t) local y = math.cos(3*t) out:write(x, " ", y, " i", string.char(10)) % or out:write(x, " ", y, " i\string\n") end out:close() end } \begin{tikzpicture}[scale=4] \directlua{f(0, 2*math.pi, 256)}% \draw[red] plot[smooth] file {\jobname.table}; \end{tikzpicture} \end{document}