From mboxrd@z Thu Jan 1 00:00:00 1970 From: Curiouslearn Subject: Re: About entering latex code in an org file Date: Fri, 10 Dec 2010 11:19:51 -0500 Message-ID: References: <83bp4thbjr.fsf@yahoo.it> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=53963 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PR5hJ-0002iM-Ky for emacs-orgmode@gnu.org; Fri, 10 Dec 2010 11:19:54 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PR5hI-00087v-0A for emacs-orgmode@gnu.org; Fri, 10 Dec 2010 11:19:53 -0500 Received: from mail-gx0-f180.google.com ([209.85.161.180]:64867) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PR5hH-00087Z-TZ for emacs-orgmode@gnu.org; Fri, 10 Dec 2010 11:19:51 -0500 Received: by gxk19 with SMTP id 19so2441425gxk.39 for ; Fri, 10 Dec 2010 08:19:51 -0800 (PST) In-Reply-To: <83bp4thbjr.fsf@yahoo.it> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Giovanni Ridolfi Cc: emacs-orgmode@gnu.org Giovannie, thanks very much for the reply. Your solution works well for latex export. Is there a way to make it work for the HTML export too? I thought MathJax would take care of converting it to appropriate html file. While \pi_g is appropriately converted, \geq is not. Also, \( \) remain in the HTML. Perhaps, I am asking for too much and please let me know if that is so. But if there is a way to write math in such a way that it is compatible with both html and latex, I would like to learn it. Thanks again. On Fri, Dec 10, 2010 at 10:50 AM, Giovanni Ridolfi wrote: > Curiouslearn writes: > >> >> I am new to both emacs and org-mode. Org-mode sounds really cool and I >> am trying to use it to make notes for a project. > > welcome! > >> =A0I have some latex >> symbols that I need to enter in the file. >> As a background: >> (1) I read in the manual that for latex code I do not need to enclose >> math inside $ $. >> (2) I have many words with "_" in the their names, so as mentioned in >> the manual, I added >> #+OPTIONS: ^:{} _:{} >> to my .org file. >> >> In fact, the my file is >> ------------------------------------------------------------------------= ----------------------------- >> #+OPTIONS: ^:{} >> #+OPTIONS: _:{} >> #+LATEX_HEADER: \setlength{\parskip}{2ex plus 0.5ex minus 0.2ex} >> #+LATEX_HEADER: \setlength{\parindent}{0in} >> >> * TODO Write an aspiration_review function >> =A0 The function should do the following: >> =A0 1. Investigates if \pi_{g} =A0\geq =A00.05 =A0and \bar{\pi} \geq =A0= ASP_LEVEL >> >> >> ** Investigate if >> >> ------------------------------------------------------------------------= ----------------------------- >> The problem is that when I export this using 'C-c C- e l' to latex, >> some parts that should be enclosed in $ $ sign are not enclosed. This >> is the relevant line copied and pasted from the exported .tex file >> >> \item Investigates if $\pi$$_\{g\}$ =A0\geq =A00.05 =A0and \bar{\pi} \ge= q >> ASP\_{}LEVEL >> >> Can someone please let me know what is happening? > > You can't have the cake and eat it. > > I suggest you to enclose LaTeX parts in \( \) (that are better handled > than $'s) and keep the option > #+OPTIONS: =A0^:{} _:{} > > =A0 =A01. Investigates if \( \pi_{g} =A0\geq \) 0.05 =A0and \(\bar{\pi} \= geq \) ASP_LEVEL > > gives: > =A0 =A0 =A0 Investigates if \( \pi_{g} =A0\geq \) 0.05 =A0and \(\bar{\pi}= \geq \) ASP\_{}LEVEL > > cheers, > Giovanni > >