Skip to content

Instantly share code, notes, and snippets.

View KonstantinSchubert's full-sized avatar

Konstantin Schubert KonstantinSchubert

View GitHub Profile
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@fronx
fronx / transclose.m
Created October 25, 2011 22:05 — forked from moink/transclose.m
Transitive closure solution in Matlab
function A=transclose(A)
%returns the transitive closure matrix of the input matrix
%input: A(i,j) is 1 if the binary relation if (element i) R (element j) using the
%notation in the introduction of http://en.wikipedia.org/wiki/Transitive_closure
%
%Usage example: Implements the first example problem on https://www.4clojure.com/problem/84
%
%divideskey=[2 3 4 8 9 27];
%%I don't actually use that variable, but it keeps track of what my matrix means
%