Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ideas for improving the SAGE tutorial #482

Closed
williamstein opened this issue Aug 23, 2007 · 7 comments
Closed

ideas for improving the SAGE tutorial #482

williamstein opened this issue Aug 23, 2007 · 7 comments

Comments

@williamstein
Copy link
Contributor

Here are some ideas from a user for improving the SAGE tutorial:

  • 2nd para of abstract: point reader to the official python tutorial for syntax issues
  • section 5 "programming": mention X? and X?? again
  • why doesn't "print?" work? "attach?"
  • why does att[tab] give me attr and not "attach"?
  • Why does "time for M in L:" break.
  • Putting cputime(t) alone by itself in the script doesn't print anything. Why? (Because you have to put "print cputime(t)")
  • In many cases using xrange instead of range can be vastly better
  • nohup sage file.sage > out& # very useful
  • even better: use screen instead of nohup - you can reconnect to the session later
  • How to change a .sage file to a .spyx file:
    1. Profile your file.sage file with %prun -- premature optimization is root of all evil
    2. Start with file.py instead of file.sage.
    3. Use "from sage.all import stuff you need" at the top
    4. Consider cdef'ing classes, cdef'ing methods, and cdef'ing variables.

CC: @sagetrac-mvngu @kcrisman

Component: documentation

Issue created by migration from https://trac.sagemath.org/ticket/482

@williamstein williamstein added this to the sage-2.9 milestone Aug 23, 2007
@williamstein williamstein self-assigned this Aug 23, 2007
@sagetrac-mabshoff sagetrac-mabshoff mannequin changed the title ideals for improving the SAGE tutorial ideas for improving the SAGE tutorial Aug 23, 2007
@williamstein williamstein modified the milestones: sage-2.9, sage-2.8.4 Aug 31, 2007
@sagetrac-mabshoff

This comment has been minimized.

@williamstein williamstein modified the milestones: sage-2.8.4, sage-2.9 Sep 7, 2007
@sagetrac-mabshoff
Copy link
Mannequin

sagetrac-mabshoff mannequin commented Sep 26, 2008

comment:5

Unless somebody thinks that anything here is still usefull I will close this ticket in the near future.

Cheers,

Mihcaek

@aghitza
Copy link

aghitza commented Sep 27, 2008

comment:6

Some comments, based on 3.1.3.alpha1:

  • attach? does work (so fixed)
  • print? does not work (so still an issue)
  • att[tab] gives attach, not attr (so fixed)
  • the following works when written on one line:
sage: time for i in range(10000): a = i^2
CPU times: user 0.02 s, sys: 0.00 s, total: 0.02 s
Wall time: 0.02 s
  • however, I cannot see how to make it work with a for loop spread over several lines

Several of the other suggestions seem more appropriate for the FAQ (on the wiki) than for the tutorial (e.g. the cputime issue, the "use screen instead of nohup"). I think it is a good idea to mention screen somewhere in the tutorial, as well as a section about converting from .sage to .spyx. I am happy to write a small paragraph about the former, but I'm not the right person for the latter.

I've opened #4204 regarding screen, and someone who agrees that the "sage 2 spyx" section should exist should open a ticket for that. Maybe there should also be a ticket for "print?". Then we can close this ancient and somewhat vague ticket.

@sagetrac-mabshoff
Copy link
Mannequin

sagetrac-mabshoff mannequin commented Sep 27, 2008

comment:7

Replying to @aghitza:

Someone who agrees that the "sage 2 spyx" section should exist should open a ticket for that.

Isn't that covered by Cython already? What exactly would the goal of that section be?

Maybe there should also be a ticket for "print?". Then we can close this ancient and somewhat vague ticket.

Well, that is really a Python issue. I do not recall it ever coming up.

Cheers,

Michael

@sagetrac-mvngu
Copy link
Mannequin

sagetrac-mvngu mannequin commented Jun 27, 2009

comment:8

CC'ing myself.

@jdemeyer jdemeyer modified the milestones: sage-5.11, sage-5.12 Aug 13, 2013
@sagetrac-vbraun-spam sagetrac-vbraun-spam mannequin modified the milestones: sage-6.1, sage-6.2 Jan 30, 2014
@sagetrac-vbraun-spam sagetrac-vbraun-spam mannequin modified the milestones: sage-6.2, sage-6.3 May 6, 2014
@sagetrac-vbraun-spam sagetrac-vbraun-spam mannequin modified the milestones: sage-6.3, sage-6.4 Aug 10, 2014
@mezzarobba
Copy link
Member

comment:14

See also #9790.

@mkoeppe mkoeppe removed this from the sage-6.4 milestone Dec 29, 2022
@jhpalmieri
Copy link
Member

I propose that we close this. Tickets can be opened for more targeted changes to the tutorial, rather than the mostly outdated laundry list here.

@mkoeppe mkoeppe closed this as not planned Won't fix, can't repro, duplicate, stale Jul 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants