TransWikia.com

How can I install SNEG Library package on Windows?

Mathematica Asked by Rosetta on May 31, 2021

I want to save my time doing second quantization calculation, so I tried to install SNEG package. (http://nrgljubljana.ijs.si/sneg/)

But in the website I only founnd ways to install the package on MacOS or Linux. Is the package available to Windows users? How can I install it?

Thanks in advance.

One Answer

Although, it seems like the question has been addressed in comments, it may be useful to clarify the subject in general. The command Get["http://nrgljubljana.ijs.si/sneg/sneg.m"] does not install the package, it simply loads the package into the Mathematica session from the Web. This does not allow one using it offline.

Installation on Windows

Step-by-step manually

  1. Download sneg-1.250.tar.gz archive from http://nrgljubljana.ijs.si/sneg/sneg-1.250.tar.gz
  2. Extract files from sneg-1.250.tar.gz archive into a folder using, for example, 7zip. The produced folder will contain sneg-1.250.tar archive.
  3. Extract files from sneg-1.250.tar into a folder again. This time, the produced folder, say sneg-1.250, will contain files and folders of the sneg library.
  4. Open any Mathematica notebook and evaluate SystemOpen[FileNameJoin[{$BaseDirectory, "Applications"}]] (if you want to install package for all users of the PC) or SystemOpen[FileNameJoin[{$BaseDirectory, "Applications"}]] (if you want to intall the package for only one user, i.e. youself).
  5. The previous step navigates you to a standard location for all Mathematica packages. In this opened location create folder "sneg".
  6. Copy content of the extracted archive with sneg library into the created "sneg" folder in the standard location for Mathematica packages.

Note: Despite this installation the documentation will not work in Mathematica 11.0+. In Mathematica 10.0+ it works in principle, but for this you need to go to "Add-ons and Packages": Help->Wolfram Documentation->Add-ons and Packages (at the very bottom of the pop-up page). There you will find "sneg documentation". By clicking on this you will invoke Mathematica Help Browser, where you can see documentation pages.

Automated installation

As an alternative, you can try to install TBpack application that contains Sneg Library as a subcontext: https://github.com/vasilsaroka/TBpack . (Sneg Library is a part of TBpack starting from v0.4.0). In this case, an installation is simpler (it works actually for Windows/Linux/MacOS):

  • In Mathematica 11.3+:
ResourceFunction["InstallTBpack"][]
  • In Mathematica 10.0+:
CloudGet["https://www.wolframcloud.com/obj/vasil.saroka/TBpack/Services/InstallTBpack"];
InstallTBpack[]

Note: For now Sneg Library is included into TBpack without documentation. However, as usual for any function the usage message can be invoked: ?func.

Answered by vasilsaroka on May 31, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP