Hot
- Controlling what appears in front in a 3d pgfplotby James on July 12, 2026 at 6:00 pm
I'm trying to make a nice diagram to illustrate partial derivatives for my multivariable class. I have the graph of a function, a plane, the intersection of these in the graph, a tangent line, and some guide lines to show what's occurring, but (presumably because of the order in which they appear in the code) the diagram doesn't respect what object is behind a different object, i.e., the graph is drawn on top of the plane, or the plane is drawn on top of the graph, even though they ``should'' pass through one another. Is there any nice way to make whatever ``should'' be on top be drawn on top without manually finding intersections and having different domains/clip regions for different features? My code so far is below, along with the image that is produced \begin{standalone} \usepackage{tikz} \usepackage{pgfplots} \begin{document} \begin{tikzpicture} \begin{axis}[axis lines = center, xmin = 0, xmax = 3, ymin = 0, ymax = 3, view = {100}{30}, xlabel = {$x$}, ylabel = {$y$}, zlabel = {$z$}, xtick=\empty, ytick=\empty, ztick=\empty, ] % Using f(x,y) = 2 - (x-2)^3 - (y-1.5)^2 %graph \addplot3[ domain =1:3, y domain = 0.5:2.5,surf,colormap/viridis, opacity=0.9] {-(x-2)^3 - (y-1.5)^2 + 2}; %plane \draw[fill = blue!90, color = blue, opacity = 0.3] (2,0,0)--(2,3,0)-- (2,3,3) node[black, above, opacity = 0.9] {$x=a$}--(2,0,3)--cycle ; %intersection of line and plane \addplot3[domain = 0.5:2.5, blue, samples y = 1, thick] ({2},{x},{2 - (2-2)^3 - (x-1.5)^2}); %tangent line \addplot3[black, thick, domain = -1:1.23] ({2},{x+1},{-2*(1-1.5)*x + 2 - (1-1.5)^2}); %point of tangancy \draw[fill = black] (2,1, {2 - (1-1.5)^2}) circle (2pt); %guide lines for point \draw[dashed, thick] (2,0,0)--(2,1,0) node[below] {$(a,b,0)$}--(0,1,0); \draw[dashed, thick,] (2,1,0) -- (2,1,{2 - (1-1.5)^2}); \end{axis} \end{tikzpicture} \end{document}
- TeXLive Backend Gone Problemby berkus on July 12, 2026 at 4:39 pm
Ok. Here me out. I had this problem in the earlier versions of TeXLive, but was never able to fully understand where it is coming from, and what exactly is the solution. The only workaround was to perform a clearn install of TeXLive. I am on Windows 11 64bit, TeXLive 2026. I tend to update my TeXLive occasionally to catch up with the possible updates on the packages that I am interested. Just couple of days ago, I checked the updates again using tlshell.exe (TLShell TeX Live Manager), and the update list that is shown in the following picture came up. A typical update of packages in TeXLive is not like this. Note that all the updateble packages have the version number of 79618. Also note that there is an update of "tlmgr" My first question is: What kind of update is this? Is this some sort of a major update of the TeXLive system for the purpose of some sort of a clean-up, instead of individual package updates? I have updated "tlmgr" first, and updated all the packages. But then, I have this problem of "Back end gone. Last command: info --data name,remoterev,rcat-version, category,shortdesc" Then the tlshell.exe quits on me... I have tried many many things to get rid of this error, but did not work, so just out of curiosity, I uninstalled TeXLive and did a clean installation. To my surprise, the error still occurs. So, this is telling me that the TeXLive update that was recently rolled-out has an issue. Am I right? I had this issue last year and could not solve it back then. So I am really wondering what exactly this problem is about. If anybody can direct me to a page with an explanation and a possible solution, that would be also fine. Also, what is the suggested action here when we see this sort of update list? Should we just wait for TUG to fix the problem for a couple of days, without performing an update? Or is this related to my own TeXLive setup?
- Rocky mountain journal font [duplicate]by Chinnapparaj Rayappan on July 12, 2026 at 3:02 pm
I recently read one Rocky Mountain article and I felt that the font is good. I attached the sample image. I am using overleaf for my project.I would like to use this font in my work. How can I do this? Any help?
- How do TeXstudio .cwl files encode the syntax implications in \def and \newcommand?by Baylee V on July 12, 2026 at 1:16 pm
In short, my aim in this question is to understand how the TeXstudio syntax highlighter recognises commands spawned from other commands. For some background, I've been trying to fix the syntax colouring problems TeXstudio has with etoolbox; in particular, I want something like \A to be recognised as a valid command when preceded by a command like \csdef{\A}{\mathbb{A}}. The editor already recognises this if \csdef is replaced by \def or \newcommand, so I was hoping that an explanation for the syntax colouring of those commands could inform a solution for \csdef. According to this FAQ, the syntax checking for TeXstudio is processed through .cwl files, whose structure is documented here. They have also linked to the source code for the in-built .cwl files, and it seems to include all .cwl files relevant to this question. My understanding is that every valid command must appear as a line in one of these .cwl files, with modifiers that indicate exactly when these commands are valid. (There's also quite a bit of extra info for the completer, but this isn't really relevant to my question.) Referring to latex-document.cwl and tex.cwl, it looks like \def and \newcommand only appear in one line each (excluding shenanigans with optional arguments), and nothing in that line indicates that they should spawn other valid commands. In fact, I can't spot any meaningful difference between how they are specified and how \csdef is specified in etoolbox.cwl. Clearly I must have missed something! So, my question is as follows: How is the TeXstudio editor able to understand that commands spawned by \def and \newcommand shouldn't be highlighted, but unable to understand it for \csdef?
- Manage tcolorbox positioning and breakby Brasil on July 12, 2026 at 1:01 pm
I'm using tcolorbox to create a lecture material with examples but can't manage breaks and positioning. Can anyone help me, please? I provide a MEW below. \documentclass[12pt, openright, twoside, a4paper, chapter=TITLE]{memoir} \usepackage[a4paper, top=30mm, bottom=20mm, left=20mm, right=20mm]{geometry} %--> Language package \usepackage[english]{babel} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{lipsum} %--> For multicolumns: \usepackage{multicol} \setlength{\columnsep}{5mm} \usepackage{paracol} %... allows empty column %--> Packages for images and floats: \usepackage{graphicx, float} \newcounter{example}[chapter] \renewcommand{\theexample}{\thechapter.\arabic{example}} \usepackage[breakable, skins]{tcolorbox} \newtcolorbox[use counter=example]{example}[1][]{% %--> TITLE SETTINGS %... boxed head enhanced jigsaw, %... box style boxed title style={size=small,colback=white}, %... title text title={\bfseries Example~\thetcbcounter}, %... title color coltitle=black, %... head position attach boxed title to top left={ xshift=2mm, yshift=-\tcboxedtitleheight/2 }, %--> BOX SETTINGS %... frame line widths boxrule=1pt, rightrule=0pt, leftrule=0pt, %... background color colback=gray!10, %... shaddow drop shadow={gray!50!white}, %... automatic breaking enforce breakable, pad at break=3mm, %--> TEXT SETTINGS %... margin widths boxsep=0mm, top=5mm, %... text font size fontupper=\small, %... keep paragraphs similar to the text parbox=false, #1 % use the option [break at=85mm/0mm] if necessary } \begin{document} \begin{multicols}{2} \begin{example}[label=X: free fall, break at=350mm/0mm] \lipsum[1] \begin{figure}[H] \centering \includegraphics[width=4cm]{example-image-a} \end{figure} \lipsum[2] \end{example} \lipsum[3] \begin{example} \lipsum[4] \begin{figure}[H] \centering \includegraphics[width=4cm]{example-image-b} \end{figure} \lipsum[5] \begin{figure}[H] \centering \includegraphics[width=4cm]{example-image-c} \end{figure} \lipsum[6-7] \end{example} \section*{Non numbered section} \lipsum[1] \begin{example}[label=X: mass-spring] \lipsum[2] \begin{figure}[H] \centering \includegraphics[width=4cm]{example-image-a} \end{figure} \lipsum[3] \end{example} \lipsum[4] \end{multicols} \end{document}
- How to plot a graph?by charuanl on July 12, 2026 at 11:18 am
I want to plot a graph for this below picture I already tried but the graph wasn't smooth. This is the graph that I tried to plot Here's my code : \documentclass{article} \usepackage{tikz} \begin{document} \begin{center} \begin{tikzpicture}[x=1.2cm, y=0.7cm] \draw[thick, ->, >=stealth] (-2, 0) -- (6, 0) node[right] {X}; \draw[thick, ->, >=stealth] (0, -3.5) -- (0, 6.5) node[above] {Y}; \draw[thick, <->, >=stealth, color=black!80!blue] plot[smooth, tension=0.7] coordinates {(-1.5, 1.5) (0, 5) (2, 0) (4, -2) (4.8, 3)}; \fill (0, 5) circle (2.5pt); \node[above right] at (0, 5) {$(0, 5)$}; \fill (2, 0) circle (2.5pt); \node[above right] at (2, 0) {$(2, 0)$}; \fill (4, -2) circle (2.5pt); \node[below, yshift=-2pt] at (4, -2) {$(4, -2)$}; \node[above left] at (5.2, 3) {$y = f(x)$}; \end{tikzpicture} \end{center} \end{document}
- How to make the index after \printindex be printed?by M. Logic on July 12, 2026 at 2:51 am
An MWE is as follows. \documentclass{book} \usepackage{lipsum} \usepackage{imakeidx} \makeindex \begin{document} \index{a term before printing index} \lipsum[1] \printindex \index{a term after printing index} \end{document} As you see, I add an index after \printindex while it's not printed. So is there anyway to make it be printed when I still add it after \printindex?
- latexml: What is correct way to install latexml on new Linux which already has TeXLive on it?by Nasser on July 11, 2026 at 10:31 pm
New Linux mint 22.3 with texlive install using texlive own installer (i.e. not using apt), which is installed in /usr/local/texlive/2026/bin/x86_64-linux/ And it is now on the PATH also. Now I need to install latexml to evaluate and try. The problem is that if I use the following command (which is what the official latexml web site say to use) sudo apt-get install latexml This will cause it to install Linux mint own version of texlive which I do not want. I asked google AI and it said to use the following commands instead of using apt sudo apt install perl libxml2-dev libxslt1-dev imagemagick libimage-magick-perl build-essential cpanminus then sudo cpanm LaTeXML The question is: Are these the correct commands to use or what else to use? I want to make sure to install latexml correctly on this new Linux as I do not want to spend time cleaning things again. Texlive 2026
- Inconsistent character height with page zoom (moderncv, banking)by A.B. on July 11, 2026 at 8:10 pm
I am building a CV with moderncv in Overleaf. There is some strange variation of the character height that appears in any PDF viewer. The first photo is viewed at 90%, and the second at 100%. Notice that the E's in EXEPERIENCE are at a lower height. I thought this might be due to the roman font, but a similar effect occurs with sans fonts, but less dramatic. Is there an explanation for this? Please see the MWE code in Overleaf. %% start of file `template.tex'. %% Copyright 2006-2015 Xavier Danaux (xdanaux@gmail.com), 2020-2022 moderncv maintainers (github.com/moderncv). % % This work may be distributed and/or modified under the % conditions of the LaTeX Project Public License version 1.3c, % available at http://www.latex-project.org/lppl/. \documentclass[11pt,a4paper,roman]{moderncv} % possible options include font size ('10pt', '11pt' and '12pt'), paper size ('a4paper', 'letterpaper', 'a5paper', 'legalpaper', 'executivepaper' and 'landscape') and font family ('sans' and 'roman') \moderncvcolor{black} % color options 'black', 'blue' (default), 'burgundy', 'green', 'grey', 'orange', 'purple' and 'red' % moderncv themes \moderncvstyle{banking} % style options are 'casual' (default), 'classic', 'banking', 'oldstyle' and 'fancy' %\renewcommand{\familydefault}{\sfdefault} % to set the default font; use '\sfdefault' for the default sans serif font, '\rmdefault' for the default roman one, or any tex font name %\nopagenumbers{} % uncomment to suppress automatic page numbering for CVs longer than one page % adjust the page margins \usepackage[scale=0.75]{geometry} \setlength{\footskip}{136.00005pt} % depending on the amount of information in the footer, you need to change this value. comment this line out and set it to the size given in the warning %\setlength{\hintscolumnwidth}{3cm} % if you want to change the width of the column with the dates %\setlength{\makecvheadnamewidth}{10cm} % for the 'classic' style, if you want to force the width allocated to your name and avoid line breaks. be careful though, the length is normally calculated to avoid any overlap with your personal info; use this at your own typographical risks... % font loading % for luatex and xetex, do not use inputenc and fontenc % see https://tex.stackexchange.com/a/496643 \ifxetexorluatex \usepackage{fontspec} \usepackage{unicode-math} \defaultfontfeatures{Ligatures=TeX} \setmainfont{Latin Modern Roman} \setsansfont{Latin Modern Sans} \setmonofont{Latin Modern Mono} \setmathfont{Latin Modern Math} \else \usepackage[T1]{fontenc} \usepackage{lmodern} \fi % document language \usepackage[english]{babel} % FIXME: using spanish breaks moderncv % personal data \name{John}{Doe} \title{Résumé title} % optional, remove / comment the line if not wanted \born{4 July 1776} % optional, remove / comment the line if not wanted \address{street and number}{postcode city}{country}% optional, remove / comment the line if not wanted; the "postcode city" and "country" arguments can be omitted or provided empty \phone[mobile]{+1~(234)~567~890} % optional, remove / comment the line if not wanted; the optional "type" of the phone can be "mobile" (default), "fixed" or "fax" \phone[fixed]{+2~(345)~678~901} \phone[fax]{+3~(456)~789~012} \email{john@doe.org} % optional, remove / comment the line if not wanted \homepage{www.johndoe.com} % optional, remove / comment the line if not wanted % Social icons \social[linkedin]{john.doe} % optional, remove / comment the line if not wanted \social[xing]{john\_doe} % optional, remove / comment the line if not wanted \social[twitter]{ji\_doe} % optional, remove / comment the line if not wanted \social[github]{jdoe} % optional, remove / comment the line if not wanted \social[gitlab]{jdoe} % optional, remove / comment the line if not wanted % \social[stackoverflow]{0000000/johndoe} % optional, remove / comment the line if not wanted % \social[bitbucket]{jdoe} % optional, remove / comment the line if not wanted % \social[skype]{jdoe} % optional, remove / comment the line if not wanted % \social[orcid]{0000-0000-000-000} % optional, remove / comment the line if not wanted % \social[researchgate]{jdoe} % optional, remove / comment the line if not wanted % \social[researcherid]{jdoe} % optional, remove / comment the line if not wanted % \social[telegram]{jdoe} % optional, remove / comment the line if not wanted % \social[whatsapp]{12345678901} % optional, remove / comment the line if not wanted % \social[signal]{12345678901} % optional, remove / comment the line if not wanted % \social[matrix]{@johndoe:matrix.org} % optional, remove / comment the line if not wanted % \social[googlescholar]{googlescholarid} % optional, remove / comment the line if not wanted \extrainfo{additional information} % optional, remove / comment the line if not wanted \photo[64pt][0.4pt]{picture} % optional, remove / comment the line if not wanted; '64pt' is the height the picture must be resized to, 0.4pt is the thickness of the frame around it (put it to 0pt for no frame) and 'picture' is the name of the picture file \quote{Some quote} % optional, remove / comment the line if not wanted % bibliography adjustments (only useful if you make citations in your resume, or print a list of publications using BibTeX) % to show numerical labels in the bibliography (default is to show no labels) %\makeatletter\renewcommand*{\bibliographyitemlabel}{\@biblabel{\arabic{enumiv}}}\makeatother \renewcommand*{\bibliographyitemlabel}{[\arabic{enumiv}]} % to redefine the bibliography heading string ("Publications") %\renewcommand{\refname}{Articles} % bibliography with mutiple entries %\usepackage{multibib} %\newcites{book,misc}{{Books},{Others}} %---------------------------------------------------------------------------------- % content %---------------------------------------------------------------------------------- \begin{document} %\begin{CJK*}{UTF8}{gbsn} % to typeset your resume in Chinese using CJK %----- resume --------------------------------------------------------- \makecvtitle \section{EDUCATION} \cventry{year--year}{Degree}{Institution}{City}{\textit{Grade}}{Description} % arguments 3 to 6 can be left empty \cventry{year--year}{Degree}{Institution}{City}{\textit{Grade}}{Description} \section{Master thesis} \cvitem{title}{\emph{Title}} \cvitem{supervisors}{Supervisors} \cvitem{description}{Short thesis abstract} \section{EXPERIENCE} \subsection{Vocational} \cventry{year--year}{Job title}{Employer}{City}{}{General description no longer than 1--2 lines.\newline{} Detailed achievements: \begin{itemize} \item Achievement 1 \item Achievement 2 (with sub-achievements) \begin{itemize} \item Sub-achievement (a); \item Sub-achievement (b), with sub-sub-achievements (don't do this!); \begin{itemize} \item Sub-sub-achievement i; \item Sub-sub-achievement ii; \item Sub-sub-achievement iii; \end{itemize} \item Sub-achievement (c); \end{itemize} \item Achievement 3 \item Achievement 4 \end{itemize}} \cventry{year--year}{Job title}{Employer}{City}{}{Description line 1\newline{}Description line 2\newline{}Description line 3} \subsection{Miscellaneous} \cventry{year--year}{Job title}{Employer}{City}{}{Description} \section{Languages} \cvitemwithcomment{Language 1}{Skill level}{Comment} \cvitemwithcomment{Language 2}{Skill level}{Comment} \cvitemwithcomment{Language 3}{Skill level}{Comment} \cvitemwithcomment{Language 4}{Skill level}{Comment} \section{Computer skills} \cvdoubleitem{category 1}{XXX, YYY, ZZZ}{category 4}{XXX, YYY, ZZZ} \cvdoubleitem{category 2}{XXX, YYY, ZZZ}{category 5}{XXX, YYY, ZZZ} \cvdoubleitem{category 3}{XXX, YYY, ZZZ}{category 6}{XXX, YYY, ZZZ} \section{Skill matrix} \cvitem{Skill matrix}{Alternatively, provide a skill matrix to show off your skills} %% Skill matrix as an alternative to rate one's skills, computer or other. %% Adjusts width of skill matrix columns. %% Usage \setcvskillcolumns[<width>][<factor>][<exp_width>] %% <width>, <exp_width> should be lengths smaller than \textwidth, <factor> needs to be between 0 and 1. %% Examples: % \setcvskillcolumns[5em][][]% adjust first column. Same as \setcvskillcolumns[5em] % \setcvskillcolumns[][0.45][]% adjust third (skill) column. Same as \setcvskillcolumns[][0.45] % \setcvskillcolumns[][][\widthof{``Year''}]% adjust fourth (years) column. % \setcvskillcolumns[][0.45][\widthof{``Year''}]% % \setcvskillcolumns[\widthof{``Languag''}][0.48][] % \setcvskillcolumns[\widthof{``Languag''}]% %% Adjusts width of legend columns. Usage \setcvskilllegendcolumns[<width>][<factor>] %% <factor> needs to be between 0 and 1. <width> should be a length smaller than \textwidth %% Examples: % \setcvskilllegendcolumns[][0.45] % \setcvskilllegendcolumns[\widthof{``Legend''}][0.45] % \setcvskilllegendcolumns[0ex][0.46]% this is usefull for the banking style %% Add a legend if you are using \cvskill{<1-5>} command or \cvskillentry %% Usage \cvskilllegend[*][<post_padding>][<first_level>][<second_level>][<third_level>][<fourth_level>][<fifth_level>]{<name>} % \cvskilllegend % insert default legend without lines \cvskilllegend*[1em]{}% adjust post spacing % \cvskilllegend*{Legend}% Alternatively add a description string %% adjust the legend entries for other languages, here German % \cvskilllegend[0.2em][Grundkenntnisse][Grundkenntnisse und eigene Erfahrung in Projekten][Umfangreiche Erfahrung in Projekten][Vertiefte Expertenkenntnisse][Experte\,/\,Spezialist]{Legende} %% Alternative legend style with the first three skill levels in one column %% Usage \cvskillplainlegend[*][<post_padding>][<first_level>][<second_level>][<third_level>][<fourth_level>][<fifth_level>]{<name>} % \setcvskilllegendcolumns[][0.6]% works for classic, casual, banking % \setcvskilllegendcolumns[][0.55]% works better for oldstyle and fancy % \cvskillplainlegend{} % \cvskillplainlegend[0.2em][Grundkenntnisse][Grundkenntnisse und eigene Erfahrung in Projekten][Umfangreiche Erfahrung in Projekten][Vertiefte Expertenkenntnisse][Experte/Guru]{Legende} %% Add a head of the skill matrix table with descriptions. %% Usage \cvskillhead[<post_padding>][<Level>][<Skill>][<Years>][<Comment>]% \cvskillhead[-0.1em]% this inserts the standard legend in english and adjust padding %% Adjust head of the skill matrix for other languages % \cvskillhead[0.25em][Level][F\"ahigkeit][Jahre][Bemerkung] %% \cvskillentry[*][<post_padding>]{<skill_cathegory>}{<0-5>}{<skill_name>}{<years_of_experience>}{<comment>}% %% Example usages: \cvskillentry*{Language:}{3}{Python}{2}{I'm so experienced in Python and have realised a million projects. At least.} \cvskillentry{}{2}{Lilypond}{14}{So much sheet music! Man, I'm the best!} \cvskillentry{}{3}{\LaTeX}{14}{Clearly I rock at \LaTeX} \cvskillentry*{OS:}{3}{Linux}{2}{I only use Archlinux btw}% notice the use of the starred command and the optional \cvskillentry*[1em]{Methods}{4}{SCRUM}{8}{SCRUM master for 5 years} %% \cvskill{<0-5>} command % \cvitem{\textbackslash{cvskill}:}{Skills can be visually expressed by the \textbackslash{cvskill} command, e.g. \cvskill{2}} \section{Interests} \cvitem{hobby 1}{Description} \cvitem{hobby 2}{Description} \cvitem{hobby 3}{Description} \section{Extra 1} \cvlistitem{Item 1} \cvlistitem{Item 2} \cvlistitem{Item 3. This item is particularly long and therefore normally spans over several lines. Did you notice the indentation when the line wraps?} \section{Extra 2} \cvlistdoubleitem{Item 1}{Item 4} \cvlistdoubleitem{Item 2}{Item 5\cite{book2}} \cvlistdoubleitem{Item 3}{Item 6. Like item 3 in the single column list before, this item is particularly long to wrap over several lines.} \section{References} \begin{cvcolumns} \cvcolumn{Category 1}{\begin{itemize}\item Person 1\item Person 2\item Person 3\end{itemize}} \cvcolumn{Category 2}{Amongst others:\begin{itemize}\item Person 1, and\item Person 2\end{itemize}(more upon request)} \cvcolumn[0.5]{All the rest \& some more}{\textit{That} person, and \textbf{those} also (all available upon request).} \end{cvcolumns} % Publications from a BibTeX file without multibib % for numerical labels: \renewcommand{\bibliographyitemlabel}{\@biblabel{\arabic{enumiv}}}% CONSIDER MERGING WITH PREAMBLE PART % to redefine the heading string ("Publications"): \renewcommand{\refname}{Articles} \nocite{*} \bibliographystyle{plain} \bibliography{publications} % 'publications' is the name of a BibTeX file % Publications from a BibTeX file using the multibib package %\section{Publications} %\nocitebook{book1,book2} %\bibliographystylebook{plain} %\bibliographybook{publications} % 'publications' is the name of a BibTeX file %\nocitemisc{misc1,misc2,misc3} %\bibliographystylemisc{plain} %\bibliographymisc{publications} % 'publications' is the name of a BibTeX file \clearpage %----- letter --------------------------------------------------------- % recipient data \recipient{Company Recruitment team}{Company, Inc.\\123 somestreet\\some city} \date{January 01, 1984} \opening{Dear Sir or Madam,} \closing{Yours faithfully,} \enclosure[Attached]{curriculum vit\ae{}} % use an optional argument to use a string other than "Enclosure", or redefine \enclname \makelettertitle Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis ullamcorper neque sit amet lectus facilisis sed luctus nisl iaculis. Vivamus at neque arcu, sed tempor quam. Curabitur pharetra tincidunt tincidunt. Morbi volutpat feugiat mauris, quis tempor neque vehicula volutpat. Duis tristique justo vel massa fermentum accumsan. Mauris ante elit, feugiat vestibulum tempor eget, eleifend ac ipsum. Donec scelerisque lobortis ipsum eu vestibulum. Pellentesque vel massa at felis accumsan rhoncus. Suspendisse commodo, massa eu congue tincidunt, elit mauris pellentesque orci, cursus tempor odio nisl euismod augue. Aliquam adipiscing nibh ut odio sodales et pulvinar tortor laoreet. Mauris a accumsan ligula. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Suspendisse vulputate sem vehicula ipsum varius nec tempus dui dapibus. Phasellus et est urna, ut auctor erat. Sed tincidunt odio id odio aliquam mattis. Donec sapien nulla, feugiat eget adipiscing sit amet, lacinia ut dolor. Phasellus tincidunt, leo a fringilla consectetur, felis diam aliquam urna, vitae aliquet lectus orci nec velit. Vivamus dapibus varius blandit. Duis sit amet magna ante, at sodales diam. Aenean consectetur porta risus et sagittis. Ut interdum, enim varius pellentesque tincidunt, magna libero sodales tortor, ut fermentum nunc metus a ante. Vivamus odio leo, tincidunt eu luctus ut, sollicitudin sit amet metus. Nunc sed orci lectus. Ut sodales magna sed velit volutpat sit amet pulvinar diam venenatis. Albert Einstein discovered that $e=mc^2$ in 1905. \[ e=\lim_{n \to \infty} \left(1+\frac{1}{n}\right)^n \] \makeletterclosing %\clearpage\end{CJK*} % if you are typesetting your resume in Chinese using CJK; the \clearpage is required for fancyhdr to work correctly with CJK, though it kills the page numbering by making \lastpage undefined \end{document} %% end of file `template.tex'.
- problem z TLShell Tex Live Manager [closed]by Wojciech Kleczko on July 11, 2026 at 4:35 pm
komunikat: Back end gone. Last command: info – data name, remoterev,rcat-version,category,shortdesc i po OK się zamyka wersja Texlive 2026
- How to ignore space in expl3 string comparisonby Denis Bitouzé on July 11, 2026 at 3:14 pm
(This is a follow-up of How to ignore space in sorting order of biblatex + biber?.) At least in French, spaces should be ignored in sorting order of strings. But, as shown by the following MCE, that's not by default the case with expl3 string comparison: just as “AB”, “A B” should be considered after (here >) “AA” in the lexicographic order. How to fix this problem? \documentclass{article} \begin{document} \ExplSyntaxOn \begin{itemize} \item \str_compare:nNnTF {AB} > {AA} {true} {false} % returns true \item \str_compare:nNnTF {A~B} > {AA} {true} {false} % returns false \end{itemize} \ExplSyntaxOff \end{document}
- Symmetrical blank space using bold hat of \brcurs of Griffiths David's bookby Sebastiano on July 11, 2026 at 12:46 pm
I have tried several approaches, including adding \mkern inside the \slhat command, but I still haven't been able to fix the spacing around \slhat{\brcurs} (the slanted-hat version of Griffiths' italic accented (r)). I would like the spacing to be correct both before and after the symbol, so that it behaves like a standard mathematical accent. \documentclass{article} \usepackage{newtxtext} \usepackage{newtxmath} \usepackage{bm} \usepackage{mathtools} \newcommand{\genericrcurs}[1]{% \text{% \resizebox{!}{0.9\fontcharht\font`x}{% \includegraphics[trim=20 0 140 40]{#1}% }% }% } \NewDocumentCommand{\rcurs}{}{\mathord{\genericrcurs{ScriptR}}} \NewDocumentCommand{\brcurs}{}{\mathord{\genericrcurs{BoldR}}} \NewDocumentCommand{\hrcurs}{}{\,\mathit{\hat{\!\brcurs}}} \usepackage{l3draw} \ExplSyntaxOn \NewDocumentCommand{\xslantobject}{mm} { \draw_begin: \draw_transform_xslant:n { #2 } \hbox_set:Nn \l_tmpa_box { #1 } \draw_box_use:N \l_tmpa_box \draw_end: } \NewDocumentCommand{\slhat}{m} { \mathord{ \mkern-5mu \vbox{ \offinterlineskip \halign{\hfil##\hfil\cr \xslantobject{$\hat{\phantom{x}}$}{0.3}\cr \noalign{\kern-.95ex} $#1$\cr } } \mkern0mu } } \ExplSyntaxOff \begin{document} \[ {S}_{a}^{\mathbf{(CGS)}}=\frac{q^2 a^2 \sin^2\theta}{4 \pi c^{3}\rcurs^2}\boldsymbol{[}\slhat{\brcurs}\boldsymbol{]} \] \begin{equation}\label{rayd49} \begin{aligned} & |\slhat{\brcurs}\times\{(\slhat{\brcurs}-\beta \hat{z})\times\hat{\mathbf{x}}\}|^2\\ & = |\slhat{\brcurs}-\beta\hat{\mathbf{z}}|^2 (\slhat{\brcurs}\cdot\hat{\mathbf{x}})^2+(1-\beta \hat{\mathbf{z}}\cdot\slhat{\brcurs})^2 -2 (\slhat{\brcurs}\cdot\hat{\mathbf{x}})(1-\beta\hat{\mathbf{z}}\cdot\slhat{\brcurs})\{ \hat{\mathbf{x}}\cdot (\slhat{\brcurs}-\beta\hat{\mathbf{z}})\}= \\ & = |\slhat{\brcurs}-\beta \hat{\mathbf{z}}|^2(\slhat{\brcurs}\cdot\hat{\mathbf{x}})^2+(1-\beta \hat{\mathbf{z}}\cdot\slhat{\brcurs})^2 -2 (\slhat{\brcurs}\cdot\hat{\mathbf{x}}) (1-\beta\hat{\mathbf{z}}\cdot\slhat{\brcurs}) (\hat{\mathbf{x}}\cdot\slhat{\brcurs}) \end{aligned} \end{equation} \end{document}
- How to ignore space in sorting order of biblatex + biber?by Denis Bitouzé on July 11, 2026 at 9:00 am
At least in French, spaces should be ignored in sorting order of strings. But, as shown by the following MCE, that's not by default the case with biblatex + biber: just as “AB”, “A B” should appear after “AA”. How to fix this problem? \begin{filecontents}[overwrite]{\jobname.bib} @article{ab, author = {A B, Jane}, } @article{aa, author = {AA, Jane}, } \end{filecontents} \documentclass[french]{article} \usepackage{biblatex} \usepackage{babel} \addbibresource{\jobname.bib} \nocite{*} \begin{document} \printbibliography \end{document} The original, realistic, case is the following one where “El Kacimi” should appear after “Eliahou” (in “El Kacimi”, “El” should not be considered as a prefix). \begin{filecontents}[overwrite]{\jobname.bib} @article{elka, author = {El Kacimi, Aziz}, } @article{elia, author = {Eliahou, Shalom}, } \end{filecontents} \documentclass[french]{article} \usepackage{biblatex} \usepackage{babel} \addbibresource{\jobname.bib} \nocite{*} \begin{document} \printbibliography \end{document}
- Nesting tikzcd (specifically) within tikzpictureby Just Some Old Man on July 10, 2026 at 7:34 pm
I would like to have a tikzcd within tikzpicture. The reason for this is I want to have a standard commutative diagram from tikzcd, but then also put lines, text, and shapes in the "background" of the diagram using tikzpicture treating the diagram as static and without interacting with the diagram at all (allowing for overlap, for example). A solution for tikzpicture within tikzpicture is using \newsavebox, but this doesn't work for tikzcd within tikzpicture. Specifically, \UseRawInputEncoding \documentclass[11pt]{article} \renewcommand{\baselinestretch}{1.05} \usepackage{tikz-cd} \begin{document} \newsavebox{\mybox} \sbox{\mybox}{ \begin{tikzpicture} \end{tikzpicture} } \end{document} compiles, but \UseRawInputEncoding \documentclass[11pt]{article} \renewcommand{\baselinestretch}{1.05} \usepackage{tikz-cd} \begin{document} \newsavebox{\mybox} \sbox{\mybox}{ \begin{tikzcd} A \arrow[r] & B \end{tikzcd} } \end{document} does not compile and throws the following error. Moreover, \UseRawInputEncoding \documentclass[11pt]{article} \renewcommand{\baselinestretch}{1.05} \usepackage{tikz-cd} \begin{document} \newsavebox{\mybox} \sbox{\mybox}{ \begin{tikzpicture} \begin{tikzcd} A \arrow[r] & B \end{tikzcd} \end{tikzpicture} } \end{document} does not compile and throws the following error. How can I have a tikzcd within tikzpicture?
- Slight shift when exchanging TikZ node and line by exchanging some of their characteristicsby Denis Bitouzé on July 10, 2026 at 3:02 pm
Thanks to https://tex.stackexchange.com/a/764554/18401, I can easily have a (TikZ) node followed by a line, the total width of them being fixed (40mm below). In the following MCE, I use code from the link above (not optimizing in order to make it clearer) and: for the first case, I use: the east anchor, draw to the right, the west anchor of the node considered for the total width, and the result is as expected; for the second case, I want to exchange the node and the line (not mirroring them), so my code exchanges: east anchor → west anchor, draw to the right → draw to the left, west anchor → east anchor of the node considered for the total width. But, for the second case, there is slight shift (about 1pt) to the right I can't explain. How to get rid of it? \documentclass{article} \usepackage{tikz} \usepackage[showframe]{fgruler} \usepackage{geometry} \geometry{ paperwidth=60mm, paperheight=50mm, margin=1cm, marginparwidth=0mm, textwidth=40mm, } \newcommand{\test}[3]{% \noindent% \tikz \draw[line width=2pt] (0,0) node[line width=0pt,inner sep=0pt,draw, anchor=#1, ] (foo) {Foo} -- ([shift=(#2:40mm)]foo.#3);% } \begin{document} \test{east}{right}{west} \test{west}{left}{east} \end{document}
- Macros from unicode-math package in section headingsby Stephen Powell on July 10, 2026 at 1:40 pm
I have a section heading that includes the macro \symup defined in the unicode-math package: \documentclass{article} \usepackage{unicode-math} \begin{document} \section{Euler's number \(\symup{e}\)} \(\symup{e} = \exp(1)\) \end{document} It compiles to PDF without problems using LuaTeX. I can also successfully compile to HTML using make4ht -a debug -ul mwe.tex "mathjax" (MiKTeX 26.5). But despite producing correct output, it reports an error: ! Undefined control sequence. \TocTitle ->Euler's number \(\symup {e}\) l.4 \section{Euler's number \(\symup{e}\)} As I understand it, htlatex doesn't load unicode-math, so it gives an error when trying to construct the section title for the table of contents. But the page appears correctly anyway because MathJax supports \symup. Is there some way to prevent these errors, but still report genuinely undefined macros? I have a long document with many such section headings and they get in the way when trying to fix actual errors.
- How to place footnote into scrletter's signature?by lAtExFaN on July 10, 2026 at 11:09 am
I use texlive 2025 and try to set a footnote into scrletter's signature. The following code seems to work, but isn't: The footnotemark/footnotetext-pair appears but the footnote's numbering is off by +1 and the implementation is ugly (due to the loose distribution of code: footnotemark and footnotetext) \documentclass{scrartcl} \usepackage{scrletter} \setkomavar{signature}{Alfred E. Neumann\footnotemark{}} %<- works, but ugly \begin{document} \begin{letter}{You} \opening{Dear You,} Hello World! \closing{Best regards,} \footnotetext{MAD} %<- uhhh, that's really ugly! 😉 \end{letter} \end{document} Thus I tried to get rid of the distribution of code, using this: \documentclass{scrartcl} \usepackage{scrletter} \setkomavar{signature}{Alfred E. Neumann\footnote{MAD}} %<- preferred solution \begin{document} \begin{letter}{You} \opening{Dear You,} Hello World! \closing{Best regards,} \end{letter} \end{document} But I can't get it to work: only the footnote mark appears, but the footnotetext doesn't. The mark is off by +1, too. Could someone please help me and demonstrate how to solve this? Thanks!
- How to force page numbers to start in a fixed column in an index?by test on July 10, 2026 at 9:28 am
This is a follow-up to my previous question posted here: Fixed spacing and hanging indentation in imakeidx index I am currently working on the index of my dissertation, and my supervisor has requested that the page numbers be aligned in a fixed column. If the entry text is long enough to extend past the page-number column, but not long enough to wrap automatically or leave enough room for the page numbers on the same line, I would like a line break to be inserted automatically so that the page numbers start at the same fixed position on the following line. Just to make sure, this is the layout I am trying to achieve: Here is my MWE: % Source - https://tex.stackexchange.com/q/764586 % Posted by test % Retrieved 2026-07-10, License - CC BY-SA 4.0 % Notes: % - delim_0 is the separator between entry and page number of level 0 % we use it to add insert a fix space of 1cm % - delim_1 is the same for level 1 % - delim_2 is the same for level 2 \begin{filecontents}[overwrite]{\jobname.ist} delim_0 "\\hspace{1cm}" delim_1 "\\hspace{1cm}" delim_2 "\\hspace{1cm}" \end{filecontents} \documentclass{scrbook} \usepackage{imakeidx} \usepackage{polyglossia} \makeindex[options={-s \jobname.ist}] \makeatletter \renewcommand*{\@idxitem}{\par\hangindent 0.4cm}% use a hanging indent of 0.4cm on all levels \makeatother \begin{document} \section{First section} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage A \newpage TEST \newpage Test \newpage B \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage C \newpage Test \newpage Test \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \newpage Test \newpage \index{0@Exodus!2, 100} \index{0@Genesis!1} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aliquam rutrum aliquet elit in pellentesque. Proin nulla eros, consequat nec\index{1@pu} convallis vel, vulputate vitae purus\index{0@purusu rusuru surus Schönheitswahnsinn}. Pellentesque consequat euismod sapien, ac porttitor diam laoreet id. Pellentesque habitant morbi tristique senectus\index{senectus} et netus et malesuada fames ac turpis egestas. Sed vehicula magna orci, nec congue sem congue ac. Sed fringilla aliquam interdum. Nullam quis commodo massa.\index{Schönheitswahnsinn abc def ghi jklmnopq} \printindex \end{document}
- Why the interline spacing is different depending on where the font size is set? [duplicate]by CarLaTeX on July 10, 2026 at 7:43 am
In the first node the font size is set as node argument. In the second node the font size is set where within the node text. Why the line spacing is different? \documentclass{book} \usepackage{tikz} \begin{document} \begin{tikzpicture} \node[draw, rectangle, minimum height=1cm, anchor=west, text width=10cm, align=flush left, font=\Large] {Some text. Some text. Some text. Some text. Some text. Some text.}; \end{tikzpicture} \vspace{1cm} \begin{tikzpicture} \node[draw, rectangle, minimum height=1cm, anchor=west, text width=10cm, align=flush left] {\Large Some text. Some text. Some text. Some text. Some text. Some text.}; \end{tikzpicture} \end{document}
- Difference between columnset and pagecolumnsby A. Licari-Guillaume on July 10, 2026 at 7:37 am
I had a few problems using pagecolumns in ConTeXt (I find quite easy workarounds, but it is not really satisfying…). By looking at the wiki, it seems that column sets is the preferred way for handling columns if I follow these hints: the manual for column sets is newer (2024 vs 2017) and contains twice more details the pagecolumns manual starts with a disclamer about the mechanism being under construction the tutorial «Typesetting in columns» is about column sets However, I don't find any clear confirmation that the pagecolumns are to be left. Before I start migrating all my documents, can someone confirm that I would be better using column sets ? And why is it so ? Thank you in advance
- Why adding breqn package allows one to use underscore in text mode with no error?by Nasser on July 10, 2026 at 5:03 am
We all know that in latex one needs to escape _ when not in math mode. So this MWE gives error as expected because there is _quadrature in the first column of this longtable. (column type is p) \documentclass[12pt]{article} \usepackage{longtable} \begin{document} \begin{longtable}{|p{3.5in}|p{.5in}|p{.6in}|p{.6in}|p{.6in}|}\hline [_quadrature]&$1588$&97.04&99.31&90.55\\ \hline \end{longtable} \end{document} Compiling using lualatex >lualatex B.tex This is LuaHBTeX, Version 1.26.3 (TeX Live 2027/dev) restricted system commands enabled. (./B.tex LaTeX2e <2025-11-01> L3 programming layer <2026-03-20> (/usr/local/texlive/2026/texmf-dist/tex/latex/base/article.cls Document Class: article 2025/01/22 v1.4n Standard LaTeX document class (/usr/local/texlive/2026/texmf-dist/tex/latex/base/size12.clo)) (/usr/local/texlive/2026/texmf-dist/tex/latex/tools/longtable.sty) (/usr/local/texlive/2026/texmf-dist/tex/latex/l3backend/l3backend-luatex.def) (./B.aux) ! Missing $ inserted. <inserted text> $ l.10 [_ quadrature]&$1588$&97.04&99.31&90.55\\ \hline ? But adding \usepackage{breqn} to the preamble, now it compiles with no error !! >lualatex B.tex This is LuaHBTeX, Version 1.26.3 (TeX Live 2027/dev) restricted system commands enabled. (./B.tex LaTeX2e <2025-11-01> L3 programming layer <2026-03-20> (/usr/local/texlive/2026/texmf-dist/tex/latex/base/article.cls Document Class: article 2025/01/22 v1.4n Standard LaTeX document class (/usr/local/texlive/2026/texmf-dist/tex/latex/base/size12.clo)) ...... (/usr/local/texlive/2026/texmf-dist/tex/context/base/mkii/supp-pdf.mkii [Loading MPS to PDF converter (version 2006.09.02).] ) (/usr/local/texlive/2026/texmf-dist/tex/latex/epstopdf-pkg/epstopdf-base.sty (/usr/local/texlive/2026/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg)) Overfull \hbox (89.16727pt too wide) in alignment at lines 9--11 [][][][][] [1 Non-PDF special ignored!{/usr/local/texlive/2026/texmf-var/fonts/map/pdftex/upd map/pdftex.map}] (./B.aux)) (see the transcript file for additional information) 574 words of node memory still in use: 6 hlist, 2 vlist, 2 rule, 2 glue, 4 kern, 1 glyph, 6 attribute, 70 glue_spec , 6 attribute_list, 1 write nodes avail lists: 1:1,2:122,3:38,4:1,5:22,6:10,7:252,8:4,9:152,11:2 </usr/local/texlive/2026/texmf-dist/fonts/opentype/public/lm/lmroman12-regular. otf></usr/local/texlive/2026/texmf-dist/fonts/type1/public/amsfonts/cm/cmr12.pf b> Output written on B.pdf (1 page, 11974 bytes). Transcript written on B.log. And gives How does this happen and why? I was going to make the first column \verb|| in order to make it compile, when I noticed that simply adding the breqn package made it compile without having to do anyting. Is this documented and known feature of breqn ? TL 2026 on WSL 1.0 Ubuntu.
- Optical illusion that depicts objects which appear to move, but don't, due to a repeating pattern within the static fill. I want to reproduce itby Jasper on July 10, 2026 at 4:14 am
I saw a cool optical illusion while surfing the web. It depicts objects which appear to move, but aren't, due to a repeating pattern within the static fill. I want to reproduce it in TikZ. This is the graphic: The source I originally viewed I did not post deliberately due to the use of a swear word in the subreddit's name. David provides an alternative source, which is likely the source of the Reddit post, though they never listed one. https://www.sciencealert.com/this-colorful-new-spin-on-a-classic-illusion-has-brains-tripping-again This is the static color wheel: \documentclass{article} \usepackage{tikz} \usetikzlibrary{shadings} \begin{document} \begin{tikzpicture} \shade[ shading=color wheel, even odd rule ] (0,0) circle[radius=1] (0,0) circle[radius=2] ; \end{tikzpicture} \end{document}
- TikZ pic is not handling pgfkeysby PaulTanenbaum on July 10, 2026 at 2:50 am
I'm trying to use a pic to produce diamonds of a fixed width and height (specified by a parameter) and of specified line and fill colors. My first attempt was based on code I copied and pasted from Google in response to the search "can tikzpicture pic macros have arguments." Google responded with what seemed to be just what I needed (under a heading of "Default Values and Keyword Arguments"). But I have not been able to get my tweak of it to work. (But having typed that last sentence, I've now tried the code verbatim as Google provided it, and I got a pgfkeys error. Sigh). In my attempts, I have gotten the default values to work: if I change the default values, then those changes are reflected in the output. But for some reason when I pass my pic key-value pairs, they seem to have no effect. Oh, and when (by way of debugging) I try commenting out the lines that set the defaults, I get error messages about the resulting "undefined control sequences." I've also looked at various answers here on SE and tried adjusting my code to resemble theirs. No such adjustments have made any difference. Nor, I'm sorry to say, has the PGF/TikZ manual been of any help. I'm confident that the problem is some fairly simple thing that I'm too bone-headed to find. So here's a MWE: \documentclass{article} \usepackage{tikz} \usetikzlibrary{shapes.geometric} \tikzset{ pics/mydiamond/.style={ code={ \node[ draw, diamond, color=\mydiamondcolor, fill=\mydiamondfill, minimum width=\mydiamondradius*2, minimum height=\mydiamondradius*2, align=center] (0,0) {}; } }, % Set defaults pics/mydiamond/.cd, color/.store in=\mydiamondcolor, color=purple, fill/.store in=\mydiamondfill, fill=yellow!30, radius/.store in=\mydiamondradius, radius=2mm, } \tikzset{blue thing/.style={color=blue,fill=blue!20}} \begin{document} These three diamonds should be of different sizes and colors, \begin{tikzpicture} \draw (0,0) pic {mydiamond}; \draw[radius=5cm, color=red, fill=green] (1,0) pic {mydiamond}; \draw (2,0) pic {mydiamond={radius=10cm, color=blue, fill=white}}; \end{tikzpicture} But they are not. Nor do such diamonds seem to pick up on .styles (\begin{tikzpicture} \draw (0,0) pic[blue thing] {mydiamond}; \end{tikzpicture}, see what I mean?), although things like garden-variety nodes and geometric shapes (\begin{tikzpicture} \draw[blue thing] (0,0) node {Blue Thing!}; \end{tikzpicture} and \begin{tikzpicture} \draw[blue thing, radius=2mm] (1.2,0) circle; \end{tikzpicture}) do. \end{document} The output I get from that MWE is As my MWE illustrates, among the variants I've tried is taking the key-value pairs out of the brackets appended to the \draw command and putting them into ={} appended to the pic name. But no dice.
- What is the best geometry configuration for a standard novel of a large size? [closed]by Cham on July 9, 2026 at 8:00 pm
I'm writing a large science-fiction novel and currently set my geometry package to a default 8.5 x 11'' standard format, and it's all fine. But I'm curious of the way it would look like once reduced to a typical novel size, as found in libraries. So what should be the configuration I should use for the geometry package, to get all the pages and margins to a typical "large size" novel? I believe it's 6 x 9" (but I need to work in cm for an eventual French publisher), and I know nothing about the margins used. I'm looking for something that looks like the Dune novel (Frank Herbert), in the Robert Laffont publisher, as an example, or maybe something like the large versions of The Lord of the Rings (Tolkien). Also, what line spacing and font size should I use for this kind of novel? 12pt is clearly too large, but I'm wondering about 10pt or 11pt, or even something in between? Here's the MWE code I'm playing with: \documentclass[11pt,twoside]{book} \usepackage[T1]{fontenc} \usepackage[tt=false]{libertinus} \usepackage[french]{babel} \usepackage[stretch=50]{microtype} \usepackage[ papersize={14.8cm,21cm}, % Format A5 inner=2cm, outer=1.5cm, top=2cm, bottom=2cm, headheight=14pt, includeheadfoot, showframe ]{geometry} %\usepackage{setspace} \raggedbottom %\onehalfspacing %\setstretch{1.25} \setlength{\parindent}{1.5em} % Indentation de première ligne des paragraphes. \linespread{1.1} %\setlength{\parskip}{0pt} % Espacement des paragraphes. \usepackage[bottom,symbol,perpage]{footmisc} \usepackage{titlesec} \usepackage{fancyhdr} \pagestyle{fancy} \fancyhf{} \fancyfoot[C]{\thepage} \fancyfoot[LO,RE]{\small\nouppercase{\textcopyright Copyright notice}} \fancyhead[CE]{\normalsize\scshape\nouppercase{Novel title}} \fancyhead[CO]{\normalsize\itshape\nouppercase{\leftmark}} \titleformat{\chapter}[display]{\normalfont\huge\bfseries\centering}{\chaptertitlename\ \thechapter}{20pt}{\Huge} \usepackage{blindtext} \begin{document} \mainmatter \pagestyle{fancy} \chapter{Chapter title} \Blindtext \end{document}
- Simulating a granular concrete surface texture in TikZby Sebastiano on July 9, 2026 at 4:06 pm
I have this my image in Adobe Illustrator. How can I simulate a coarse-grained concrete surface with the libraries? \documentclass{article} \usepackage{tikz} \usetikzlibrary{patterns} \begin{document} \begin{tikzpicture}[scale=1] \draw[->,thick] (-3.2,-1.65)--(4.3,-1.65) node[below right] {$x$}; % ground \fill[pattern=north east lines,pattern color=gray] (-3.2,-1.9) rectangle (4,-1.65); \end{tikzpicture} \end{document}
- Count the number of no-empty delimited argumentsby myhsia on July 9, 2026 at 8:31 am
I defined a function \__foo:w #1+#2+#3, like the MWE below \documentclass{article} \begin{document} \ExplSyntaxOn \cs_new:Npn \__foo:w #1 + #2 + #3 \q_stop { \textbf{#1},~ \textit{#2} \tl_if_blank:eF {#3} { ,~ \texttt{#3} } } \__foo:w tex + live + 2026 \q_stop % \__foo:w tex+live \q_stop \ExplSyntaxOff \end{document} But if users use \foo:w tex+live, due to the second delimiter + could not be founded, then error arises: File ended while scanning use of \foo:w <inserted text> Certainly, I know I can use l3seq, but I think it is not an elegant way. Is there a way to allow the usage \__foo:w tex+live \q_stop? Note \textbf, \textit, \texttt are just for demoing; in fact, I will use other personal defined functions.
- How to make a relatively more beautiful classification table of quadratic functions?by D G on July 9, 2026 at 12:16 am
Objectives: remove top left cell all contents are vertically and horizontally centered well balanced padding in each cell make it relatively much more beautiful \documentclass[12pt,border=12pt]{standalone} \usepackage{amsmath,array,tikz} \usetikzlibrary{math} \newcommand{\graph}[2][]{ \begin{tikzpicture}[baseline=(current bounding box.center)] \draw[blue,thick,->] (-1.5,#2)--(1.5,#2) node[right]{$x$}; \draw[red,thick,domain=-1.5:1.5,samples=100] plot(\x,{#1\x*\x/2}); \end{tikzpicture} } \renewcommand{\arraystretch}{1.8} \setlength{\tabcolsep}{18pt} \begin{document} \begin{tabular}{| >{\centering\arraybackslash}m{2.2cm}| >{\centering\arraybackslash}m{5.2cm}| >{\centering\arraybackslash}m{5.2cm}|} \cline{2-3} & $\mathbf{a>0}$ & $\mathbf{a<0}$ \\ \hline $\mathbf{D<0}$ & \graph{-1/2} & \graph[-]{1/2} \\ \hline $\mathbf{D=0}$ & \graph{0} & \graph[-]{0} \\ \hline $\mathbf{D>0}$ & \graph{1/2} & \graph[-]{-1/2} \\ \hline \end{tabular} \end{document} Any improvements are always welcome!
- Inside a longtblr, how can I split an itemize list — wrapped in a minipage — across pages?by Ommo on July 8, 2026 at 9:54 pm
I found that "itemize" works inside "longtblr" when it is wrapped with a "minipage": \usepackage [ a4paper, left = 0.2cm, right = 0.2cm, top = 0.1cm, bottom = 0.2cm, ] {geometry} \usepackage{tabularray} \usepackage{lipsum} \newcommand{\rowgap}{10pt} \begin{document} \begin{center} \DefTblrTemplate{firsthead, middlehead,lasthead}{default}{} \begin{longtblr}[presep=-4pt,postsep=0pt] {colspec = {p{3.2cm}X},width=\textwidth,colsep=0pt,rowsep=0pt} 1 December 1871 & Some intro text:\\ & \lipsum[1-3] \\[\rowgap] 15 June 2016 & Some text:\\ & \begin{minipage}[t]{\linewidth} \begin{itemize} \item \lipsum[7] \item \lipsum[8] \item \lipsum[9] \end{itemize} \end{minipage} \\[\rowgap] 30 March 2051 & Other intro text:\\ & Hello man! \\[\rowgap] \end{longtblr} \end{center} \end{document} That code produces the following output: However, if one of the "itemize" entries is made longer, for example, \item \lipsum[7] \item \lipsum[8] \item \lipsum[9-11] the "minipage" prevents the "itemize" environment from breaking across pages. As a result, the entire list is moved to the second page instead of being split between the first and second pages, producing the following output: My question: inside a "longtblr", how can I split an "itemize" list — wrapped in a "minipage" — across pages? Should I wrap my "itemize" list in a different environment that allows it to split across pages? If so, which one? Are there any other solutions for using "itemize" inside "longtblr"? EDIT (9 July 2026): Thanks, everyone, for your comments! I realize I didn't explain why I chose to use a table here. My intention is to take advantage of some features that — to my understanding — are specific to the table environment. For example, the ability to highlight particular rows and columns by applying different colors: \documentclass[11pt,english]{article} \usepackage [ a4paper, left = 0.2cm, right = 0.2cm, top = 0.1cm, bottom = 0.2cm, ] {geometry} \usepackage{tabularray} \usepackage{lipsum} \newcommand{\rowgap}{10pt} \usepackage{xcolor} \definecolor{MyColor1}{rgb}{0.22,0.45,0.70} % light blue \definecolor{MyColor2}{rgb}{0.55,0.75,0.65} % mint green \begin{document} \begin{center} \DefTblrTemplate{firsthead, middlehead,lasthead}{default}{} \begin{longtblr}[presep=-4pt,postsep=0pt] {colspec = {p{3.2cm}X},width=\textwidth,colsep=0pt,rowsep=0pt} 1 December 1871 & Some intro text:\\ & \lipsum[1-3] \\[\rowgap] \SetRow{bg=MyColor1!20} 15 June 2016 & Some text:\\ & \begin{minipage}[t]{\linewidth} \begin{itemize} \item \lipsum[7] \item \lipsum[8] \item \lipsum[9] \end{itemize} \end{minipage} \\[\rowgap] \SetRow{bg=MyColor2!20} 30 March 2051 & Other intro text:\\ & Hello man! \\[\rowgap] \end{longtblr} \end{center} \end{document} Which gives this output: I was therefore wondering whether \begin{description} ... \end{description} can provide the same functionality. So far, I have not been able to find a way to reproduce this feature within the "description" environment.
- Trail or trace of a moving charged particleby Sebastiano on July 8, 2026 at 12:31 pm
I think in 2019 I built the following image with Adobe Illustrator for my book. Now, since there are so many images in pdf, I am slowly creating them in TikZ code. I wanted to know if there is something to create a trail for the blue particle similar to the main image or any other idea you have. Thank you. \documentclass{article} \usepackage{tikz} \usetikzlibrary{arrows.meta} \tikzset{rhtip/.tip={Triangle[line width=1pt, fill=white, length=9pt, width=9pt]}, pics/clock/.style args={#1/#2}{ code={ \def\dist{0.38} \draw[thin] (0,0) circle (\dist); \draw[line width=.7pt] (0,0) -- ({0.16*cos(90-30*#1-0.5*#2)}, {0.16*sin(90-30*#1-0.5*#2)}); \draw[line width=.7pt] (0,0) -- ({0.28*cos(90-6*#2)}, {0.28*sin(90-6*#2)}); } } } \begin{document} \begin{tikzpicture}[scale=.8] \draw[->] (0,0) -- (4.8,0) node[right] {$x$}; \draw[->] (0,0) -- (0,4.8) node[above] {$z$}; \draw[->] (0,0) -- (1.8,1.1) node[above] {$y$}; \node at (-0.4,4.3) {$\Sigma$}; \shade[ball color=cyan] (2.7,1.2) circle (0.2); \draw[brown!80!black,line width=2pt,-rhtip] (2.9,1.2)--(3.8,1.2) node[midway,above left] {$\mathbf{u}$}; \pic at (2.5,2.5) {clock={1/10}}; \node[blue!60!black] at (3.35,2.9) {$C(u)$}; \begin{scope}[shift={(5,1)}] \draw[->] (0,0)--(4.5,0) node[right] {$x'$}; \draw[->] (0,0)--(0,4.8) node[above] {$z'$}; \draw[->] (0,0)--(1.8,1.1) node[above] {$y'$}; \node at (-0.4,4.3) {$\Sigma'$}; \draw[magenta,line width=2pt,-rhtip] (0,3.6)--(1.8,3.6) node[midway,above] {$\mathbf{v}$}; \draw[green!60!black,line width=2pt,-rhtip] (2.1,1.3)--(3.7,1.3) node[midway,below] {$\mathbf{u}'$}; \pic at (2.5,2.5) {clock={2/20}}; \node[blue!60!black] at (3.55,2.9) {$C'(u')$}; \end{scope} \end{tikzpicture} \end{document}
- Left indices for atomsby Brasil on July 6, 2026 at 10:03 pm
Is it possible to right align the left upper and lower indices that characterize atomic properties using \chemfig? Example: \chemfig{^{14}_6C} prints out the following: However, I would like to have the following: How to get it? EDIT: adding a MWE \documentclass[border=1mm]{standalone} \usepackage{chemfig} \begin{document} \chemfig{^{14}_6C} \end{document}