2020-02-17 01:04:35 +0200 | received badge | ● Famous Question (source) |
2019-07-14 00:20:02 +0200 | received badge | ● Notable Question (source) |
2019-07-14 00:20:02 +0200 | received badge | ● Popular Question (source) |
2019-03-13 15:31:14 +0200 | received badge | ● Famous Question (source) |
2018-02-03 19:28:10 +0200 | asked a question | Uniform random choice of integer I want to perform some statistical sampling and to do this I need to uniformly randomly choose an integer from [0, N) where $N \approx 10^{50}$. It appears that there are several plausible ways to do this in Sage: 1) randint(0, N-1) However, the standard Python random library appears to have some non-uniformity, for example see this ticket. 2) import numpy; numpy.random.randint(0, N) However, since N is so large, this raises 3) ZZ.random_element(0, N)
|
2016-11-21 15:16:22 +0200 | received badge | ● Student (source) |
2016-11-21 15:15:27 +0200 | received badge | ● Notable Question (source) |
2016-11-21 15:15:27 +0200 | received badge | ● Popular Question (source) |
2015-09-16 23:22:37 +0200 | received badge | ● Scholar (source) |
2015-09-16 21:48:17 +0200 | received badge | ● Editor (source) |
2015-09-16 21:47:01 +0200 | asked a question | load a graph from a dot file Sage allows me to get the representation of a Graph, G, in the dot language by using the method I can even have this string written directly to a file by using: Is there a way of reloading G from such a file? I tried doing
Where the contents of 'my_graph_file.dot' are:
But none of these worked. |