Skip to content

Instantly share code, notes, and snippets.

#include <iostream>
#include <string>
#include <functional>
#include "either.hxx"
using std::cout;
using std::endl;
using std::string;

#[JULIA] Faster than CGAL Delaunay

####TL;DR

DelaunayJL is an incremental 2D Delaunay triangulation algorithm implemented in Julia, it is robust and ~20% faster than CGAL, the C++ de-facto industry standard. And it's MIT Licensed! all links to code are below

####Show me the data!

The figure below shows how much time it takes to run a benchmark on my computer, an Intel Core i7-4800MQ CPU @ 2.7Ghz, 16GB RAM, Win8 64bit. The benchmark consists of inserting a number of points uniformly distributed. The benchmark is run 5 times for each number of points once for CGAL and once for Julia. The numbers of points used are 10K, 100K, 1M, and 10M. CGAL v4.4 was compiled with VS2013 64bit release mode, Julia is of version 0.3.0 Commit 7681878 (2014-08-20 20:43 UTC) x86_64-w64-mingw32 the delaunay code is here (see other gists of mine for complementing files... I'll compile this all into a library when I have the time)

@denisfitz57
denisfitz57 / FRPandPhilosophy.md
Last active November 9, 2023 10:26 — forked from dmvaldman/FRPandPhilosophy.md
Descartes, Berkeley and Functional Reactive Programming

Descartes, Berkeley and Functional Reactive Programming

By @dmvaldman

Functional Reactive Programming (FRP) is generating buzz as an alternative to Object Oriented Programming (OOP) for certain use cases. However, an internet search quickly leads a curious and optimistic reader into the rabbit-hole of monads, functors, and other technical jargon. I’ve since emerged from this dark and lonely place with the realization that these words are mere implementation details, and that the core concepts are far more universal. In fact, the groundwork was laid down many centuries before the first computer, and has more to do with interpretations of reality, than structuring programs. Allow me to explain.

There’s an old thought experiment that goes like this:

Tree

@denisfitz57
denisfitz57 / whistle-encode.pl
Created November 4, 2015 01:28 — forked from windytan/whistle-encode.pl
whistle encoder
# windytan's pea whistle encoder
# http://www.windytan.com/2015/10/pea-whistle-steganography.html
use warnings;
use strict;
my $data = $ARGV[0] // "OHAI!";
my $outfile = "whistle.wav";
my $fs = 44100; # sample rate
my $fc = 2600; # whistle pitch

Visual Studio 2015 Update 1 was released today.

As part of this this release, a C# Interactive tool is provided. This is a read-eval-print loop for C#. It can be opened via the 'View -> Other Windows' menu:

Below is a screenshot demonstrating the computer algebra library Symbolism in C# Interactive:

@denisfitz57
denisfitz57 / walk.py
Created April 1, 2016 16:55 — forked from jcmiller11/walk.py
Random Walk Using Race Conditions
from __future__ import print_function
from threading import Thread
from time import sleep
WALKNUM = 0
STEPNUM = 0
KILL = False
def increment(value):
global WALKNUM
@denisfitz57
denisfitz57 / understanding-word-vectors.ipynb
Created April 21, 2017 16:46 — forked from aparrish/understanding-word-vectors.ipynb
Understanding word vectors: A tutorial for "Reading and Writing Electronic Text," a class I teach at ITP. (Python 2.7)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@denisfitz57
denisfitz57 / prepack-svelte.md
Created May 4, 2017 21:11 — forked from Rich-Harris/prepack-svelte.md
Is Prepack like Svelte?

Note: I'm not involved in Prepack in any way — please correct me if I say anything incorrect below!

A few people have asked me if Prepack and Svelte are similar projects with similar goals. The answer is 'no, they're not', but let's take a moment to explore why.

What is Prepack?

Prepack describes itself as a 'partial evaluator for JavaScript'. What that means is that it will run your code in a specialised interpreter that, rather than having some effect on the world (like printing a message to the console), will track the effects that would have happened and express them more directly.

So for example if you give it this code...