From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Schulte Subject: Re: imaxima babel Date: Sat, 23 Nov 2013 09:12:29 -0700 Message-ID: <87a9gvgk7l.fsf@gmail.com> References: <87li0htl9g.fsf@gmx.co.uk> <35517207.uS1ReSrXEG@descartes> <87ppptjd0s.fsf@gmail.com> <878uwgtlhq.fsf@gmx.co.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60213) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VkG1P-00026u-GP for emacs-orgmode@gnu.org; Sat, 23 Nov 2013 11:25:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VkG1I-0005uF-03 for emacs-orgmode@gnu.org; Sat, 23 Nov 2013 11:25:27 -0500 Received: from mail-pb0-x22f.google.com ([2607:f8b0:400e:c01::22f]:39728) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VkG1H-0005u6-Ps for emacs-orgmode@gnu.org; Sat, 23 Nov 2013 11:25:19 -0500 Received: by mail-pb0-f47.google.com with SMTP id um1so2899455pbc.6 for ; Sat, 23 Nov 2013 08:25:18 -0800 (PST) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: yggdrasil@gmx.co.uk Cc: =?utf-8?Q?R=C3=BCdiger?= Sonderfeld , emacs-orgmode@gnu.org writes: > Thanks, this does answer my initial question and works good enough to > enable latex export!=20 > > Even better would be if it's possible to mimic imaxima behaviour which > is (I think) to directly process the resulting latex code and > (temporarily?) store it as an image to display the pretty-printed > equations directly inline in the org-buffer (which will make it export > as html better I guess as the latex output doesn't seem to be recognised > when exporting to html). > You would switch from ":results latex" to ":results raw", in which case the latex will be inserted directly into the Org-mode buffer, and org-mode's existing pretty display functionality may be used to view the equations inline and should work for export to HTML as well. Alternately, if you really want to get fancy you could use noweb expansion (see the manual) to insert the results of the imaxima code block into a latex code block, and then use the existing latex code block functionality to convert the imaxima output to images of different types depending on the export target [1]. Best, > > All the best, > > Johnny > > Eric Schulte writes: > >> Changing ":results output" to ":results output latex" in R=C3=BCdiger's = nice >> example below would probably be an improvement. >> >> Best, >> >> R=C3=BCdiger Sonderfeld writes: >> >>> TeX output is a feature of Maxima. See >>> (info "(maxima) Functions and Variables for TeX Output") >>> >>> E.g. >>> >>> #+name: solve-maxima >>> #+header: :exports results >>> #+begin_src maxima :results output >>> tex(exp(-x)/x); >>> #+end_src >>> #+RESULTS: solve-maxima >>> : $${{e^ {- x }}\over{x}}$$ >>> >>> >>> On Thursday 21 November 2013 23:58:35 yggdrasil@gmx.co.uk wrote: >>>> Hi, >>>>=20 >>>> Is there a way to evaluate imaxima source code in org-mode to display >>>> the latex output inline in the org-buffer? I have found in [1] how to >>>> evaluate maxima code, but I don't understand if and how to adopt it to >>>> get the nice latex/pdf output. Any pointers appreciated, or just wheth= er >>>> it is possible or not. >>>>=20 >>>>=20 >>>> I am running emacs 24.3.1 with org mode 7.9.3f. >>>>=20 >>>> Thanks, >>>>=20 >>>> Johnny >>>>=20 >>>> Footnotes: >>>> [1] http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-maxima= .html >>> >>> Footnotes:=20 [1] http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-LaTeX.html#= sec-4-3 --=20 Eric Schulte https://cs.unm.edu/~eschulte PGP: 0x614CA05D