Hot
- First paragraph not indented in paracol environmentby Roland Chastain on November 23, 2025 at 10:04 am
I am making a bilingual document using paracol. I don't know why the first paragraph is not indented, as other are. I would like that it be indented. Here is my code: \documentclass[14pt,a4paper]{extarticle} \usepackage{fontspec} \usepackage[german,latin]{babel} \usepackage{microtype} \usepackage[margin=16mm]{geometry} \usepackage{paracol} % https://tex.stackexchange.com/a/505562/295527 \newcommand\chunks[2]{% \begin{leftcolumn*}\begin{otherlanguage}{latin}% {#1}% \end{otherlanguage}\end{leftcolumn*}% \begin{rightcolumn}\begin{otherlanguage}{german}% {#2}% \end{otherlanguage}\end{rightcolumn}% } \setlength{\columnsep}{8mm} \setlength{\columnseprule}{0.4pt} \usepackage[center]{titlesec}% https://tex.stackexchange.com/a/107282/295527 \begin{document} \thispagestyle{empty} \section*{GEBETE.} \subsection*{Das «Gegrüsset seist du, Maria».} \begin{paracol}{2} \chunks{\textsc{Ave}, Maria, gratia plena, Dominus tecum, benedicta tu in mulieribus et benedictus fructus ventris tui, Jesus.} {\textsc{Gegrüsset} seist du, Maria, voll der Gnade; der Herr ist mit dir; du bist gebeinedeit unter den Weibern, und gebeinedeit ist die Frucht deines Leibes, Jesus.} \chunks{Sancta Maria, Mater Dei, ora pro nobis peccatoribus, nunc et in hora mortis nostræ. Amen.} {Heilige Maria, Mutter Gottes, bitte für uns Sünder jetzt und in der Stunde unseres Todes! Amen.} \end{paracol} \end{document}
- Plans for evolution/support of {Xe|Lua[node|harf]}LaTeX?by Alain Stalder on November 23, 2025 at 7:44 am
Let me first give some context: As far as I can see, the original TeX/LaTeX including rendering with pdflatex has been very reliably producing the same visual output for decades now and presumably will for many more decades into the future, while there can be glitches due to various optional packages influencing each other. If you plan to or need to support a series of possibly evolving documents with a shared *TeX source code base, that is a very important feature, often close to an absolute necessity. However, I guess still due to Donald E. Knuth’s decision of 1990 in a TUGboat article titled The Future of TeX and METAFONT to not allow especially METAFONT to evolve into the future, and with in parallel newer font features broadly needed and desired, new variants/"variants" of LaTeX emerged that use especially OpenType fonts, I presume having evolved partially via ConTeXt to now XeLaTeX and LuaLaTeX. As far as I understand, XeLaTeX uses the HarfBuzz library (C++, the basis of font support in modern web browsers, Android and a lot more), which is also used by LuaLaTeX with the HarfBuzz renderer, while LuaLaTeX with the default Node renderer is doing it in some other way (maybe native Lua or C?). These three "engines" (XeLaTeX, LuaLaTeX/HarfBuzz and LuaLaTeX/Node) seem to produce similar output in many typical use cases, but in border cases differ. In contrast, as Knuth writes in the above article, at least at the time he wrote it there were tests called TRIP and TRAP that specifically focus on border/edge cases, again a very desirable feature in the context of long-term reliability. Since I write software for a living and partially also as a hobby, I am well aware that for all that it appears the situation is not easy or simple: The three "engines" are broadly used (except maybe LuaLaTeX/HarfBuzz?) so that I presume even making small meaningful changes or small bug fixes would often be close to impossible. Now to the main question (which I presume is of interest to many *TeX users): What are the plans and/or the likely outcome for the three "engines" and thus what is the recommendation which of those three (if any) to use if you want long-term reliable output and need features beyond pdflatex? Related questions that could at least make it easier to decide individually for users: • Any plans to freeze one or some of the "engines"? (Has XeLaTeX already been essentially frozen? And maybe LuaLaTeX/HarfBuzz less future than LuaLaTeX/Node? Or the other way round? Or both to evolve? If several "engines" are planned to keep evolving, any plans to harmonize their output a bit further? Or plans for a new "engine" that would be largely compatible with "the best of all three" but have a more stringent design and tests? Maybe a new renderer "..." for LuaLaTeX?) • Are there tests similar to "TRIP and TRAP" for any of those "engines" or plans to implement more of that in the future? • Any helpful links around the planned/envisioned future of *TeX would be appreciated... Questions on the side: • Did anybody recently ask Donald E. Knuth if he would maybe be willing to change his mind regarding the Computer Modern font under some circumstances, like maybe a well-defined and well-tested environment, like maybe in a future "engine" out of or derived from the mentioned three? (In my personal view, the quality of the font is unparalleled, but it is also tied to it being typeset as intended, which I why I can understand his decision in 1990.)
- Command \showhyphens has changedby DavidIsDumb on November 23, 2025 at 1:58 am
I got a warning when using Overleaf saying "Command \showhyphens has changed". The AI tells me I don't need to change anything, but honestly I don't understand why that pops up. There are hyphens in my text and they work normally. Can somebody explain why the error message is there? The AI said "The message "Command \showhyphens has changed." is an informational message, not an error. It usually appears when a package (like babel or polyglossia) redefines the \showhyphens command. This does not stop compilation and does not require a fix unless you are experiencing other issues. No action is needed for this message. If you are experiencing other errors, please provide those log entries." and I used \usepackage[dvipsnames,svgnames]{xcolor} \usepackage[shortlabels]{enumitem} \usepackage[framemethod=TikZ]{mdframed} \usepackage{amsmath,amssymb,amsthm} \usepackage{epigraph} \usepackage[colorlinks]{hyperref} \usepackage{microtype} \usepackage{mathtools} \usepackage[headsepline]{scrlayer-scrpage} \usepackage{thmtools} \usepackage{listings} \usepackage{derivative} Which package doesn't work?
- How to use a GPU to run Lua math faster?by Jasper on November 23, 2025 at 12:37 am
I've heard that I can hook up a GPU to handle my matrix multiplications significantly faster. I want to do this locally, so I can make gifs faster. E.g., I have a lua-based animation, and it still takes ages to compile. I heard a GPU can do it orders of magnitude faster. That makes a 10 minute video compile in about 6 seconds, assuming as least two orders. MWE: \documentclass[tikz,border=1cm]{standalone} \usepackage{lua-tikz3dtools} % https://github.com/Pseudonym321/TikZ-Animations/tree/master1/TikZ/lua-tikz3dtools \begin{document} \pgfmathsetmacro{\startparam}{0} \pgfmathsetmacro{\stopparam}{2*pi} \pgfmathsetmacro{\samplesparam}{40} \pgfmathsetmacro{\stepparam}{(\stopparam-\startparam)/(\samplesparam-1)} \foreach \param[parse=true] in {\startparam,\startparam+\stepparam,...,\stopparam-\stepparam } { \begin{tikzpicture} \useasboundingbox[scale=6] (-1,-1) rectangle (1,1); \setobject[ name = {T} ,object = { matrix_multiply( matrix_multiply( euler(pi/2,pi/4+pi/4*sin(\param),5.25*pi/6+\param) ,translate(0,0,-10) ) ,matrix_multiply( { {1,0,0,0} ,{0,1,0,0} ,{0,0,1,0} ,{0,0,0,1} } ,matrix_multiply(xscale(1),yscale(1)) ) ) } ] \setobject[ name = {I} ,object = { matrix_inverse(T) } ] \appendsurface[ ustart = {-2} ,ustop = {2} ,usamples = {20} ,vstart = {-2} ,vstop = {2} ,vsamples = {20} ,transformation = {T} ,x = {u} ,y = {v} ,z = {u^4 + v^4 - 4*u*v + 1} ,fill options = { preaction = { fill = green ,fill opacity = 0.2 } ,postaction = { draw = blue ,ultra thin ,line join = round } } ,filter = { abs(matrix_multiply(A,I)[1][3])<2.01 and abs(matrix_multiply(B,I)[1][3])<2.01 and abs(matrix_multiply(C,I)[1][3])<2.01 and abs(matrix_multiply(A,I)[1][2])<2.01 and abs(matrix_multiply(B,I)[1][2])<2.01 and abs(matrix_multiply(C,I)[1][2])<2.01 and abs(matrix_multiply(A,I)[1][1])<2.01 and abs(matrix_multiply(B,I)[1][1])<2.01 and abs(matrix_multiply(C,I)[1][1])<2.01 } ] % I can't find these trajectories for the life of me! % \appendcurve[ % ustart = {-2} % ,ustop = {2} % ,usamples = {20} % ,transformation = {T} % ,x = {u*cos(pi/4)} % ,y = {u*sin(pi/4)} % ,z = {(u*cos(pi/4))^4 + (u*sin(pi/4))^4 - 4*(u*cos(pi/4))*(u*sin(pi/4)) + 1} % ,draw options = { % draw = blue % ,ultra thin % ,line join = round % } % ] % \appendcurve[ % ustart = {-2} % ,ustop = {2} % ,usamples = {20} % ,transformation = {T} % ,x = {u*cos(3*pi/4)} % ,y = {u*sin(3*pi/4)} % ,z = {(u*cos(3*pi/4))^4 + (u*sin(3*pi/4))^4 - 4*(u*cos(3*pi/4))*(u*sin(3*pi/4)) + 1} % ,draw options = { % draw = red % ,ultra thin % ,line join = round % } % ] \appendsolid[ ustart = {-2} ,ustop = {2} ,usamples = {2} ,vstart = {-2} ,vstop = {2} ,vsamples = {2} ,wstart = {-2} ,wstop = {2} ,wsamples = {2} ,transformation = {T} ,x = {u} ,y = {v} ,z = {w} ,fill options = { preaction = { fill = none ,fill opacity = 0.5 } ,postaction = { draw = none ,ultra thin ,line join = round ,line cap = round } } ] \appendcurve[ ustart = {0} ,ustop = {4} ,usamples = {2} ,x = {0} ,y = {0} ,z = {u} ,transformation = {T} ,arrow tip = {true} ,draw options = { draw ,ultra thin ,line cap = round } ] \appendlabel[ x = {0} ,y = {0} ,z = {4.3} ,transformation = {T} ,name = {\(z\)} ] \appendcurve[ ustart = {0} ,ustop = {4} ,usamples = {2} ,x = {0} ,y = {u} ,z = {0} ,transformation = {T} ,arrow tip = {true} ,draw options = { draw ,ultra thin ,line cap = round } ] \appendlabel[ x = {0} ,y = {4.3} ,z = {0} ,transformation = {T} ,name = {\(y\)} ] \appendcurve[ ustart = {0} ,ustop = {4} ,usamples = {2} ,x = {u} ,y = {0} ,z = {0} ,transformation = {T} ,arrow tip = {true} ,draw options = { draw ,ultra thin ,line cap = round } ] \appendlabel[ x = {4.3} ,y = {0} ,z = {0} ,transformation = {T} ,name = {\(x\)} ] \foreach \p in {-4,-3,...,4} { \appendcurve[ ustart = {-4} ,ustop = {4} ,usamples = {2} ,x = {u} ,y = {\p} ,z = {0} ,transformation = {T} ,draw options = { draw = black!70!white ,ultra thin ,line cap = round ,densely dashed } ] \appendcurve[ ustart = {-4} ,ustop = {4} ,usamples = {2} ,x = {\p} ,y = {u} ,z = {0} ,transformation = {T} ,draw options = { draw = black!90!white ,ultra thin ,line cap = round ,densely dashed } ] } \appendsurface[ ustart = {-4} ,ustop = {4} ,usamples = {2} ,vstart = {-4} ,vstop = {4} ,vsamples = {2} ,transformation = {T} ,x = {u} ,y = {v} ,z = {0} ,fill options = { preaction = { fill = gray!70!white ,fill opacity = 0.6 } ,postaction = { draw = none ,ultra thin ,line join = round } } ] \displaysegments \end{tikzpicture} } \end{document}
- [T1]{fontenc} changes "lightness" of font [duplicate]by Allan Felipe on November 22, 2025 at 11:04 pm
I noticed that I need to comment the line \usepackage[T1]{fontenc} to get a normal font or else it becomes "light". Since I believe that's not a normal behavior, what could be the reason for that? I'll paste the packages in my preamble and two images with and without [T1]{fontenc}. Thanks % \usepackage[T1]{fontenc} \usepackage[ansinew]{inputenc} \usepackage[brazil]{babel} \usepackage{etoolbox} \usepackage{graphicx} \usepackage{array} \usepackage{caption} \usepackage{subcaption} % \usepackage{newtxtext,newtxmath} \usepackage{pifont} \usepackage[dvipsnames]{xcolor} \usepackage{amsmath} \usepackage{amssymb} \usepackage{tikz} \usepackage{multirow} \usepackage{fancyhdr} \usepackage{indentfirst} \usepackage[a4paper, left=2.5cm, right=2.5cm, bottom=2.2cm, top=3.2cm]{geometry}
- Why doesn't Tcolorbox respect spacingby Dorian on November 22, 2025 at 10:41 pm
I am facing a problem with tcolorbox: the spacing between my paragraphs and my lists is not the same inside a tcolorbox, and I don’t know how to fix it (as you can see in the image, the blue arrow shows a much larger spacing than the purple arrow). Thank you in advance. MWE : \documentclass[11pt]{article} % Encodings and language \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage[french]{babel} \usepackage{lmodern} % ============================================================ % GLOBAL SPACING MANAGEMENT % ============================================================ % 1. Spacing between paragraphs \setlength{\parskip}{4pt} % space between paragraphs \setlength{\parindent}{0pt} % indentation of the first line % 2. Line spacing in the text \usepackage{setspace} \setstretch{1.15} % line spacing (1.0 = single, 1.3 = 1.5, 1.6 = double) % ============================================================ % LIST MANAGEMENT (itemize, enumerate, etc.) % ============================================================ \usepackage{enumitem} % Fine configuration: \setlist{ % itemsep=0pt, % space between items % parsep=4pt, % space between paragraphs inside an item topsep=0pt, % space before/after the list % partopsep=2pt, % additional space at the beginning of a list inside environments % left=1.5em % left margin } % ============================================================ % PARAMETERS FOR TCOLORBOX % ============================================================ \usepackage{tcolorbox} % Example of a tcolorbox style controlling spacing \tcbset{ myboxstyle/.style={ colback=white, colframe=black, boxsep=4pt, % internal space between the border and the text left=4pt, % internal left margin right=4pt, % internal right margin top=6pt, % internal top margin bottom=6pt, % internal bottom margin before skip=12pt, % space before the box after skip=12pt, % space after the box } } % ============================================================ \begin{document} \section*{Example with all spacing controlled} Here is a paragraph of text to illustrate spacing. % Outer list \begin{itemize} \item Outer item A \item Outer item B \item Outer item C \end{itemize} Here is the paragraph that follows the list. % tcolorbox with a list \begin{tcolorbox}[myboxstyle, title=Box with itemize] Example of text inside a tcolorbox. \begin{itemize} \item Inner item 1 \item Inner item 2 \item Inner item 3 \end{itemize} Middle of the box \begin{itemize} \item Inner item 4 \item Inner item 5 \item Inner item 6 \end{itemize} \end{tcolorbox} % List after the box \begin{itemize} \item Outer item D \item Outer item E \end{itemize} \end{document}
- Make tcblistof display tcolorboxes from the current chapter onlyby UnderscorePoY on November 22, 2025 at 9:41 pm
Setup: In a big document with several chapters, i generate several tcolorbox instances per chapter of the same tcbtheorem called "method", with an option list inside={methods}. Needed: At the start of each chapter, i want to display -- with a call to \tcblistof -- a list of all methods within that chapter. Issue: With this default implementation, the first call to \tcblistof outputs a single list containing all "method" boxes from all the chapters, and any subsequent call to \tcblistof produces an empty list. Question: What is the simplest way to achieve this ? An idea could be to edit the value inside the list inside option to change depending on the chapter count, but i don't know how to do this or even if this is the cleanest solution. MWE: \documentclass[a4paper, 11pt]{report} \usepackage[many]{tcolorbox} \newtcbtheorem[list inside={methods}]{method}{Method}{}{}% \begin{document} \chapter{My chapter 1} \tcblistof[\section*]{methods}{Methods Chapter 1}% Lists all methods, not only this chapter's \begin{method}{1}{} \end{method} \begin{method}{2}{} \end{method} \chapter{My chapter 2} \tcblistof[\section*]{methods}{Methods Chapter 2}% Lists nothing \begin{method}{3}{} \end{method} \begin{method}{4}{} \end{method} \end{document}
- Factorize a forest codeby projetmbc on November 22, 2025 at 9:40 pm
In the code below, made using the "AI" Claude, there is too much copying and pasting of lines like the ones shown below. What is the best way to factorize the full code? archivefile/.style={ before typesetting nodes={ content/.wrap value={ \textcolor{orange!80}{\faFileArchive}\ ##1 } } } Here is the full code. \documentclass{article} \usepackage{forest} \usepackage{fontawesome5} \definecolor{foldercolor}{RGB}{124,166,198} \definecolor{filecolor}{RGB}{88,88,88} \forestset{ dir tree/.style={ for tree={ font = \sffamily, grow' = 0, child anchor = west, parent anchor= south, anchor = west, calign = first, inner ysep = 1pt, inner xsep = 1.75pt, text depth = 0pt, edge path = { \noexpand \path[draw, \forestoption{edge}] (!u.south west) +(7.5pt,0) |- (.child anchor)\forestoption{edge label}; }, before typesetting nodes={ if n=1 {insert before={[,phantom]}} {} }, fit = band, before computing xy = {l = 15pt}, } }, open/.style={ before typesetting nodes={ content/.wrap value={ \textcolor{foldercolor}{\faFolderOpen}\ ##1 } } }, closed/.style={ before typesetting nodes={ content/.wrap value={ \textcolor{foldercolor}{\faFolder}\ ##1 } } }, file/.style={ before typesetting nodes={ content/.wrap value={ \textcolor{filecolor}{\faFile}\ ##1 } } }, codefile/.style={ before typesetting nodes={ content/.wrap value={ \textcolor{filecolor}{\faFileCode}\ ##1 } } }, pdffile/.style={ before typesetting nodes={ content/.wrap value={ \textcolor{red!70}{\faFilePdf}\ ##1 } } }, textfile/.style={ before typesetting nodes={ content/.wrap value={ \textcolor{filecolor}{\faFile*}\ ##1 } } }, imagefile/.style={ before typesetting nodes={ content/.wrap value={ \textcolor{blue!70}{\faFileImage}\ ##1 } } }, archivefile/.style={ before typesetting nodes={ content/.wrap value={ \textcolor{orange!80}{\faFileArchive}\ ##1 } } }, } \begin{document} \subsection*{Exemple d'arborescence de fichiers} \begin{forest} dir tree [system, open [config, closed [settings.conf, textfile] [database.yml, codefile] ] [doc, open [manual.pdf, pdffile] [README.md, textfile] [images, closed [logo.png, imagefile] [banner.jpg, imagefile] ] ] [lib, closed [utils.py, codefile] [helpers.js, codefile] [archive.zip, archivefile] ] [test, open [test\_unit.py, codefile] [test\_integration.py, codefile] [fixtures, closed [data.json, file] ] ] ] \end{forest} \subsection*{Exemple simple} \begin{forest} dir tree [system, open [config, closed] [Dog, closed] [lib, closed] [test, closed] ] \end{forest} \end{document}
- Using preview with glossaries?by nowox on November 22, 2025 at 8:28 pm
I notice the following do not build: \documentclass{article} \usepackage[active,tightpage]{preview} \setlength\PreviewBorder{0pt} \usepackage[acronym]{glossaries} \makeglossaries \newacronym{NASA}{NASA}{National Aeronautics and Space Administration} \begin{document} \begin{preview} The National Aeronautics and Space Administration \acrshort{NASA} is responsible for the civilian space program. \printglossary[type=\acronymtype, title=List of Acronyms] \end{preview} \end{document} There is a clash between the preview: \@istfilename found in 'test.aux'. It seems preview don't like the \write triggered by \acrshort and \printglossary. I notice I can tweak the .latexmkrc: $bibtex_use = 2; $biber = 'biber %O %B'; $root_filename = 'test'; $pdf_mode = 4; # Preview is enabled only after a successful glossaries run: we gate on a flag # file %R.preview.ready set by run_makeglossaries. $lualatex = qq{bash -lc 'TS_PREVIEW=\$( [ -f "%R.preview.ready" ] && echo 1 || echo 0 ); \ export TS_PREVIEW; lualatex --shell-escape %O %S'}; if (system("which texindy >/dev/null 2>&1") == 0) { $makeindex = 'texindy %O -o %D %S'; } else { $makeindex = 'makeindex %O -o %D %S'; } $clean_ext .= ' %R.run.xml %R.blg %R.preview.ready'; add_cus_dep('glo', 'gls', 0, 'run_makeglossaries'); add_cus_dep('acn', 'acr', 0, 'run_makeglossaries'); sub run_makeglossaries { my ($base) = @_; my $cmd = "makeglossaries \"$base\""; my $status = system($cmd); if ($status == 0) { system("touch \"$base.preview.ready\""); } return $status; } and modify my file to have: \documentclass{article} \newif\iftsPreview \tsPreviewfalse \ifdefined\directlua \directlua{ if os.getenv("TS_PREVIEW") == "1" then tex.print("\\global\\tsPreviewtrue") end } \fi \iftsPreview \usepackage[active,tightpage]{preview} \setlength\PreviewBorder{0pt} \fi \newenvironment{MaybePreview}{\iftsPreview\begin{preview}\fi}{\iftsPreview\end{preview}\fi} \usepackage[acronym]{glossaries} \makeglossaries \newacronym{NASA}{NASA}{National Aeronautics and Space Administration} \begin{document} \begin{MaybePreview} The National Aeronautics and Space Administration \acrshort{NASA} is responsible for the civilian space program. \printglossary[type=\acronymtype, title=List of Acronyms] \end{MaybePreview} \end{document} Is there a smarter way?
- how to shade an region bounded by curvesby underflow on November 22, 2025 at 6:43 pm
I have a region on the plane bounded by two hyperbolas xy = +/- C. What is the best/simplest way to shade (not filled) the "star shaped" region enclosed by these two hyperbolas? Advanced version of this question: I have two rays in the first quadrant, starting from the origin. These two rays cut out a curved wedge in the star shaped region. How I can shade this wedge in a different color from the rest of the region? Here is a MWE for the star shaped region, plus the two rays: \documentclass{amsart} \usepackage{tikz} \begin{document} \begin{tikzpicture} \draw [thick, domain=0.5:3] plot (\x, { 1.2/\x)}); \draw [thick, domain=-3:-0.5] plot (\x, { 1.2/\x)}); \draw [thick, domain=0.5:3] plot (\x, {-1.2/\x)}); \draw [thick, domain=-3:-0.5] plot (\x, {-1.2/\x)}); \draw (-3.4,0) -- (3.4,0); \draw (0,-2.6) -- (0,2.6); \draw [thick] (0,0) -- (2.2,2.2); \draw [thick] (0,0) -- (3.1,1.5); \end{tikzpicture} \end{document} Thanks for your help! EDIT: I know how to fill a polygon using \draw [filled] (coord) -- (coord) -- etc but I don't know how to handle the parabolas.
- resume enumerate from previous environmentby stackoverflow21 on November 22, 2025 at 6:01 pm
I'd like to resume the enumeration from my defined exercise environment. However, the resume option of enumitem obviously only resumes the first level of the enumeration. Therefore, I tried to save and restore enumii, which unfortunately does not work this way. Is there any way to resume with the second level of the previous environment? Here is my MWE: \documentclass{article} \usepackage{enumitem} \newcounter{cntExercise} \newcounter{saveenumii} \newenvironment{Exercise}{ \refstepcounter{cntExercise} \subsubsection*{Exercise Number \thecntExercise} \begin{enumerate}[label={\thecntExercise.\arabic*}] } { \setcounter{saveenumii}{\value{enumii}} \end{enumerate} } \newenvironment{Exerciseresume}{ \setcounter{enumii}{\value{saveenumii}} \begin{enumerate}[resume, label={\thecntExercise.\arabic*}] } { \end{enumerate} } \begin{document} \begin{Exercise} \item problem 1.1 \end{Exercise} \begin{Exercise} \item problem 2.1 \item problem 2.2 \end{Exercise} \noindent some text... \begin{Exerciseresume} \item shoud be problem 2.3 \end{Exerciseresume} \end{document}
- How can I make sure characters 157 and 158 are populated with autoinst?by TobiBS on November 22, 2025 at 5:00 pm
I have some Corporate True Type Fonts and use autoinst to convert them. However even though unicode characters uni0130 and uni0111 are there, after using the converted fonts I get the issue: glyph `Idotaccent' not found and glyph `dcroat' not found So I had a look and thought I need to provide unicoding commands to otftotfm, so I added extra commands to autoinst and the log files confirm that they are used: extra: --no-truetype --unicoding=Idot=:uni0130 --unicoding=dmacron=:uni0111` But no matter if I use Idotaccent or Idot or dmacron or dcroat, pdfLatex gives me the same output. What I don't get in the first place is, why I should provide such a command anyway. The font gives when I call otfinfo -g the glyphs Idotaccent and dcroat and of course contains unicode characters uni0130 as well as uni0111. If I am calling otfinfo -u I even get: uni0111 278 dcroat uni0130 101 Idotaccent What am I missing and what do I need to change? Reacting to cfrs questions: Minimal example \documentclass[]{minimal} \pdfmapfile{+MyOwnSansFont.map} \usepackage{MyOwnSansFont} \usepackage[T1]{fontenc} \begin{document} \sffamily \.Iletişim İletişim Character 157: \char157 I with dot \end{document} The MyOwnSansFont is the auto generated style file from autoinst. This then gets me this error message: pdfTeX warning: pdflatex.exe (file MyOwnSansFont.ttf): glyph Idotaccent' not found` So I want T1 encoding and also told autoinst so, hence also in the style file it is available and from what I understand T1 should have them: % 0x90 /Rcaron /Sacute /Scaron /Scedilla /Tcaron /Tcedilla /Udblacute /Uring /Ydieresis /Zacute /Zcaron /Zdot /IJ /Idot /dmacron /section Further finding Thank you for the questions and reactions so far, I think I came closer to a solution, but it is still strange. So I started to read and then I traced down the encoding file that comes out of otftotfm, copied it to my working directory and manually changed from: %90 /Rcaron /Sacute /Scaron /Scedilla /Tcaron /Tcommaaccent /Uhungarumlaut /Uring /Ydieresis /Zacute /Zcaron /Zdotaccent /IJ /Idotaccent /dcroat /section to %90 /Rcaron /Sacute /Scaron /Scedilla /Tcaron /Tcommaaccent /Uhungarumlaut /Uring /Ydieresis /Zacute /Zcaron /Zdotaccent /IJ /Idot /dmacron /section and everything works as it should. So for whatever reason even though the glyph names are reported to be available by the ttf and are also properly mapped, pdftex can only access them under the other name. What could be the reason for this and how can I fix this in the creation process?
- latexmk failure with --shell-escapeby projetmbc on November 22, 2025 at 3:48 pm
The following TeX file is well managed when invoking latexmk -pdf -pdflatex="lualatex" main.tex, but latexmk fails when used with latexmk -pdf -pdflatex="lualatex --shell-escape" main.tex. First case needs at most 2 compilations Second case implies more than 5 compilations. Why? PS: luadraw is used. See https://github.com/pfradin/luadraw . % !TEX TS-program = lualatex \documentclass{standalone} \usepackage[svgnames]{xcolor} \usepackage[3d]{luadraw} \usepackage{animate} \begin{luacode*} nbimages = 35 name = "shadow" basename = cachedir .. name \end{luacode*} \begin{luadraw}{auto = false, exec = true} require 'luadraw_polyhedrons' local z0 = -3 local graphview = graph3d:new{ window3d = {-5, 8, -5, 8, z0, 5}, adjust2d = true, bbox = false, viewdir = perspective("yz", 0.35, 60), bg = "Beige", size = {10, 10} } local light = M(-5, -5, 3.5) local center = M(-1, -1, -1) local proj = function(A) return proj3dO( A, {z0*vecK, vecK}, A - light ) end local C = cube(center, M(-1, -1, z0)) -- TEMP: bug in version 2.3 local shadow, beam, beamVisible, beamHidden local theta = linspace(0, 360, nbimages + 1) for k = 1, nbimages do C_rotated = rotate3d( C, theta[k], {M(-1, -1, z0), vecK} ) shadow = cvx_hull3d( ftransform3d(C_rotated.vertices, proj) )[1] if not graphview:Isvisible(shadow) then shadow = reverse(shadow) end beam = pyramid(shadow, light, true) beamVisible, beamHidden = graphview:Classifyfacet(beam) graphview:Dfacet( graphview:Plane2facet({z0*vecK, vecK}), { color = "lightgray", contrast = 0 } ) graphview:Dseg3d({M(-5, -5, z0), light}) graphview:Dballdots3d(light, "Yellow", 2) graphview:Dpolyline3d( shadow, true, "draw = none, fill = DarkGray, fill opacity = 0.9" ) graphview:Dfacet( beamHidden, { color = "yellow", opacity = 0.4, mode = mShadedOnly } ) graphview:Dpoly( C_rotated, { color = "cyan", mode = mShadedHidden } ) graphview:Dfacet( beamVisible, { color = "yellow", opacity = 0.4, mode = mShadedOnly } ) graphview:Savetofile(basename .. k .. ".tkz") graphview:Cleargraph() end \end{luadraw} \def\nb{\directlua{tex.print(nbimages)}} \def\name{\directlua{tex.print(basename)}} \begin{document} \begin{animateinline}[ poster = first, controls, loop ]{6} \multiframe{\nb}{ik = 1+1}{% \input{\name\ik.tkz}% }% \end{animateinline} \end{document}
- circuitikz / pgfpicture: modify existing symbol to a new one and rename itby cis on November 22, 2025 at 1:37 pm
I want to create these block-circuit-symbols (I don't know the correct English name. 'Size limiter'? 'Limiter'? [German: "Größenwertbegrenzer"]) So I stole the \pgfpicture-code for the saturation-block (manual, p.107) out of the file pgfcircquadpoles.tex this is \pgfcirc@define@twoports{blocks} ... {saturation} ... (see MWE too). My current result (see below) definitely needs improvement. Feel free to make changes! But my main problem right now is: How do I give the new symbol its own name? In other words: How to make \draw (0,0) to[saturation] (2,0) to \draw (0,0) to[<better name>] (2,0) MWE: \documentclass[margin=5pt]{standalone} \usepackage{circuitikz} % How to give that another name as "saturation? \makeatletter %% origin: %% saturation block, contributed by P.Sacco <paul.sacco@estaca,eu> \pgfcirc@define@twoports{blocks} {} {\ctikzvalof{bipoles/saturation/width}} {saturation} {\ctikzvalof{bipoles/saturation/width}} {\ctikzvalof{bipoles/saturation/width}} { \pgfsetlinewidth{1.2\pgfstartlinewidth} \pgfpathmoveto{\pgfpointorigin} \pgfpathlineto{\pgfpoint{.4\pgf@circ@res@step}{.6\pgf@circ@res@step}} % \pgfpathlineto{\pgfpoint{0.65\pgf@circ@res@step}{.4\pgf@circ@res@step}} % \pgfpathmoveto{\pgfpointorigin} \pgfpathlineto{\pgfpoint{-.4\pgf@circ@res@step}{-.6\pgf@circ@res@step}} \pgfpathlineto{\pgfpoint{-0.85\pgf@circ@res@step}{-.6\pgf@circ@res@step}} \pgfusepath{draw} } \makeatother \begin{document} \begin{circuitikz} \draw (0,0) to[saturation, l=not orig. saturation] (2,0) to[L] (4,0); \end{circuitikz} \end{document}
- How to recreate a DuPont schemeby Dorian on November 22, 2025 at 1:30 pm
I'd like to recreate a DuPont scheme as the image below. I’m not necessarily asking for the exact code used to recreate the graphic, but rather for the packages and commands that would allow me to do it myself. Is there anything more “accessible” than TikZ? Thank you in advance 😉
- What parameter(s) control the vertical spacing of adjacent equations?by keith77777 on November 22, 2025 at 12:58 pm
I cannot find a parameter - other than vspace{} that affects only the vertical spacing of adjacent equations. \documentclass[% openright, % doublepage cleaning ends up right side 11pt, % font size ]{book}% \usepackage[fleqn]{amsmath}% \usepackage{amssymb}% \usepackage{amsthm}% \usepackage[english]{babel}% \usepackage{enumitem}% \usepackage{fancyvrb} \usepackage[paperheight=240mm,paperwidth=175mm,bindingoffset=12.5mm,showcrop]{geometry} \usepackage{setspace} \usepackage{mathtools}% \usepackage{float} \usepackage{parskip} \usepackage{hyperref}% \usepackage{fancyhdr,lastpage,fancyref}% \usepackage{refcount}% \makeatletter \renewcommand{\small}{\@setfontsize\small{10.25}{15}}% \renewcommand{\normalsize}{\@setfontsize\normalsize{10.95}{15}}% 15 \renewcommand{\large}{\@setfontsize\large{11.5}{15}} \makeatother % \setlength{\topsep}{4pt} % above and below the completed lst \setlength{\itemsep}{3.4pt} % item separation \setlength{\parsep}{4.5pt} % paras and items within lists \setlength{\partopsep}{2.8pt}% top and bottom if preceeded by \par \setlength{\parskip}{6pt} \setlength{\abovedisplayskip}{6pt plus 1pt minus 1pt} % equ - using 6.8pt and 4.8pt \setlength{\abovedisplayshortskip}{4pt plus 1pt minus 1pt} % \setlength{\belowdisplayskip}{6pt plus 0pt minus 0pt} % active - using 2pt and 2pt \setlength{\belowdisplayshortskip}{4pt plus 0pt minus 0pt} % \begin{document} \section{The vertical spacing of equations} A first line to demonstrate the effect of the parameter parskip. This line is nicely positioned above equation (1), % \begin{equation} {\hspace{84pt}A\hspace{-0.6pt}=\hspace{-0.6pt}a\hspace{-0.6pt}+(\hspace{1.2pt}i\hspace{-0.6pt}-\hspace{-0.8pt}1\hspace{0.8pt})\hspace{1.4pt}d} \label{eqn:chap_01_conv_div_series_12} \end{equation} % and this line nicely positioned below the equation. But adjacent equations (2) and (3) below are massively spaced. % \begin{equation} \text{\hspace{8pt}this one \hspace{44pt}}2\hspace{1pt}B\hspace{-0.8pt}=\hspace{-0.8pt}2\times A \label{eqn:chap_01_conv_div_series_22} \end{equation} % \begin{equation} \text{\hspace{8pt}and this \hspace{18pt}}C\hspace{-1.0pt}=\hspace{-1.0pt}\dfrac{n}{2}\hspace{1.0pt}\big\{\hspace{1.4pt}2\hspace{1.5pt}a\hspace{-0.4pt}+(\hspace{1.2pt}n\hspace{-0.4pt}-\hspace{-0.4pt}1\hspace{0.8pt})\hspace{1.4pt}d\hspace{1.2pt}\big\} \label{eqn:chap_01_conv_div_series_24} \end{equation} % Another line nicely positioned below - except for the protrusion \\[1.8pt] of the fraction above. % \begin{equation} \hspace{92pt}D\hspace{-1.0pt}=\hspace{-1.0pt}4\times C \label{eqn:chap_01_conv_div_series_24} \end{equation} % A final line showing the desired spacing below the math. \end{document}
- How to configure language with DocumentMetadata and documentclassby user2609605 on November 22, 2025 at 12:11 pm
I started using \DocumentMetadata just to create PDF/A. If I don't specify lang in the metadata, I receive LaTeX DocumentMetadata Warning: The language has not been set in (DocumentMetadata) \DocumentMetadata. (DocumentMetadata) Setting it to 'en' as fallback. which I can avoid specifying lang=en. I a sense, I specify the language also in \documentclass as an option english. I also use babel package and I know this reads the option english. It feels like a duplicate so I would like to remove language specification from the document class. Is the metadata setting really a replacement? What about hyphenation? What about German language? In particular I wonder about the treatment of german vs ngerman. Can this be expressed in \DocumentMetadata??
- latex verapdf dictionary stream contains duplicated key /Groupby user2609605 on November 22, 2025 at 11:56 am
I know, I shall add a minimal working example, and i am willing to do so, but could you give me a first hint? I compile a quite complicated document with lualatex, texlive 2025 After I verify on PDF/A 2b with verapdf. The test passes but... warnings occur: Nov 22, 2025 12:17:49 PM org.verapdf.parser.COSParser getDictionary WARNING: Dictionary/Stream contains duplicated key /Group(object key = 1677 0 obj, offset = 297743) Nov 22, 2025 12:17:49 PM org.verapdf.parser.COSParser getDictionary WARNING: Dictionary/Stream contains duplicated key /Group(object key = 1522 0 obj, offset = 267511) PASS /home/ernst/OpenSource/LatexMavenPluginGit/latex-maven-plugin/maven-latex-plugin/src/site/tex/manualLMP.pdf 2b verapdf return value: 0 Before i strip down, to locate the problem, can anyone give me a hint?
- Integral symbolby Didier on November 22, 2025 at 7:52 am
I have a problem with the integral symbol. Previously, it was perfectly straight and now it's tilted, even though I haven't changed my code. Before: Now: Here are the packages I use: \usepackage[dvipsnames,table,xcdraw]{xcolor} \usepackage{wrapfig2}%pour mettre des figures à côté de texte \usepackage{babel}%francisation \usepackage{mathtools} \usepackage[warnings-off={mathtools-colon,mathtools-overbracket},math-style=french]{unicode-math} \usepackage[default,varnothing]{fontsetup} \newfontface{\STIXTWO}{STIX Two Math} \usepackage[scale={0.75,0.8},footskip=1.5cm,heightrounded]{geometry} \usepackage[shortlabels]{enumitem}%pour pouvoir changer les labels des listes \usepackage{siunitx}%pour les unités \usepackage{xspace}%pour la gestion des espaces \usepackage[np,autolanguage]{numprint}%pour la séparation des milliers \usepackage{autoaligne}%pour les systèmes linéaires \usepackage{nicematrix}%pour les matrices "évoluées" \usepackage{tikz}%pour les graphiques et bien d'autres choses \usetikzlibrary{babel,fit,calc,arrows.meta,positioning,% decorations.pathreplacing,patterns.meta,angles,matrix,3d,quotes,mindmap,backgrounds} \usepackage{tkz-tab} \usepackage{emoji} \setemojifont{Noto Color Emoji} \usepackage[most]{tcolorbox}%pour les théorèmes, définitions, etc. \tcbuselibrary{documentation} Maybe there is an option in a package I should add? PS: Sorry for my English (I am French) Here is a MWE: \documentclass[10pt,a4paper,french]{book} \usepackage[dvipsnames,table,xcdraw]{xcolor} \usepackage{wrapfig2}%pour mettre des figures à côté de texte \usepackage{babel}%francisation \usepackage{mathtools} \usepackage[warnings-off={mathtools-colon,mathtools-overbracket},math-style=french]{unicode-math} \usepackage[default,varnothing]{fontsetup} \newfontface{\STIXTWO}{STIX Two Math} \usepackage[scale={0.75,0.8},footskip=1.5cm,heightrounded]{geometry} \usepackage[shortlabels]{enumitem}%pour pouvoir changer les labels des listes \usepackage{siunitx}%pour les unités \usepackage{xspace}%pour la gestion des espaces \usepackage[np,autolanguage]{numprint}%pour la séparation des milliers \usepackage{autoaligne}%pour les systèmes linéaires \usepackage{nicematrix}%pour les matrices "évoluées" \usepackage{tikz}%pour les graphiques et bien d'autres choses \usetikzlibrary{babel,fit,calc,arrows.meta,positioning,% decorations.pathreplacing,patterns.meta,angles,matrix,3d,quotes,mindmap,backgrounds} \usepackage{tkz-tab} \usepackage{emoji} \setemojifont{Noto Color Emoji} \usepackage[most]{tcolorbox}%pour les théorèmes, définitions, etc. \tcbuselibrary{documentation} \begin{document} \[\int_a^b f\] \end{document} And here is the result: I can't reproduce the upright version (and that's what I would want) Edit: I tried the solution provided by Apporv Potnis with the upint option. It is better but that's not exactlty what I had before: What I had before: Now with the upint option: As you can see, before it was less straight and more bold. I remember I recently updated the packages in Miktex. Maybe, it is the reason of the change? New Edit: In the stix-two package documentation, I see this: I think that is what I had before. So how do I get the Stylistic set 8?
- Key value option for enumerate definitionby azetina on November 22, 2025 at 5:44 am
Consider the following MWE: \documentclass{article} \usepackage{amsmath} \usepackage{xcolor} \usepackage{enumitem} \newlist{enumatlib}{enumerate}{2}% \setlist[enumatlib]{ label=\arabic*, font=\bfseries, align=left, leftmargin=*, labelsep=1em, labelwidth=*, itemsep=2.5ex, before=\setupmodenumerate } \setlist[enumatlib,2]{ label=\Alph*, font=\bfseries, leftmargin=*, itemsep=1ex, before=\setupmodenumerate} \newif\ifmoditem \newif\ifcitem \newcommand{\setupmodenumerate}{% \global\moditemfalse \global\citemfalse \let\origmakelabel\makelabel \def\moditem##1{\global\moditemtrue\def\mesymbol{\footnotesize\normalfont\color{red}\parbox[t]{10em}{\raggedleft##1}}\item}% \def\citem##1{\global\citemtrue\def\cecolor{##1}\item}% \def\makelabel##1{% \origmakelabel{\ifmoditem\llap{\mesymbol\enspace}\else\ifcitem\color{\cecolor}\fi\fi##1}% \global\moditemfalse\global\citemfalse}% } %----------------- usage examples ----------------- \begin{document} Default behaviour (both features on): \begin{enumatlib} \moditem{M4.5 (KSC)} First question \begin{enumatlib} \citem{red} option 1 \item option 2 \item option 3 \item option 4 \end{enumatlib} \moditem{GT8.9 (KSC)} Second question \begin{enumatlib} \item option 1 \citem{red} option 2 \item option 3 \item option 4 \end{enumatlib} \end{enumatlib} \end{document} I would like assistance in creating a key-value that toggles off and on the entries for moditem and citem. See below. \begin{enumatlib}[mod=false,citem=false] \moditem{M4.5 (KSC)} First question \begin{enumatlib} \citem{red} option 1 \item option 2 \item option 3 \item option 4 \end{enumatlib} \moditem{GT8.9 (KSC)} Second question \begin{enumatlib} \item option 1 \citem{red} option 2 \item option 3 \item option 4 \end{enumatlib} \end{enumatlib} By default \citem will always have red as the color but having the option to choose the color is ideal.
- Row colour problem with longtable, multicolumn and makecellby Subhajit Paul on November 22, 2025 at 5:37 am
How do I get the rowcolor spanned for the entire first row? \documentclass{article} \usepackage{longtable, makecell, booktabs} \usepackage[table]{xcolor} \begin{document} \begin{longtable}{m{0.1\linewidth} m{0.88\linewidth}} \toprule\endhead \rowcolor{gray}\multicolumn{2}{c}{\makecell[cc]{Top line\\Bottom line}}\\\bottomrule a & b \end{longtable} \end{document}
- expl3: l3file: \iow_now:Ne... doesn't expand tokens before writing to the stream?by Grass on November 22, 2025 at 4:43 am
MWE: \documentclass{article} \begin{document} \ExplSyntaxOn \iow_new:N \g__test_iow \iow_open:Nn \g__test_iow { test.pl } \iow_now:Ne \g__test_iow { \# } \iow_close:N \g__test_iow \ExplSyntaxOff \end{document} This produces the file test.pl with contents \# instead of #. Also, if I do \iow_now:Ne \g__test_iow { \$ }, I get the error \g__test_iow=\write3 \openout3 = `test.pl'. ./testing2.tex:7: TeX capacity exceeded, sorry [input stack size=10000]. \font@name -> \OT1/cmr/m/n/10 l.7 \iow_now:Ne \g__test_iow { \$ } I don't understand why this error occurs. In any case, to avoid a X-Y problem situation, here is more context: I want to make the following work: \documentclass{article} \begin{document} \ExplSyntaxOn \seq_new:N \l__test_seq \seq_put_right:Ne \l__test_seq { 1 } \int_new:N \l__test_int \iow_new:N \g__test_iow \iow_open:Nn \g__test_iow { test.pl } \iow_now:Ne \g__test_iow { \#!/usr/bin/perl \seq_map_inline:Nn \l__test_seq { \int_incr:N \l__test_int my~\$width\_\int_use:N \l__test_int~=~##1 } } \iow_close:N \g__test_iow \ExplSyntaxOff \end{document} As you can see, I'm trying to create a perl script to which I save some TeX values to.
- saddle point trajectoriesby Jasper on November 22, 2025 at 4:41 am
I am trying to graph the intersecting trajectories for a saddle point of a surface. In particular, there are two curves which intersect this point. One is concave up, and one is concave down. My aim is to graph both trajectories on the surface. The saddle point is at (0,0). \documentclass[tikz,border=1cm]{standalone} \usepackage{lua-tikz3dtools} % https://github.com/Pseudonym321/TikZ-Animations/tree/master1/TikZ/lua-tikz3dtools \begin{document} \pgfmathsetmacro{\startparam}{-pi/12} \pgfmathsetmacro{\stopparam}{pi/12} \pgfmathsetmacro{\samplesparam}{24} \pgfmathsetmacro{\stepparam}{(\stopparam-\startparam)/(\samplesparam-1)} \foreach \param[parse=true] in {\startparam} { \begin{tikzpicture} \useasboundingbox[scale=2] (-2,-2) rectangle (2,2); \setobject[ name = {T} ,object = { matrix_multiply( matrix_multiply( euler(pi/2,pi/3,5.25*pi/6) ,translate(0,0,-5) ) ,matrix_multiply( { {1,0,0,0} ,{0,1,0,0} ,{0,0,1,0} ,{0,0,0,1} } ,matrix_multiply(xscale(1),yscale(1)) ) ) } ] \setobject[ name = {I} ,object = { matrix_inverse(T) } ] \appendsurface[ ustart = {-2} ,ustop = {2} ,usamples = {20} ,vstart = {-2} ,vstop = {2} ,vsamples = {20} ,transformation = {T} ,x = {u} ,y = {v} ,z = {u^4 + v^4 - 4*u*v + 1} ,fill options = { preaction = { fill = green ,fill opacity = 0.2 } ,postaction = { draw = blue ,ultra thin ,line join = round } } ,filter = { abs(matrix_multiply(A,I)[1][3])<2.01 and abs(matrix_multiply(B,I)[1][3])<2.01 and abs(matrix_multiply(C,I)[1][3])<2.01 and abs(matrix_multiply(A,I)[1][2])<2.01 and abs(matrix_multiply(B,I)[1][2])<2.01 and abs(matrix_multiply(C,I)[1][2])<2.01 and abs(matrix_multiply(A,I)[1][1])<2.01 and abs(matrix_multiply(B,I)[1][1])<2.01 and abs(matrix_multiply(C,I)[1][1])<2.01 } ] % I can't find these trajectories for the life of me! % \appendcurve[ % ustart = {-2} % ,ustop = {2} % ,usamples = {20} % ,transformation = {T} % ,x = {u*cos(pi/4)} % ,y = {u*sin(pi/4)} % ,z = {(u*cos(pi/4))^4 + (u*sin(pi/4))^4 - 4*(u*cos(pi/4))*(u*sin(pi/4)) + 1} % ,draw options = { % draw = blue % ,ultra thin % ,line join = round % } % ] % \appendcurve[ % ustart = {-2} % ,ustop = {2} % ,usamples = {20} % ,transformation = {T} % ,x = {u*cos(3*pi/4)} % ,y = {u*sin(3*pi/4)} % ,z = {(u*cos(3*pi/4))^4 + (u*sin(3*pi/4))^4 - 4*(u*cos(3*pi/4))*(u*sin(3*pi/4)) + 1} % ,draw options = { % draw = red % ,ultra thin % ,line join = round % } % ] \appendsolid[ ustart = {-2} ,ustop = {2} ,usamples = {2} ,vstart = {-2} ,vstop = {2} ,vsamples = {2} ,wstart = {-2} ,wstop = {2} ,wsamples = {2} ,transformation = {T} ,x = {u} ,y = {v} ,z = {w} ,fill options = { preaction = { fill = none ,fill opacity = 0.5 } ,postaction = { draw = none ,ultra thin ,line join = round ,line cap = round } } ] \appendcurve[ ustart = {0} ,ustop = {4} ,usamples = {2} ,x = {0} ,y = {0} ,z = {u} ,transformation = {T} ,arrow tip = {true} ,draw options = { draw ,ultra thin ,line cap = round } ] \appendlabel[ x = {0} ,y = {0} ,z = {4.3} ,transformation = {T} ,name = {\(z\)} ] \appendcurve[ ustart = {0} ,ustop = {4} ,usamples = {2} ,x = {0} ,y = {u} ,z = {0} ,transformation = {T} ,arrow tip = {true} ,draw options = { draw ,ultra thin ,line cap = round } ] \appendlabel[ x = {0} ,y = {4.3} ,z = {0} ,transformation = {T} ,name = {\(y\)} ] \appendcurve[ ustart = {0} ,ustop = {4} ,usamples = {2} ,x = {u} ,y = {0} ,z = {0} ,transformation = {T} ,arrow tip = {true} ,draw options = { draw ,ultra thin ,line cap = round } ] \appendlabel[ x = {4.3} ,y = {0} ,z = {0} ,transformation = {T} ,name = {\(x\)} ] \displaysegments \end{tikzpicture} } \end{document}
- How do I cancel the exponent in an equation?by user424920 on November 21, 2025 at 8:54 pm
I'm trying to achieve something like this I tried \cancelto but it doesn't look good. Is there a library for these kind of "special cancellations"? Thank you all.
- extract data from excell file [closed]by Serge75013 on November 21, 2025 at 8:43 pm
Well, I tried to understand your code or your code and I also consulted the tutorial indicated by cfr, and I admit that I don't understand anything and that it will take me a little time to master this language. Since you tell me that you have to ask the questions one by one, I would like to know how to retrieve the values of a line, for example the one obtained randomly, in nine respective variables varone, vartwo etc that I can then simply exploit in different calculations of the type (varone + vartwo) mod n or any other operation without having to continue in the same language? Because there, I have searched and I am unable to recover these values.
- Typesetting a more aesthetic continued fractionby user143462 on November 21, 2025 at 7:08 pm
In the following code, the quotient $\pi/4$ is expressed as a continued fraction. There is only one modification that I would like to be made. The diagonal dots at the end of the continued fraction would look much better if they were typeset in alignment with the 2's. \documentclass{amsart} \usepackage{amsmath} \usepackage{amsfonts} \begin{document} \begin{equation*} \frac{\pi}{4} = \cfrac{1}{\ 1 + \cfrac{1^{2}}{\ 2 + \cfrac{3^{2}}{\ 2 + \cfrac{\ 5^{2}}{\ 2 + \cfrac{7^{2}}{\ 2 + \vphantom{\dfrac{9^{2}}{2}}_{\ddots}}}}}} \ . \end{equation*} \end{document}
- LaTeX: Matrix in Matrixby gefei on November 21, 2025 at 10:08 am
I created a matrix by this code \documentclass{article} \usepackage{amsmath} \begin{document} \[ A_{n+1}= \begin{pmatrix} a & \begin{tabular}{ccccc} 0 & 0 & \ldots & 0 & 0 \\ \end{tabular} & 1\\ \begin{tabular}{c} 0\\ \vdots\\ \end{tabular} & A_n & \begin{tabular}{c} 0\\ \vdots \end{tabular} \\ 1 & \begin{tabular}{ccccc} 0 & 0 & \ldots & 0 & 0 \\ \end{tabular} & a\\ \end{pmatrix} \] \end{document} But I don't like the result because the margin between the "a" and the first "0" in the first line is too large. I guess it's due to the tabular environment. Anyway to improve it?
- Command with `^^` and `__` as exponent optional argumentsby projetmbc on November 21, 2025 at 8:54 am
In the following toy example, I would like to use __ and ^^ instead of - and .. Is it possible? \documentclass[varwidth, border = 3pt]{standalone} \NewDocumentCommand{\hyperseq}{ m e_ e^ e- e. }{% $% {}% \IfValueT{#4}{_{#4}}% \IfValueT{#5}{^{#5}}% #1% \IfValueT{#2}{_{#2}}% \IfValueT{#3}{^{#3}}% $ } \begin{document} \hyperseq{u} \hyperseq{u}_{1} \hyperseq{u}_{1}^{2} \hyperseq{u}_{1}^{2}-{3} \hyperseq{u}_{1}^{2}-{3}.{4} \hyperseq{u}-{3}.{4} \end{document}
- Arrow Positioning in Tikzby itc on November 21, 2025 at 12:09 am
I am having problems with arrow positioning in my tikz diagram. Please see my MWE: \documentclass[11pt, a4paper]{article} \usepackage[top=2cm, bottom=2cm, left=2cm, right=2cm]{geometry} \usepackage{fontspec} \setmainfont{Noto Sans} \usepackage{amsmath} \usepackage{amssymb} \usepackage{bm} \usepackage{tikz} \usepackage{caption} \usepackage{graphicx} \DeclareMathOperator*{\argmin}{argmin} \DeclareMathOperator{\prctile}{prctile} \usetikzlibrary{shapes, arrows.meta, positioning, fit, backgrounds, calc, shadows} \begin{document} \begin{figure}[htbp] \centering \resizebox{0.95\textwidth}{!}{% \begin{tikzpicture}[ node distance=1.5cm and 2cm, >={Latex[width=2mm,length=2mm]}, base/.style = {draw, align=center, minimum height=3em, rounded corners, drop shadow, font=\footnotesize}, input/.style = {base, trapezium, trapezium left angle=70, trapezium right angle=110, fill=blue!10, draw=blue!40!black, minimum width=2.5cm}, process/.style = {base, rectangle, fill=orange!10, draw=orange!40!black, minimum width=3cm}, simblock/.style = {base, rectangle, fill=green!10, draw=green!40!black, minimum width=2.5cm}, decision/.style = {base, diamond, aspect=2, fill=yellow!10, draw=yellow!40!black, inner sep=1pt}, output/.style = {base, ellipse, fill=red!10, draw=red!40!black, minimum width=2.5cm, font=\footnotesize\bfseries}, group/.style = {draw, dashed, inner sep=10pt, rounded corners, fill=gray!5}, line/.style = {draw, ->, thick, color=gray!70} ] \node[input] (inputs_data) {Ggdh Jjdhds: \newline $\mathbf{Z}, \mathbf{X}, \mathbf{B}, \mathbf{M}, \mathbf{Y}, \mathbf{E}, \mathbf{Q}$}; \node[input, right=1cm of inputs_data] (inputs_params) {Dgsgshwwdd: \newline $\mathbf{J}, sx, qw, \zeta$}; \node[process, below=1.5cm of inputs_data] (calc_lambda) {Dsrwrws $\bm{C} = \mathbf{A} \mathbin{/} \mathbf{C}$ \newline where $\mathbf{C} = \text{ffee}(\mathbf{U})$}; \node[process, right=1cm of calc_lambda] (calc_sorted) {Zeehwywye Eodhyeywup \newline $\mathbf{G} \to \mathbf{A_{fhfhr}}$}; \node[process, below=1cm of calc_lambda] (calc_pcdf) {Fswuwyhs Uhwbsgx ASX \newline $\mathbf{A_{rrfh}}$ using $\bm{D}$}; \node[simblock, below left=2cm and 0.5cm of calc_pcdf] (freq_sim) {\textbf{K. Feeeffd} \newline Jsggwywhs $\mathbf{O_{wsdfq}}$ \newline $\mathbf{K} = \operatorname{argmin}\lVert \mathbf{W_{OOO}} - \mathbf{F_{ttthq}}\rVert$}; \node[simblock, right=1.5cm of freq_sim] (sev_sim) {\textbf{j. Swwywywy} \newline Yhhdhdhdd $\mathbf{R_{ddddd}}$ \newline Lirurur $\mathbf{M} \to \mathbf{X_{ssssss}}$ \newline Oqqtqtq: $\mathbf{P}$ ($n \times j$)}; \node[simblock, below=1cm of freq_sim] (calc_gul) {\textbf{C. Xcbc HJH} \newline $\mathbf{M} = \text{gghhg}(\mathbf{L})$ \newline $\mathbf{R} = \mathbf{A} \cdot\ast \mathbf{B}$}; \node[simblock, below=1cm of calc_gul] (analysis) {\textbf{D. Adjfjfjfde} \newline KKK Fcc \& Capital \newline ($\prctile(\mathbf{Z}, f)$)}; \node[process, right=2cm of sev_sim, text width=3.5cm] (spatial) {\textbf{Trixx XI: Jpoaigk (a-OU)} \newline Hshhs shuw $\mathbf{Y}$ to Judu $\mathbf{M}$ \newline Aqqtwt $\mathbf{P_6}, \mathbf{Q_9}$}; \node[output, below=1.5cm of analysis] (out_gul) {Zvxhswuus gsgsgw \newline ($\mathbf{S}$)}; \node[output, below=1.5cm of spatial] (out_maps) {Jmetial Lagz \newline}; \draw[line] (inputs_params) -- (calc_lambda); \draw[line] (inputs_data) -- (calc_lambda); \draw[line] (inputs_data) -- (calc_sorted); %EDITS%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{scope}[on background layer] \draw[-latex, line] (inputs_data) -| (spatial); \end{scope} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \draw[line] (calc_lambda) -- (calc_pcdf); \draw[line] (calc_pcdf) -- (freq_sim); \draw[line] (calc_sorted) -- (sev_sim); \draw[line] (freq_sim) -- (calc_gul); \draw[line] (sev_sim) |- (calc_gul); % T goes to calc R \draw[line] (calc_gul) -- (analysis); % Sim to Spatial \draw[line] (sev_sim) -- (spatial) node[midway, above] {$\mathbf{W}$}; % Sim to Output \draw[line] (analysis) -- (out_gul); % Spatial to Output \draw[line] (spatial) -- (out_maps); \begin{scope}[on background layer] \node[group, fit=(calc_lambda) (calc_sorted) (calc_pcdf), label=above:\textbf{Mnttigwiqagijj \& Grr-Huui}] {}; \node[group, fit=(freq_sim) (sev_sim) (calc_gul) (analysis), fill=green!5, label=above:\textbf{Mosne Zarlo Suup ($n$ ifiririririri)}] {}; \node[group, fit=(spatial), fill=orange!5, label=above:\textbf{Spatmmm Jfhfhfhfhf}] {}; \end{scope} \end{tikzpicture} } \caption{fhhhhhhhhhhhhhhhhhhhhff} \label{fig:ffhfjfjfjfjff} \end{figure} \end{document} The two problems are: Each time I try to adjust the positioning of my arrows, they end up crossing each other. Another arrow is passing through the purple shape, which is something I do not like. The arrow must be split. I have attached the output for reference. Edit Problem number 1 can be ignored. On problem 2, I have replaced the line \draw[line] (inputs_data) -| (spatial); with \begin{scope}[on background layer] \draw[-latex, line] (inputs_data) -| (spatial); \end{scope}. The remaining issue is as follows: The line will split as desired. However, the line will move from the right parallelogram to the outer dotted rectangle but the tip of the arrow (>) disappears. The arrow (->) should touch the inner solid rectangle. See the updated output.
- xelatex data from Excellby Serge75013 on November 20, 2025 at 11:56 pm
Hello I made a test file in xelatex to extract numbers from an excell file, but despite two days of effort I couldn't fix the bugs. Bug: For several orders, the last value of the extracted rows only shows the number of tens. Several other bugs must come from this first bug... I specify that I would actually like to work on a file of more than 500 lines and that the nine lines of data in my file were only for a test. I also want a command that looks for the lines where the X and Y values are simultaneously and that convert them to an usable integer. I thank in advance all those who would like to look into these problems Xelatex file : \documentclass{article} \usepackage{pgffor} \usepackage{fontspec} \usepackage{xstring} % Built-in test data (9x9) \def\mydata{ {1,2,3,4,5,6,7,8,9}, {10,11,12,13,14,15,16,17,18}, {19,20,21,22,23,24,25,26,27}, {28,29,30,31,32,33,34,35,36}, {37,38,39,40,41,42,43,44,45}, {46,47,48,49,50,51,52,53,54}, {55,56,57,58,59,60,61,62,63}, {64,65,66,67,68,69,70,71,72}, {73,74,75,76,77,78,79,80,81} } \newcounter{totalrows} \newcounter{currentindex} \newcounter{foundindex} \newcounter{startline} \newcounter{numlines} % Initialize variables \newcommand{\varone}{} \newcommand{\vartwo}{} \newcommand{\varthree}{} \newcommand{\varfour}{} \newcommand{\varfive}{} \newcommand{\varsix}{} \newcommand{\varseven}{} \newcommand{\vareight}{} \newcommand{\varnine}{} % Command to convert to number \newcommand{\ConvNb}[1]{\number\numexpr#1\relax} % Show lines from i to i+n \newcommand{\showlines}[2]{% \setcounter{startline}{#1}% \setcounter{numlines}{#2}% \setcounter{currentindex}{0}% \foreach \line in \mydata {% \stepcounter{currentindex}% \ifnum\value{currentindex}<\value{startline}\else \ifnum\value{currentindex}>\numexpr\value{startline}+\value{numlines}-1\relax \breakforeach \else \noindent Ligne \thecurrentindex: \expandafter\processlinedata\line\par \fi \fi }% } \def\processlinedata#1,#2,#3,#4,#5,#6,#7,#8,#9{% \ConvNb{#1} \ConvNb{#2} \ConvNb{#3} \ConvNb{#4} \ConvNb{#5} \ConvNb{#6} \ConvNb{#7} \ConvNb{#8} \ConvNb{#9}% } % Find line with x \newcommand{\findlinewithx}[1]{% \setcounter{foundindex}{0}% \setcounter{currentindex}{0}% \foreach \line in \mydata {% \stepcounter{currentindex}% \foreach \val in \line {% \ifnum\val=#1\relax% \setcounter{foundindex}{\thecurrentindex}% \expandafter\storevariables\line% \breakforeach% \fi% }% \ifnum\value{foundindex}>0\breakforeach\fi% }% \ifnum\value{foundindex}>0% Line \thefoundindex\ found with #1% \else% No lines found with #1% \fi% } %% % Displays all rows containing the number x but BUG if x not found or if all rows \newcommand{\findallwithx}[1]{% \setcounter{currentindex}{0}% \foreach \line in \mydata {% \stepcounter{currentindex}% \foreach \val in \line {% \ifnum\val=#1\relax% \noindent Ligne \thecurrentindex\ contient #1: \expandafter\processlinedata\line\par% \breakforeach% \fi% }% }% } %% % Random Line Extract \newcommand{\randomline}{% \pgfmathsetmacro{\r}{int(random(0,8))}% \setcounter{currentindex}{0}% \foreach \line in \mydata {% \ifnum\value{currentindex}=\r% \expandafter\storevariables\line% Random line \the\numexpr\r+1\relax% \breakforeach% \fi% \stepcounter{currentindex}% }% } %%%%%%%%%%%%%% % Find a random line containing x AND y \newcommand{\findrandomwithxy}[2]{% \def\xfound{0}% \def\yfound{0}% \pgfmathsetmacro{\r}{int(random(0,8))}% \setcounter{currentindex}{0}% \foreach \line in \mydata {% \stepcounter{currentindex}% \ifnum\value{currentindex}=\r% \foreach \val in \line {% \ifnum\val=#1\relax\def\xfound{1}\fi% \ifnum\val=#2\relax\def\yfound{1}\fi% }% \ifnum\xfound=1\relax% \ifnum\yfound=1\relax% \expandafter\storevariables\line% Random line \the\numexpr\r+1\relax\ containing #1 AND #2: \expandafter\processlinedata\line\par% \breakforeach% \else% % Relaunch the search if not y \findrandomwithxy{#1}{#2}% \fi% \else% % Relaunch the search if not x \findrandomwithxy{#1}{#2}% \fi% \fi% }% } %%%%% % 1. Count the total number of rows containing x \newcounter{xcount} \newcommand{\countlineswithx}[1]{% \setcounter{xcount}{0}% \setcounter{currentindex}{0}% \foreach \line in \mydata {% \stepcounter{currentindex}% \edef\temp{\line}% \expandafter\checkforxcount\temp\relax{#1}% }% \noindent Total number of rows containing #1: \thexcount\par } %%%% % Command to store variables \def\storevariables#1,#2,#3,#4,#5,#6,#7,#8,#9{% \gdef\varone{#1}% \gdef\vartwo{#2}% \gdef\varthree{#3}% \gdef\varfour{#4}% \gdef\varfive{#5}% \gdef\varsix{#6}% \gdef\varseven{#7}% \gdef\vareight{#8}% \gdef\varnine{#9}% } % Control with number conversion \newcommand{\cmdbidon}[9]{% \textbf{\ConvNb{#1}} \textbf{\ConvNb{#2}} \textbf{\ConvNb{#3}} \textbf{\ConvNb{#4}} \textbf{\ConvNb{#5}} \textbf{\ConvNb{#6}} \textbf{\ConvNb{#7}} \textbf{\ConvNb{#8}} \textbf{\ConvNb{#9}}% } % Command to simulate encryption operations \newcommand{\cryptoperation}{% \def\a{\ConvNb{\varone}}% \def\b{\ConvNb{\vartwo}}% \def\c{\ConvNb{\varthree}}% \def\d{\ConvNb{\varfour}}% \def\e{\ConvNb{\varfive}}% \def\f{\ConvNb{\varsix}}% \def\g{\ConvNb{\varseven}}% \def\h{\ConvNb{\vareight}}% \def\i{\ConvNb{\varnine}}% % % Example of an encryption operation Résult: $\a + \b + \c + \d + \e + \f + \g + \h + \i = \number\numexpr\a+\b+\c+\d+\e+\f+\g+\h+\i\relax$% } \begin{document} \section*{Displaying Lines 1 to 9} \showlines{1}{9} \section*{Line with specific number} \findlinewithx{5} % Triggers bug for NB not found or if adding a line \noindent Variables: \cmdbidon{\varone}{\vartwo}{\varthree}{\varfour}{\varfive}{\varsix}{\varseven}{\vareight}{\varnine} \section*{Ligne aléatoire}%bug: for the last value only displays the number of tens \randomline \noindent Variables: \cmdbidon{\varone}{\vartwo}{\varthree}{\varfour}{\varfive}{\varsix}{\varseven}{\vareight}{\varnine} \section*{Encryption operation} \cryptoperation \section*{Number conversion test} Variable \texttt{\string\varone}: \varone → Conversion: Displaying Varone + Vartwo operation: $\ConvNb{\varone}+\ConvNb{\vartwo}$ varone + vartwo: avec number numexpr $\ConvNb{\number\numexpr\varone}+\ConvNb{\number\numexpr\vartwo}$ \def\mm{$\ConvNb{\number\numexpr\varsix}*\ConvNb{\vartwo}$} \mm \section*{All rows containing 5} \findallwithx{5} %BUG but still displays the result but for the last value only displays the number of tens \cryptoperation \texttt{\varfour} \section*{Random line with 42 AND 45} \findrandomwithxy{42}{45}% affichage rien \section*{Robust random line with 42 AND 45} \findrandomwithxyrobust{42}{45} % BUG \end{document}