# Org latex exports $…$ math as $$…$$ : can this be avoided?

As the title says, inline math snippets such as $x+1$ are replaced during org latex export by $$x+1$$. But, no one is writing inline math in LaTex files like this. Is there a way to tell Org to leave my dollars alone?

Context: the LaTeX file is collaborative and people are simply not used to $$...$$ syntax.

## 2 Answers

You can hack away a fix by executing the following after loading ox-latex:

(defun org-latex-math-block (_math-block contents _info)
"Transcode a MATH-BLOCK object from Org to LaTeX.
CONTENTS is a string.  INFO is a plist used as a communication
channel."
(when (org-string-nw-p contents)
(format "$%s$" (org-trim contents))))


This means every LaTeX export, for all of your files, will use  instead of \( ). More portable solutions would define a new derived backend.

For instructions, see: https://orgmode.org/manual/Advanced-Export-Configuration.html

Either @@latex:$x+1$@@ or src_latex{$x+1$} should work.