Last active
December 11, 2015 21:18
-
-
Save taroyabuki/4660957 to your computer and use it in GitHub Desktop.
http://blog.unfindable.net/archives/5410Bug in Mathematica 8.0.4, 9.0.0, 9.0.1 for Microsoft Windows (64-bit) (December 12, 2012).To avoid this issue, you need run the following command:SetSystemOptions["CompileOptions" -> {"TableCompileLength Infinity}]
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
f[] := With[{p = RandomVariate[NormalDistribution[]]}, If[0 <= p, p, f[]]] | |
data = Table[f[], {249}]; (* no problem *) | |
data2 = Table[f[], {250}]; (* crash! *) | |
g[] := With[{p = RandomVariate[BinomialDistribution[10, 1/10]]}, If[0 <= p, p, g[]]] | |
data = Table[g[], {249}]; (* no problem *) | |
data2 = Table[g[], {250}]; (* crash! *) | |
h = With[{p = RandomVariate[NormalDistribution[]]}, If[0 <= p, p, h[]]] &; | |
data2 = Table[h[], {250}]; (* no problem *) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment