Skip to content

Commit

Permalink
Change inputs to long
Browse files Browse the repository at this point in the history
  • Loading branch information
pbloem committed Sep 14, 2016
1 parent 6bf3635 commit d0a252a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions nodes/src/main/java/org/nodes/models/ERSimpleModel.java
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,15 @@ public double codelength(Graph<? extends Object> graph)
}
}

public static double undirected(int size, int numLinks, boolean withPrior)
public static double undirected(long size, long numLinks, boolean withPrior)
{
double n = size;
double t = n * (n - 1) / 2;
return (withPrior ? Functions.prefix(size) + log2(t + 1) : 0) + log2Choose(numLinks, t);
}


public static double directed(int size, int numLinks, boolean withPrior)
public static double directed(long size, long numLinks, boolean withPrior)
{
double n = size;
double t = n * n - n;
Expand Down

0 comments on commit d0a252a

Please sign in to comment.