24,353 reputation
13481
bio website
location
age
visits member for 2 years, 11 months
seen 6 hours ago

1d
comment Random real numbers that sum up to specific value
What is wrong with: n = 5; numbers = RandomReal[{0, 1}, 5]; numbers = numbers/Total[numbers] which gives {0.269286, 0.313348, 0.0546711, 0.191817, 0.170879} which adds to 1
Dec
20
comment Different results of a definite integral $\int_0^{\cosh ^{-1}(a)} \frac{1}{\sqrt{a^2 \text{sech}^2(x)-1}}\, dx$
@JunhoLee I also just verified it with Rubi, it also gives -Pi/2 or 3 Pi/2 : !Mathematica graphics so I think the symbolic result is correct. May be there is problem with numerical integration.
Dec
20
comment Different results of a definite integral $\int_0^{\cosh ^{-1}(a)} \frac{1}{\sqrt{a^2 \text{sech}^2(x)-1}}\, dx$
@JunhoLee Well, may be, but looking at: r = Integrate[1/Sqrt[-1 + 2^2*Sech[x]^2], x]; Limit[r, x -> ArcCosh[2]] - Limit[r, x -> 0]; N[%] gives -Pi/2 and -Pi/2 is actually the same as 3 Pi/2 However, NIntegrate[1/Sqrt[-1 + 2^2*Sech[x]^2], {x, 0, ArcCosh[2]}] gives Pi/2. So I am not sure. May be someone knows.
Dec
20
comment Can I define an axiomatic (Boolean algebra) system and prove theorems using Mathematica?
Wolfram is working on adding pure math to Mathematica, here is his blog on this computational-knowledge-and-the-future-of-pure-mathematics/ the idea is that one should be able to proof things and do more pure math using Mathematica. Proofs can be generated or checked. But this is for future versions.
Dec
20
comment Buying a new computer (specifically for Mathematica)
get a mac for Mathematica. many at WRI use mac's not PC's. I think due to origin of how Mathematica was created, it is apple first, windows second, and then Linux 5th.
Dec
20
comment How to check if Integrate solved the integral?
@Jens sure. This sounds like a smart way to go about it. I did not think about it.
Dec
13
comment about the design of Part related to Association
I found more documentation on part with association. it is all here reference.wolfram.com/language/ref/Part.html about half way down the page. many examples.
Dec
13
comment about the design of Part related to Association
I think I figured it. To obtain the whole part, i.e. (key->value), one must use [[n;;n]] syntax or [[n;;]]. But if you use [[n]] this will only give the value at part n. The reason why [[n;;m]] work for both key,values at both n through m parts, is because of the ;; usage. So to pull both key+value, use ;;, else it will default to only the value at that part.
Dec
13
comment about the design of Part related to Association
I agree. It is not consistent. May be it is a bug?
Dec
13
comment Plot with Mathematica
nice. but no control buttons :)
Dec
12
comment AbsoluteOptions prints error messages in V10
@gwr I see. I was only using the example provided. For the example given, it did not give an error. There is a new post today on AbsoluteOptions problems also. mathematica.stackexchange.com/questions/68937/… so it seems there is more issue still with this. May be you can post your example as separate question? This will make it easier to track it on its own?
Dec
12
comment Fourier and InverseFourier precision
Chop[x1 - Abs[x1]] gives {0, 0, 0, -1.5136, -1.91785, -0.558831, 0, 0, 0, -1.08804, -1.99998, -1.07315, 0, 0, 0, -0.575807, -1.92279, -1.50197, 0, 0}
Dec
12
comment Solve a differential equation with an integral inside?
@NimblePawn added Laplace method. Not sure why -Sin[t] shows up in the ODE method vs. +Sin[t] in the Laplace now. But these are two methods I know about. The correct answer with zero IC should be the ODE based one. with -sin.
Dec
11
comment TableView displays negative numbers incorrectly
same problem in 10.0.2
Dec
11
comment Probable Bug in ConvexHullMesh
still present in 10.0.2. checked on windows 7
Dec
11
comment Black line after ImageTrim
bug still present in 10.0.2
Dec
10
comment A bug in the overloading of MemberQ and FreeQ for Association?
In v 10.0.2, now I get this: I do not know if this is the correct output you expect or not, but here it is: !Mathematica graphics
Dec
10
comment How to perform “implicit” integration?
fyi, Maple can do this directly, with the option continuous given (may be M should be able to do this also). int(diff(y(z),z),z=x1..x2,continuous) gives -y(x1)+y(x2)
Dec
9
comment Why is Plot3D applied to TransformedDistribution in 2 random variables so slow?
@kguler ok thanks!. I guess I was using it wrong then. Feel free to post this as answer. This was not clear from the doc to me. (it would have been nice if M gave me an error or something to tell me I am calling it wrong, instead of wanting and waiting... no error checking done in the API?)
Dec
9
comment Why is Plot3D applied to TransformedDistribution in 2 random variables so slow?
@kguler pdf depends on 2 random variable. it is a 2D pdf. As in the example shown in the link PDF[BinormalDistribution[.3], {x, y}] it is function of x,y where both are independent random variables, both draw from same distribution.