* plus in superscript. @ 2011-09-14 16:32 Piter_ 2011-09-14 16:55 ` Nick Dokos 0 siblings, 1 reply; 9+ messages in thread From: Piter_ @ 2011-09-14 16:32 UTC (permalink / raw) To: emacs-orgmode Hi all. I try to put a superscript in org-mode in this way: T^{+}. But it gets exported in latex as $^{\st{}$. Any idea how to avoid it? Thanks. ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: plus in superscript. 2011-09-14 16:32 plus in superscript Piter_ @ 2011-09-14 16:55 ` Nick Dokos 2011-09-14 17:21 ` Christian Moe 2011-09-14 22:29 ` suvayu ali 0 siblings, 2 replies; 9+ messages in thread From: Nick Dokos @ 2011-09-14 16:55 UTC (permalink / raw) To: Piter_; +Cc: nicholas.dokos, emacs-orgmode Piter_ <x.piter@gmail.com> wrote: > Hi all. I try to put a superscript in org-mode in this way: T^{+}. But > it gets exported in latex as $^{\st{}$. Any idea how to avoid it? > Thanks. > {Super,sub}scripts are latex math constructs - try the following: --8<---------------cut here---------------start------------->8--- * This is a test: \(T^{+}\) And inline: \(T^{+}\) and displayed: \[T^{+}\] --8<---------------cut here---------------end--------------->8--- Nick ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: plus in superscript. 2011-09-14 16:55 ` Nick Dokos @ 2011-09-14 17:21 ` Christian Moe 2011-09-14 17:28 ` Nick Dokos 2011-09-14 22:29 ` suvayu ali 1 sibling, 1 reply; 9+ messages in thread From: Christian Moe @ 2011-09-14 17:21 UTC (permalink / raw) To: nicholas.dokos; +Cc: emacs-orgmode, Piter_ But latex subscripts/superscripts should work in Org even without an explicit math environment, and they do for me -- exporting Piter's T^{+} gives me T$^{+}$ as expected. Something in his setup? Yours, Christian On 9/14/11 6:55 PM, Nick Dokos wrote: > Piter_<x.piter@gmail.com> wrote: > >> Hi all. I try to put a superscript in org-mode in this way: T^{+}. But >> it gets exported in latex as $^{\st{}$. Any idea how to avoid it? >> Thanks. >> > > {Super,sub}scripts are latex math constructs - try the following: > > --8<---------------cut here---------------start------------->8--- > * This is a test: \(T^{+}\) > > And inline: \(T^{+}\) and displayed: \[T^{+}\] > --8<---------------cut here---------------end--------------->8--- > > Nick > > ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: plus in superscript. 2011-09-14 17:21 ` Christian Moe @ 2011-09-14 17:28 ` Nick Dokos 0 siblings, 0 replies; 9+ messages in thread From: Nick Dokos @ 2011-09-14 17:28 UTC (permalink / raw) To: mail; +Cc: nicholas.dokos, emacs-orgmode, Piter_ Christian Moe <mail@christianmoe.com> wrote: > But latex subscripts/superscripts should work in Org even without an > explicit math environment, and they do for me -- exporting Piter's > T^{+} gives me > > T$^{+}$ > > as expected. Something in his setup? > You are right - sorry about the noise. Nick ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: plus in superscript. 2011-09-14 16:55 ` Nick Dokos 2011-09-14 17:21 ` Christian Moe @ 2011-09-14 22:29 ` suvayu ali 2011-09-15 7:19 ` Nick Dokos 1 sibling, 1 reply; 9+ messages in thread From: suvayu ali @ 2011-09-14 22:29 UTC (permalink / raw) To: nicholas.dokos; +Cc: emacs-orgmode, Piter_ Hi Nick, On Wed, Sep 14, 2011 at 6:55 PM, Nick Dokos <nicholas.dokos@hp.com> wrote: > * This is a test: \(T^{+}\) Apart from what Christian said, do you have any comments about $..$ and \(..\) ? I hear conflicting arguments about which is preferred (e.g. $..$ is a TeX construct where as \(..\) is a LaTeX macro arguing in favour of $..$). Specially an opinion in the context of org -> latex export would be interesting to hear. -- Suvayu Open source is the future. It sets us free. ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: plus in superscript. 2011-09-14 22:29 ` suvayu ali @ 2011-09-15 7:19 ` Nick Dokos 2011-09-15 7:43 ` Christian Moe 0 siblings, 1 reply; 9+ messages in thread From: Nick Dokos @ 2011-09-15 7:19 UTC (permalink / raw) To: suvayu ali; +Cc: nicholas.dokos, emacs-orgmode, Piter_ suvayu ali <fatkasuvayu+linux@gmail.com> wrote: > Hi Nick, > > On Wed, Sep 14, 2011 at 6:55 PM, Nick Dokos <nicholas.dokos@hp.com> wrote: > > * This is a test: \(T^{+}\) > > Apart from what Christian said, do you have any comments about $..$ > and \(..\) ? I hear conflicting arguments about which is preferred > (e.g. $..$ is a TeX construct where as \(..\) is a LaTeX macro arguing > in favour of $..$). Specially an opinion in the context of org -> > latex export would be interesting to hear. > As far as LaTeX is concerned, I believe that $...$ and \(...\) are entirely equivalent (but you have to use \[...\], and not $$...$$ for displayed material). That's from reading Lamport's book: sec 3.3 and Appendix E (the "Miscellaneous" section); I have not checked the code. I prefer \(...\) and (iirc) sometimes that has worked when $...$ has not, but I don't remember the context; afaik those (rare) situations were deemed to be bugs in the exporter and have all been fixed. Nick ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: plus in superscript. 2011-09-15 7:19 ` Nick Dokos @ 2011-09-15 7:43 ` Christian Moe 2011-09-15 7:44 ` Carsten Dominik 0 siblings, 1 reply; 9+ messages in thread From: Christian Moe @ 2011-09-15 7:43 UTC (permalink / raw) To: nicholas.dokos; +Cc: emacs-orgmode, Piter_ Hi, $...$ may sometimes get confused with currency signs, variable names and whatnot. Org-mode is sophisticated about it as long as you follow a few safeguards -- from the Info section 11.7.3: To avoid conflicts with currency specifications, single `$' characters are only recognized as math delimiters if the enclosed text contains at most two line breaks, is directly attached to the `$' characters with no whitespace in between, and if the closing `$' is followed by whitespace, punctuation or a dash. For the other delimiters, there is no such restriction, so when in doubt, use `\(...\)' as inline math delimiters. But note that MathJax, the preferred backend for math in Org's HTML exports, does not support $...$ by default. To configure it, see: http://www.mathjax.org/docs/1.1/tex.html#tex-and-latex-math-delimiters Yours, Christian On 9/15/11 9:19 AM, Nick Dokos wrote: > suvayu ali<fatkasuvayu+linux@gmail.com> wrote: > >> Hi Nick, >> >> On Wed, Sep 14, 2011 at 6:55 PM, Nick Dokos<nicholas.dokos@hp.com> wrote: >>> * This is a test: \(T^{+}\) >> >> Apart from what Christian said, do you have any comments about $..$ >> and \(..\) ? I hear conflicting arguments about which is preferred >> (e.g. $..$ is a TeX construct where as \(..\) is a LaTeX macro arguing >> in favour of $..$). Specially an opinion in the context of org -> >> latex export would be interesting to hear. >> > > As far as LaTeX is concerned, I believe that $...$ and \(...\) are > entirely equivalent (but you have to use \[...\], and not $$...$$ for > displayed material). That's from reading Lamport's book: sec 3.3 and > Appendix E (the "Miscellaneous" section); I have not checked the code. > > I prefer \(...\) and (iirc) sometimes that has worked when $...$ has > not, but I don't remember the context; afaik those (rare) situations > were deemed to be bugs in the exporter and have all been fixed. > > Nick > > > ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: plus in superscript. 2011-09-15 7:43 ` Christian Moe @ 2011-09-15 7:44 ` Carsten Dominik 2011-09-15 8:23 ` Christian Moe 0 siblings, 1 reply; 9+ messages in thread From: Carsten Dominik @ 2011-09-15 7:44 UTC (permalink / raw) To: mail; +Cc: nicholas.dokos, emacs-orgmode, Piter_ On Sep 15, 2011, at 9:43 AM, Christian Moe wrote: > Hi, > > $...$ may sometimes get confused with currency signs, variable names and whatnot. > > Org-mode is sophisticated about it as long as you follow a few safeguards -- from the Info section 11.7.3: > > To avoid conflicts > with currency specifications, single `$' characters are only > recognized as math delimiters if the enclosed text contains at > most two line breaks, is directly attached to the `$' characters > with no whitespace in between, and if the closing `$' is followed > by whitespace, punctuation or a dash. For the other delimiters, > there is no such restriction, so when in doubt, use `\(...\)' as > inline math delimiters. > > But note that MathJax, the preferred backend for math in Org's HTML exports, does not support $...$ by default. To configure it, see: > > http://www.mathjax.org/docs/1.1/tex.html#tex-and-latex-math-delimiters When Org exports to HTML for use with MathJax, it does convert $..$ to \(..\) to work around this. Still, parsing $...$ is much harder than parsing \(..\), so most of the time, using \(//\) will give better and more stable results with Org-mode. - Carsten ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: plus in superscript. 2011-09-15 7:44 ` Carsten Dominik @ 2011-09-15 8:23 ` Christian Moe 0 siblings, 0 replies; 9+ messages in thread From: Christian Moe @ 2011-09-15 8:23 UTC (permalink / raw) To: Carsten Dominik; +Cc: nicholas.dokos, emacs-orgmode, Piter_ On 9/15/11 9:44 AM, Carsten Dominik wrote: > When Org exports to HTML for use with MathJax, it does convert $..$ to \(..\) to work around this. Oops, I should have guessed. I just remembered having to fiddle with my MathJax configuration at one point, but that was probably before Org even switched from dvipng to MathJax as default. > Still, parsing $...$ is much harder than parsing \(..\), so most of the time, using \(//\) will give better and more stable results with Org-mode. And a good deal more readable. Christian ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2011-09-15 8:22 UTC | newest] Thread overview: 9+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2011-09-14 16:32 plus in superscript Piter_ 2011-09-14 16:55 ` Nick Dokos 2011-09-14 17:21 ` Christian Moe 2011-09-14 17:28 ` Nick Dokos 2011-09-14 22:29 ` suvayu ali 2011-09-15 7:19 ` Nick Dokos 2011-09-15 7:43 ` Christian Moe 2011-09-15 7:44 ` Carsten Dominik 2011-09-15 8:23 ` Christian Moe
Code repositories for project(s) associated with this public inbox https://git.savannah.gnu.org/cgit/emacs/org-mode.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).