Skip to content

Instantly share code, notes, and snippets.

View hyiltiz's full-sized avatar
🎯
Focusing

Hörmet Yiltiz hyiltiz

🎯
Focusing
View GitHub Profile
@hyiltiz
hyiltiz / qr_decomp.m
Created January 21, 2024 08:23
Simple QR decomposition and SVD in Octave
function qr_decomp()
Qs = cell();
m0 = reshape(1:9, [3, 3])'
m = m0;
k = 0;
[Q, Qm] = qr1(m);
Q = [eye(k) zeros([k size(m, 2)]);
zeros([size(m, 1) k]) Q];
@hyiltiz
hyiltiz / randn.clj
Created January 13, 2024 04:56
Lazy generator for Gaussian random samples using efficient box-muller algorithm
(ns statistics.lazy.rand
(:require [clojure.math :as math]))
(defn rand-gaussian
"Get a random sample from the standard Gaussian distribution.
Optionall specify the mean m and the standard deviation sd. E.g.:
(rand-gaussian) # => 0.1324...
(rand-gaussian 5 0.1) # => 5.3397...
"
([] (rand-gaussian 0 1))
jojofjaeofje
fjasefjiesofj
"
" Prevent various Vim features from keeping the contents of pass(1) password
" files (or any other purely temporary files) in plaintext on the system.
"
" Either append this to the end of your .vimrc, or install it as a plugin with
" a plugin manager like Tim Pope's Pathogen.
"
" Author: Tom Ryder <tom@sanctum.geek.nz>
"
@hyiltiz
hyiltiz / Makefile
Created December 10, 2015 05:47 — forked from lmullen/Makefile
PDF slides and handouts using Pandoc and Beamer
SLIDES := $(patsubst %.md,%.md.slides.pdf,$(wildcard *.md))
HANDOUTS := $(patsubst %.md,%.md.handout.pdf,$(wildcard *.md))
all : $(SLIDES) $(HANDOUTS)
%.md.slides.pdf : %.md
pandoc $^ -t beamer --slide-level 2 -o $@
%.md.handout.pdf : %.md
pandoc $^ -t beamer --slide-level 2 -V handout -o $@
@hyiltiz
hyiltiz / gource-multiple-repositories.sh
Created October 13, 2015 02:14 — forked from derEremit/gource-multiple-repositories.sh
Generates gource video out of multiple repositories.
#!/usr/bin/env bash
# Generates gource video (h.264) out of multiple repositories.
# Pass the repositories in command line arguments.
# Example:
# <this.sh> /path/to/repo1 /path/to/repo2
RESOLUTION="1600x1080"
outfile="gource.mp4"
i=0
@hyiltiz
hyiltiz / gource-commands.txt
Created October 13, 2015 02:09 — forked from rafi/gource-commands.txt
Gource command
################################
gource commands
################################
# basic command for big and long projects
gource --max-user-speed 500 --seconds-per-day 0.05 --file-idle-time 10 -e 0.005 -f --max-files 300 --hide-files
# some easy to understand commands
# for output file
--output-ppm-stream ~/ppm/ppm-kohana
@hyiltiz
hyiltiz / gist:c232ef20571f7116d2fd
Created September 9, 2015 14:58
ssh git@github.com output
ssh -v -T git@github.com
OpenSSH_6.9p1 Debian-1, OpenSSL 1.0.2d 9 Jul 2015
debug1: Reading configuration data /home/user/.ssh/config
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug1: Connecting to github.com [192.30.252.130] port 22.
debug1: Connection established.
debug1: identity file /home/user/.ssh/id_rsa type 1
debug1: key_load_public: No such file or directory
debug1: identity file /home/user/.ssh/id_rsa-cert type -1
@hyiltiz
hyiltiz / cidr_merge
Last active August 29, 2015 14:22 — forked from lsylsy2/cidr_merge
1.0.1.0/24
1.0.2.0/23
1.0.8.0/21
1.0.32.0/19
1.1.0.0/24
1.1.2.0/23
1.1.4.0/22
1.1.8.0/21
1.1.16.0/20
1.1.32.0/19