Ask Your Question
0

Sagetex and windows 7?

asked 2012-05-30 13:28:58 +0200

I have sage 5.0 successfully installed on my Windows 7 64 bit machine using Oracle's VM VirtualBox. However, I would like to use sagetex in my LyX 2.0 and TeXworks 0.4.3 editors. How can I accomplish this?

edit retag flag offensive close merge delete

Comments

I second this, but I have no idea how difficult it would be to implement it.

daniel.e2718 gravatar imagedaniel.e2718 ( 2012-05-31 01:42:58 +0200 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2012-06-14 12:03:20 +0200

@daniel.e2718, it is actually easy to implement. Sage 5.0 comes with sagetex installed. You can verify this by typing at the sage command prompt sage -i | more to view a list of installed packages. You will see sagetex-2.3.3.p2. This means all you have to do is share the windows folder that is your tex working directory. You do this by going to Oracle VM VirtualBox Manager, selecting the Machine->Settings menu path and finally selecting Shared Folders on the left navigation pad. Finally, as The SageTEX package pdf manual states,

To copy the fi les that LATEX needs into your texmf directory (your windows shared folder), simply do

cp -r $SAGE ROOT/local/share/texmf/* HOMEPREFIX/texmf/

You can test your windows tex editor with the provided example.tex now located under your shared folder:

  1. In Windows, build the example.tex file.
  2. In the sage command line process the example.sagetex.sage output file.
  3. Rerun the example.tex file under Windows and all the sage code will be processed in the pdf document.
edit flag offensive delete link more

Comments

1

So have you answered your own question? Great work! Unfortunately, I think you don't have enough karma yet to *accept* your own question :(

kcrisman gravatar imagekcrisman ( 2012-06-14 12:23:56 +0200 )edit

Okay. What do you mean by "tex working directory"? I'm not familiar with command lines at all, so I don't know if `cp -r $SAGE ROOT/local/share/texmf/* HOMEPREFIX/texmf/` needs adjustment -- i.e., do I need to change a directory? And when you say build the *.tex file, do you mean run PDFLaTeX on it or just write it up?

daniel.e2718 gravatar imagedaniel.e2718 ( 2012-06-21 00:57:21 +0200 )edit

See http://www.sagemath.org/doc/installation/sagetex.html for more information. The `$SAGE_ROOT` band so forth will indeed need adjustment, based on where you have installed Sage and where your Windows directory is (I am not quite sure what `HOMEPREFIX` is but I bet you can look it up). "Build the file" means to actually run (pdf)LaTeX on it, you are correct.

kcrisman gravatar imagekcrisman ( 2012-06-21 12:15:35 +0200 )edit

That link says `$SAGE_ROOT` is the location of my Sage installation. I have no idea how to find that out.

daniel.e2718 gravatar imagedaniel.e2718 ( 2012-06-22 20:54:45 +0200 )edit

Assuming you are at some point in the command line, where do you go to run Sage? Wherever that is, type `pwd` and it should probably end with `.../sage-x.y.z/` or something, and that would be the Sage root. Without knowing exactly how you're trying to do this, it's difficult to help; maybe opening a different question would be more helpful.

kcrisman gravatar imagekcrisman ( 2012-06-22 23:48:18 +0200 )edit

Done. (insert extra characters here to reach 10 character minimum)

daniel.e2718 gravatar imagedaniel.e2718 ( 2012-06-23 23:57:02 +0200 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2012-05-30 13:28:58 +0200

Seen: 1,115 times

Last updated: Jun 14 '12