ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Mon, 23 Jul 2012 11:06:44 +0200compile TeX from Sagehttps://ask.sagemath.org/question/9165/compile-tex-from-sage/Hola!
I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from *pdflatex*).
I'm trying to perfrom the final presentation part via `view` function, however, that doesn't seem to be the most convenient way (since `view` is aimed at typesetting **LaTeX** formulas of elements of a list). A lot of *hidden code* (headers, turned on math modes etc.) are really unpleasent to get around.
I'm pondering about generating an explicit `.tex` source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as `view` does it?)
ThanX in advance!
Sage 5.1
Kubuntu 12.04Fri, 20 Jul 2012 09:00:23 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/Comment by kcrisman for <p>Hola!</p>
<p>I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from <em>pdflatex</em>).</p>
<p>I'm trying to perfrom the final presentation part via <code>view</code> function, however, that doesn't seem to be the most convenient way (since <code>view</code> is aimed at typesetting <strong>LaTeX</strong> formulas of elements of a list). A lot of <em>hidden code</em> (headers, turned on math modes etc.) are really unpleasent to get around.</p>
<p>I'm pondering about generating an explicit <code>.tex</code> source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as <code>view</code> does it?)</p>
<p>ThanX in advance!</p>
<p>Sage 5.1
Kubuntu 12.04</p>
https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19375#post-id-19375Oh, I see, you mean you are making a library and trying to document it. Well, hopefully some combination of something will work.Fri, 20 Jul 2012 15:01:34 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19375#post-id-19375Comment by kcrisman for <p>Hola!</p>
<p>I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from <em>pdflatex</em>).</p>
<p>I'm trying to perfrom the final presentation part via <code>view</code> function, however, that doesn't seem to be the most convenient way (since <code>view</code> is aimed at typesetting <strong>LaTeX</strong> formulas of elements of a list). A lot of <em>hidden code</em> (headers, turned on math modes etc.) are really unpleasent to get around.</p>
<p>I'm pondering about generating an explicit <code>.tex</code> source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as <code>view</code> does it?)</p>
<p>ThanX in advance!</p>
<p>Sage 5.1
Kubuntu 12.04</p>
https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19374#post-id-19374Or maybe you should only do the final presentation as SageTeX?Fri, 20 Jul 2012 15:04:22 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19374#post-id-19374Comment by Mathemage for <p>Hola!</p>
<p>I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from <em>pdflatex</em>).</p>
<p>I'm trying to perfrom the final presentation part via <code>view</code> function, however, that doesn't seem to be the most convenient way (since <code>view</code> is aimed at typesetting <strong>LaTeX</strong> formulas of elements of a list). A lot of <em>hidden code</em> (headers, turned on math modes etc.) are really unpleasent to get around.</p>
<p>I'm pondering about generating an explicit <code>.tex</code> source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as <code>view</code> does it?)</p>
<p>ThanX in advance!</p>
<p>Sage 5.1
Kubuntu 12.04</p>
https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19376#post-id-19376I know what you mean & I did think about this way for quite a long time. But the truth is this my college project - which should be own Sage/Python library, not TeX project. Or maybe I just misunderstood the idea around SageTeX & it can processed via Python/Sage - is it somehow *"doable"*?Fri, 20 Jul 2012 14:50:57 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19376#post-id-19376Comment by Mathemage for <p>Hola!</p>
<p>I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from <em>pdflatex</em>).</p>
<p>I'm trying to perfrom the final presentation part via <code>view</code> function, however, that doesn't seem to be the most convenient way (since <code>view</code> is aimed at typesetting <strong>LaTeX</strong> formulas of elements of a list). A lot of <em>hidden code</em> (headers, turned on math modes etc.) are really unpleasent to get around.</p>
<p>I'm pondering about generating an explicit <code>.tex</code> source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as <code>view</code> does it?)</p>
<p>ThanX in advance!</p>
<p>Sage 5.1
Kubuntu 12.04</p>
https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19373#post-id-19373Yes, sth exactly like that. My task is to do some basic investigations about a given real-valued function (stationary/inflection points, intervals of monotonicity, asymptotes...) a and give out a nice dvi/pdf. Because of computational part it should stay in Sage/python code. Maybe the SageTeX is the solution (I haven't got into its depts yet) - some way to compile SageTeX's source file from Sage's command line (so that I could call it in my program)?Fri, 20 Jul 2012 15:31:04 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19373#post-id-19373Comment by kcrisman for <p>Hola!</p>
<p>I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from <em>pdflatex</em>).</p>
<p>I'm trying to perfrom the final presentation part via <code>view</code> function, however, that doesn't seem to be the most convenient way (since <code>view</code> is aimed at typesetting <strong>LaTeX</strong> formulas of elements of a list). A lot of <em>hidden code</em> (headers, turned on math modes etc.) are really unpleasent to get around.</p>
<p>I'm pondering about generating an explicit <code>.tex</code> source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as <code>view</code> does it?)</p>
<p>ThanX in advance!</p>
<p>Sage 5.1
Kubuntu 12.04</p>
https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19363#post-id-19363Well, TeX *is* a programming language, and SageTeX is just a superset thereof. Again, this is kind of vague.Mon, 23 Jul 2012 11:06:44 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19363#post-id-19363Comment by kcrisman for <p>Hola!</p>
<p>I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from <em>pdflatex</em>).</p>
<p>I'm trying to perfrom the final presentation part via <code>view</code> function, however, that doesn't seem to be the most convenient way (since <code>view</code> is aimed at typesetting <strong>LaTeX</strong> formulas of elements of a list). A lot of <em>hidden code</em> (headers, turned on math modes etc.) are really unpleasent to get around.</p>
<p>I'm pondering about generating an explicit <code>.tex</code> source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as <code>view</code> does it?)</p>
<p>ThanX in advance!</p>
<p>Sage 5.1
Kubuntu 12.04</p>
https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19378#post-id-19378Why not do it the other way around, using SageTeX? Then you could call Sage code as needed, but do all the real stuff in LaTeX. I'm not quite sure if this would help, as you are a little vague about the precise steps you'll need.Fri, 20 Jul 2012 11:37:58 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19378#post-id-19378Comment by kcrisman for <p>Hola!</p>
<p>I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from <em>pdflatex</em>).</p>
<p>I'm trying to perfrom the final presentation part via <code>view</code> function, however, that doesn't seem to be the most convenient way (since <code>view</code> is aimed at typesetting <strong>LaTeX</strong> formulas of elements of a list). A lot of <em>hidden code</em> (headers, turned on math modes etc.) are really unpleasent to get around.</p>
<p>I'm pondering about generating an explicit <code>.tex</code> source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as <code>view</code> does it?)</p>
<p>ThanX in advance!</p>
<p>Sage 5.1
Kubuntu 12.04</p>
https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19379#post-id-19379Why not do it the other way around, using SageTeX? Then you could call Sage code as needed, but do all the real stuff in LaTeX. I'm not quite sure if this would help, as you are a little vague about the precise steps youFri, 20 Jul 2012 11:37:56 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19379#post-id-19379Comment by Mathemage for <p>Hola!</p>
<p>I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from <em>pdflatex</em>).</p>
<p>I'm trying to perfrom the final presentation part via <code>view</code> function, however, that doesn't seem to be the most convenient way (since <code>view</code> is aimed at typesetting <strong>LaTeX</strong> formulas of elements of a list). A lot of <em>hidden code</em> (headers, turned on math modes etc.) are really unpleasent to get around.</p>
<p>I'm pondering about generating an explicit <code>.tex</code> source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as <code>view</code> does it?)</p>
<p>ThanX in advance!</p>
<p>Sage 5.1
Kubuntu 12.04</p>
https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19368#post-id-19368Hmm, that sounds interesting - you mean like splitting up computational and presentation part and make a *template* in (Sage)TeX with desired format? I'm just a little bit afraid if SageTeX is powerful enough. Specifically can I typeset sth conditionally (like `if` command)? Some properties of the function (*even, constant, periodic*...) would be nice to omit when they're N/A to show...Sat, 21 Jul 2012 06:36:59 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19368#post-id-19368Comment by kcrisman for <p>Hola!</p>
<p>I'm working on a program which should output the results of its computations in form of a typesetted document (ideally pdf from <em>pdflatex</em>).</p>
<p>I'm trying to perfrom the final presentation part via <code>view</code> function, however, that doesn't seem to be the most convenient way (since <code>view</code> is aimed at typesetting <strong>LaTeX</strong> formulas of elements of a list). A lot of <em>hidden code</em> (headers, turned on math modes etc.) are really unpleasent to get around.</p>
<p>I'm pondering about generating an explicit <code>.tex</code> source code file. How can I call TeX compiler from Sage? I.e. how to compile it automatically in an own program, similarly as <code>view</code> does it?)</p>
<p>ThanX in advance!</p>
<p>Sage 5.1
Kubuntu 12.04</p>
https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19372#post-id-19372I don't see why you can't use SageTeX, then. Presumably you could write a Sage file to do the heavy lifting, then do 'load myfile.sage' in SageTeX and use the new commands everywhere. People do this in R all the time, for instance, with Sweave/knitr.Fri, 20 Jul 2012 17:57:41 +0200https://ask.sagemath.org/question/9165/compile-tex-from-sage/?comment=19372#post-id-19372