Re: [julia-users] Re: Surprising behavior of singleton types

2014-06-01 Thread Jameson Nash
https://github.com/JuliaLang/julia/issues/7062 This is the bug I mentioned yesterday where Array{T} reads back as Array{T, N}. Array{T} and Array{T,N} describe the same type object On Sat, May 31, 2014 at 9:01 PM, David Moon dave_m...@alum.mit.edu wrote: On Saturday, May 31, 2014 1:08:29

[julia-users] Re: GnuTLS package and read! function

2014-06-01 Thread Ivar Nesje
Sorry that nobody answered this. I'm not much help, but usually it is hard to get help on individual packages on julia-users. A common suggestion is to open an issue with the github repository to get the attention of the developer. If that does not work, it is more likely that someone that

[julia-users] Parallel, strange behavior of the loop after changing the value to a variable, 6 time slower

2014-06-01 Thread paul analyst
D:\install\Julia\Julia 0.3.0-prerelease-win64-ver3\Julia 0.3.0-prerelease ver 3bin\julia.exe -p 8 _ _ _ _(_)_ | A fresh approach to technical computing (_) | (_) (_)| Documentation: http://docs.julialang.org _ _ _| |_ __ _ | Type help() to list

Re: [julia-users] Parallel, strange behavior of the loop after changing the value to a variable, 6 time slower

2014-06-01 Thread Andreas Noack Jensen
This is the usual problem with global variables in Julia. If you define k by const k=2 the timing results should be similar. 2014-06-01 16:09 GMT+02:00 paul analyst paul.anal...@mail.com: D:\install\Julia\Julia 0.3.0-prerelease-win64-ver3\Julia 0.3.0-prerelease ver 3bin\julia.exe

[julia-users] How can I create a simple Graph using Graphs.jl?

2014-06-01 Thread Paulo Castro
Hi guys, Sorry about making this kind of question, but even after reading the documentation, I don't know how to create the simplest graph object using Graphs.jl. For example, I want to create the following graph: http://i.stack.imgur.com/820Fl.png Can someone give me the directions to

Re: [julia-users] Parallel, strange behavior of the loop after changing the value to a variable, 6 time slower

2014-06-01 Thread paul analyst
*julia const k=2;ERROR: cannot declare k constant; it already has a value:/Paul* W dniu niedziela, 1 czerwca 2014 16:13:27 UTC+2 użytkownik Andreas Noack Jensen napisał: This is the usual problem with global variables in Julia. If you define k by const k=2 the timing

Re: [julia-users] Parallel, strange behavior of the loop after changing the value to a variable, 6 time slower

2014-06-01 Thread paul analyst
After restart julia : D:\install\Julia\Julia 0.3.0-prerelease-win64-ver3\Julia 0.3.0-prerelease ver 3bin\julia.exe -p 8 _ _ _ _(_)_ | A fresh approach to technical computing (_) | (_) (_)| Documentation: http://docs.julialang.org _ _ _| |_ __ _ |

[julia-users] Re: How can I create a simple Graph using Graphs.jl?

2014-06-01 Thread Alex
Hi Paulo, you can get your graph as follows julia using Graphs julia g = simple_graph(4) Directed Graph (4 vertices, 0 edges) julia add_edge!(g, 1, 2) edge [1]: 1 -- 2 julia add_edge!(g, 2, 4) edge [2]: 2 -- 4 julia add_edge!(g, 4, 3) edge [3]: 4 -- 3 julia add_edge!(g, 3, 1) edge [4]: 3 --

Re: [julia-users] Parallel, strange behavior of the loop after changing the value to a variable, 6 time slower

2014-06-01 Thread Andreas Noack Jensen
I don't know why you get that error. It is not there on my machine. However, for some reason defining k as const does not work for parallel loops. It only makes a difference for serial loops so my explanation was wrong. Is this expected? julia const k1=1000;k2 = k1; julia @time for i =

[julia-users] pmap(eig,M) . How to separate result of pmap ?

2014-06-01 Thread paul analyst
julia M = {cor(rand(4,4)) for i=1:2} 2-element Array{Any,1}: 4x4 Array{Float64,2}: 1.0 -0.227554 0.507924 -0.800516 -0.227554 1.00.220113 0.75924 0.507924 0.220113 1.0 -0.272765 -0.800516 0.75924 -0.272765 1.0 4x4 Array{Float64,2}: 1.0 -0.65399

Re: [julia-users] pmap(eig,M) . How to separate result of pmap ?

2014-06-01 Thread Andreas Noack Jensen
You can use a complehensen. To get a vector of the vectors of the eigenvalues you could write [x[1] for x in P]. If you want to collect them into a matrix, you could write hcat([x[1] for x in P]...) 2014-06-01 16:56 GMT+02:00 paul analyst paul.anal...@mail.com: julia M = {cor(rand(4,4)) for

Re: [julia-users] typeassert when assigning to elements of array

2014-06-01 Thread Ivar Nesje
It does not look like this was ever posted in the github tracker. kl. 17:33:37 UTC+2 onsdag 28. mai 2014 skrev Jameson følgende: Looks like a code lowering bug. Can you post this to the github issue tracker? On Wednesday, May 28, 2014, Adam Kapor adam@gmail.com javascript: wrote:

Re: [julia-users] A[]: Accessing array with empty index

2014-06-01 Thread Carlos Becker
I see now. I thought 0-dimensional arrays could not contain any element at all. For consistency, wouldn't it be better to thrown an error when myArray[] is used for non-zero-dimensional arrays? Looks like a difficult to find typo. -- Carlos On Fri, May

Re: [julia-users] typeassert when assigning to elements of array

2014-06-01 Thread Jameson Nash
It was posted -- I saw Jeff fix this. On Sunday, June 1, 2014, Ivar Nesje iva...@gmail.com wrote: It does not look like this was ever posted in the github tracker. kl. 17:33:37 UTC+2 onsdag 28. mai 2014 skrev Jameson følgende: Looks like a code lowering bug. Can you post this to the github

[julia-users] REPL history-search prefix with up/down arrow key

2014-06-01 Thread Adrian Cuthbertson
Prior to the release of the new REPL I always used rlwrap with julia-basic so I could bind my own up/down arrow keys to history-search forward and backward for a prefix string under the cursor. (I have an arthritis problem with ctrl-R). Is there a way of achieving the same with the new REPL, or

Re: [julia-users] REPL history-search prefix with up/down arrow key

2014-06-01 Thread Tim Holy
PgUp/PgDown. See the manual. --Tim On Sunday, June 01, 2014 05:38:52 PM Adrian Cuthbertson wrote: Prior to the release of the new REPL I always used rlwrap with julia-basic so I could bind my own up/down arrow keys to history-search forward and backward for a prefix string under the cursor.

Re: [julia-users] pmap(eig,M) . How to separate result of pmap ?

2014-06-01 Thread paul analyst
Thx, OK, its work. It is eigenvaluse of first array : [x[1] for x in P][1] But ?: julia [x[i] for x in P][i]=pmap(eig,M) ERROR: i not defined in anonymous at no file this no wor. How automaticly preapre m1,v1; m2,v2; m3,v3 lik in typical [m,v] = eig(R) Paul W dniu niedziela, 1 czerwca

[julia-users] Re: How can I create a simple Graph using Graphs.jl?

2014-06-01 Thread Alex
Glad it helped. I am not active on stackoverflow, but thanks for the offer. Maybe you can link to this thread in case someone else is looking for an answer? Best, Alex. On Sunday, 1 June 2014 17:57:33 UTC+2, Paulo Castro wrote: Hi Alex! Thanks very much for the help! That's exactly what I

Re: [julia-users] Black screen/window with OpenGL

2014-06-01 Thread Elliot Saba
Try running it inside an OpenGL debugger, (On Mac, you can install the opengl debugger from Apple's Xcode utilities download, I believe it's available as a separate download on their website) to figure out which OpenGL calls are failing. -E On Fri, May 30, 2014 at 11:34 PM, Toivo Henningsson