Skip to content

Instantly share code, notes, and snippets.

View vtjnash's full-sized avatar

Jameson Nash vtjnash

View GitHub Profile
@vtjnash
vtjnash / actor_centrality.jl
Created August 15, 2012 02:35 — forked from SirVer/actor_centrality.jl
Actor centrality in Julia
type Node
name::UTF8String
sn::Set{Node}
n::Vector{Node} #this is assigned later, as an efficiently iterable copy of sn
Node(name) = new(name, Set{Node}())
end
typealias Graph Dict{UTF8String, Node}
@vtjnash
vtjnash / streams
Created December 8, 2012 04:21 — forked from Keno/streams
Howto and overview of new I/O system:
Using spawn and run
-------------------
Commands are specified with backticks as before:
julia> `echo test`
`echo test`
# This stripped down example that has odd performance.
# It takes about 4 seconds to compile and allocates about 550MB of memory
type T1Type
f1::Float64
end
T1Type() = T1Type(
0.0)
type Ts
T1::T1Type
@vtjnash
vtjnash / testcp.cxx
Last active August 29, 2015 14:02 — forked from ihnorton/testcp.cxx
// envtest.cpp : Defines the entry point for the console application.
//
#include <windows.h>
#include <tchar.h>
#include <stdio.h>
int _tmain()
{
@vtjnash
vtjnash / ex.md
Last active August 29, 2015 14:19 — forked from ihnorton/ex.md
%jl_value_t = type { %jl_value_t* }
declare void @jl_throw_with_superfluous_argument(%jl_value_t*, i32)
@jl_domain_exception = external global %jl_value_t*

define double @julia_gv_67043(i64) {
top:
  %1 = call double inttoptr (i64 339752784 to double (double, double)*)(double 1.000000e+00, double 0.000000e+00)
  %2 = sitofp i64 %0 to double
  %3 = call double inttoptr (i64 339772768 to double (double, double)*)(double %1, double %2)