Skip to content

Instantly share code, notes, and snippets.

View puripuri2100's full-sized avatar
🦾

Naoki Kaneko puripuri2100

🦾
View GitHub Profile
@puripuri2100
puripuri2100 / puzzle-drawing.sty
Last active November 21, 2018 14:07
puzzle-drawing
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{demo-puzzle}[2018/09/05 v1.1]%イラロジ対応
\RequirePackage{tikz}
\newcommand{\zahyo}[2]{#1,-#2}
\newcommand{\@sen}[2]{\draw[very thick](#1) -- (#2);}
\newcommand{\sankaku@nuri}[3]{\draw[fill=black] (#1) -- (#2) -- (#3);}
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@puripuri2100
puripuri2100 / mdsc.satyh
Last active December 23, 2018 20:19 — forked from zr-tex8r/scarticle.satyh
SATySFi:非常に画期的な文書クラス(Markdown)
% scarticle.satyh: An essential docuemnt class for SATySFi
%
% Copyright (c) 2018 Takayuki YATO (aka. "ZR")
% GitHub: https:%github.com/zr-tex8r
% Twitter: @zr_tex8r
% Distributed under the MIT License.
@require: pervasives
@require: list
@require: math
@puripuri2100
puripuri2100 / key-value-kousou.md
Created February 9, 2019 08:30
SATySFiでの key-value のような引数についての構想

動作

LaTeXのkey-value方式のオプション引数をイメージ

LaTeXでの例:

\scsnowman
\scsnowmanscsnowman[adjustbaseline,scale=1]

\includegraphics[width=100mm]{hoge.jpg}
@puripuri2100
puripuri2100 / test.saty
Created March 5, 2019 11:02
再帰してしまうSATySFiファイル
@require: stdjabook
let-rec fact n = n * fact (n - 1)
in
document (|
title = {\SATySFi;概説};
author = {Takashi SUWA};
@puripuri2100
puripuri2100 / local.satyh
Last active March 13, 2019 09:53
SATySFiの`\app`の括弧の色を変える
% Author : T.Suwa and puripuri2100
% LICENSE : LGPL v3
@require: math
@require: color
let half-length hgt dpt hgtaxis fontsize =
let minhalflen = fontsize *' 0.5 in
let lenappend = fontsize *' 0.1 in
length-max minhalflen ((length-max (hgt -' hgtaxis) (hgtaxis +' dpt)) +' lenappend)
@puripuri2100
puripuri2100 / README.md
Last active May 30, 2020 04:33
Compilation speed: pdfLaTeX vs SATySFi

Compilation speed: pdfLaTeX vs SATySFi

  • Measure the time required to compile the document udhrmain.tex.
  • We measure the time 9 times after 3 times of warming up, and average the middle 5 values.

Result

  • pdfLaTeX: 0.817 seconds
@puripuri2100
puripuri2100 / todo.md
Last active March 10, 2023 16:08
SATySFiで作るパッケージ
@puripuri2100
puripuri2100 / sekaisi.pdf
Last active May 25, 2019 11:50
世界史まとめ(仮)
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@puripuri2100
puripuri2100 / nest.satyh
Last active May 26, 2019 05:06
{|a|b|c|}を受け取ったら[[{1};a];[{2};b];[{3};c]] にしてくれる関数
let-mutable it-num <- 0
let add-num-list it-list =
let () = it-num <- 0 in
let add-num it =
let () = it-num <- !it-num + 1 in
(it, !it-num)
in
List.map add-num it-list