SageMath on Microsoft Windows

802 views
Skip to first unread message

G. M.-S.

unread,
Feb 27, 2022, 9:04:59 AM2/27/22
to sage-s...@googlegroups.com

What is the recommended way to install SageMath on Microsoft Windows?

In
it says to go to
where I only see
SageMath 9.3 (Windows installer 0.6.3)

Guillermo

slelievre

unread,
Feb 27, 2022, 9:28:48 AM2/27/22
to sage-support
The Cygwin-based Sage-Windows installer has not been released
for SageMath 9.4 or SageMath 9.5 yet.

To get the latest version of Sage running on Windows, one option
is to activate Windows Subsystem for Linux (also known as WSL),
select WSL2, and install any Linux distribution there, then follow
the Linux installation guide.

G. M.-S.

unread,
Feb 27, 2022, 9:37:03 AM2/27/22
to sage-s...@googlegroups.com

Thanks, Samuel.

I think it is a pity there is nothing more straightforward…

But you will tell me (to look for somebody) to do it.

Guillermo

Dima Pasechnik

unread,
Feb 27, 2022, 10:05:58 AM2/27/22
to sage-support


On Sun, 27 Feb 2022, 14:37 G. M.-S., <list...@gmail.com> wrote:

Thanks, Samuel.

I think it is a pity there is nothing more straightforward…

But you will tell me (to look for somebody) to do it.

some Linux distributions have pretty much up to date Sage binary packages.

E.g. archlinux has Sage 9.5. Thus, having it installed as WSL2 (cf https://gist.github.com/ld100/3376435a4bb62ca0906b0cff9de4f94b)   should be getting you Sage 9.5 quite quickly.



Guillermo

On Sun, 27 Feb 2022 at 15:28, slelievre <samuel....@gmail.com> wrote:
The Cygwin-based Sage-Windows installer has not been released
for SageMath 9.4 or SageMath 9.5 yet.

To get the latest version of Sage running on Windows, one option
is to activate Windows Subsystem for Linux (also known as WSL),
select WSL2, and install any Linux distribution there, then follow
the Linux installation guide.
 

--
You received this message because you are subscribed to the Google Groups "sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sage-support...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sage-support/CANnG188whX6fJTbj1qdPvB-rdeNVm3H_mNmpC3mohE%2B7tM9rMw%40mail.gmail.com.

G. M.-S.

unread,
Feb 27, 2022, 12:12:49 PM2/27/22
to sage-s...@googlegroups.com

Thanks Dima.

However, this is for students to get SageMath on their PCs working quickly, so I think we will install SageMath 9.3 for the time being (they are not very savvy).

Guillermo

Fernando Gouvea

unread,
Feb 27, 2022, 1:11:40 PM2/27/22
to sage-s...@googlegroups.com
I don’t see archlinux in the Microsoft store.

Fernando

--
==================================================================
Fernando Q. Gouvea                                         
Dept of Mathematics and Statistics                     http://www.colby.edu/~fqgouvea
Colby College                                                   
Mayflower Hill 5836              
Waterville, ME 04901         

A training in mathematics is a prerequisite today for work in almost
any scientific field, but even for those who are not going to become
scientists, it is essential because, if it is only through speech that
we can understand what freedom means, only through mathematics
can we understand what necessity means.
  -- W. H. Auden


Matthias Koeppe

unread,
Feb 27, 2022, 3:46:44 PM2/27/22
to sage-support
+1 on adding info on how to install Linux distributions with up-to-date binary packages of Sage to our installation guide. See https://trac.sagemath.org/ticket/31485

(The updated installation guide, preview at https://6212659123a9467b3cb0cd07--sagemath-tobias.netlify.app/installation/index.html already covers WSL but does not mention specific distributions.)

Fernando Gouvea

unread,
Feb 27, 2022, 4:59:32 PM2/27/22
to sage-s...@googlegroups.com

I was trying to install SageMath using WSL, mostly to learn how it is done. Alas, the latest available Ubuntu distribution for WSL seems to be 20.04, which comes with SageMath 9.0. I have 9.2 running on Windows, so no advantage to that.

I did find Ubuntu 20.04 binaries for SageMath 9.4 in http://mirrors.mit.edu/sage/linux/64bit/index.html. I downloaded and unpacked without problems, at which time the instructions say to switch to the SageMath directory and type ./sage. That gives an error:

/usr/bin/env: ‘python’: No such file or directory
Error running the script 'relocate-once.py'.

Now what?

Fernando

To view this discussion on the web visit https://groups.google.com/d/msgid/sage-support/c5091c41-9776-4efe-9c6f-321217ed62d0n%40googlegroups.com.
-- 
=============================================================
Fernando Q. Gouvea         http://www.colby.edu/~fqgouvea
Carter Professor of Mathematics
Dept. of Mathematics
Colby College              
5836 Mayflower Hill        
Waterville, ME 04901       

The reason I never liked being called Professor is that it is
synonymous with academic, a word that over the past forty years has
become synonymous with ridiculous.
  -- Joseph Epstein, in "Don't Call Me Ishmael"

Henri Girard

unread,
Feb 27, 2022, 5:11:04 PM2/27/22
to sage-s...@googlegroups.com

Well... A little hacking if I dare say :)

Install wls2 with ubuntu 20.04 then install gwls2 with microsoft store verify it's working (it should) and then do-release-upgrade and it should install a kind of 22.04. I got it working with sagemath-9.4 (i don't know why it' not sage 9.5 as I have it working on a dual boot with ubuntu .

Why I do this ? because I have windows 11 and many softs like anaconda sage-math windows but yet I didn't success to install wolfram engine on windows but in gwls2 jupyter notebook mathematica works well only few backdraw but only cosmetic.

It's not too difficult but it needs patience because it can be tricky, but the result is good with mate-desktop I use. I even compiled amber20, sagemath but needs time.

Best

Henri

Dima Pasechnik

unread,
Feb 27, 2022, 5:57:19 PM2/27/22
to sage-support
On Sun, Feb 27, 2022 at 9:59 PM Fernando Gouvea <fqgo...@colby.edu> wrote:
>
> I was trying to install SageMath using WSL, mostly to learn how it is done. Alas, the latest available Ubuntu distribution for WSL seems to be 20.04, which comes with SageMath 9.0. I have 9.2 running on Windows, so no advantage to that.
>
> I did find Ubuntu 20.04 binaries for SageMath 9.4 in http://mirrors.mit.edu/sage/linux/64bit/index.html. I downloaded and unpacked without problems, at which time the instructions say to switch to the SageMath directory and type ./sage. That gives an error:
>
> /usr/bin/env: ‘python’: No such file or directory
> Error running the script 'relocate-once.py'.
>
> Now what?

Do you have Python installed on that Ununtu 20.04 ? Yes, you need it
to run the installer
(which could be more user-friendly)

Actually, probably the easiest is to use Conda installer, and not one
of these Sage binaries:
https://doc.sagemath.org/html/en/installation/conda.html#sec-installation-conda
> To view this discussion on the web visit https://groups.google.com/d/msgid/sage-support/b17e9093-7ae2-5521-7139-d66e3e2a3d24%40colby.edu.

Fernando Gouvea

unread,
Feb 27, 2022, 6:21:34 PM2/27/22
to sage-s...@googlegroups.com
Ubuntu includes python3, but not python without a number. I guess I could make a symlink?

Fernando

Dima Pasechnik

unread,
Feb 27, 2022, 6:26:35 PM2/27/22
to sage-support
On Sun, Feb 27, 2022 at 11:21 PM Fernando Gouvea <fqgo...@colby.edu> wrote:
>
> Ubuntu includes python3, but not python without a number. I guess I could make a symlink?

yes, this will solve this problem.

I presume the installer comes from Python2 times, where there was
always python available,
(python2, normally speaking)
> To view this discussion on the web visit https://groups.google.com/d/msgid/sage-support/CAPON7s_szVb_NSm__-L5CQY-%2BhnDvsOYf7zJdWguhTEdp5RVJA%40mail.gmail.com.

Eric Gourgoulhon

unread,
Feb 28, 2022, 3:01:29 AM2/28/22
to sage-support
Le lundi 28 février 2022 à 00:26:35 UTC+1, dim...@gmail.com a écrit :
On Sun, Feb 27, 2022 at 11:21 PM Fernando Gouvea <fqgo...@colby.edu> wrote:
>
> Ubuntu includes python3, but not python without a number. I guess I could make a symlink?

yes, this will solve this problem.

 Alternatively, you can install the Ubuntu package python-is-python3, which makes the symlink for you.

Eric.
Reply all
Reply to author
Forward
0 new messages