Created
February 17, 2014 16:53
-
-
Save dohyunkim/9054402 to your computer and use it in GitHub Desktop.
number cases with luamplib. a patch to finder needed for ".mf" file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| \documentclass{minimal} | |
| \usepackage[hangul]{kopubfonts} | |
| \usepackage{luamplib} | |
| \def\cropmplibwithmargin#1{% | |
| \pdfhorigin#1 \pdfvorigin\pdfhorigin | |
| \pdfpagewidth\dimexpr\MPwidth+2\pdfhorigin\relax | |
| \pdfpageheight\dimexpr\MPheight+2\pdfvorigin\relax | |
| } | |
| \begin{document} | |
| \begin{mplibcode} | |
| input boxes; | |
| input cmarrows; | |
| setup_cmarrows( | |
| brace_name = "Biggbrace"; | |
| parameter_file = "cmr12.mf"; | |
| macro_name = "LeftBrace" | |
| ); | |
| def leftbrace (suffix tt,bb) = | |
| LeftBrace (bb.sw+up*bb.dy -- tt.nw+down*tt.dy) | |
| enddef; | |
| pair hspace; hspace = (8,0); | |
| beginfig(0); | |
| boxit.real (btex 실수 etex); | |
| boxit.ratio(btex 유리수 etex); | |
| boxit.irrat(btex 무리수 etex); | |
| boxit.integ(btex 정수 etex); | |
| boxit.noint(btex 정수 아닌 유리수 etex); | |
| boxjoin(a.sw=b.nw); | |
| boxit.prime(btex 소수 etex); | |
| boxit.one (btex $1$ etex); | |
| boxit.compo(btex 합성수 etex); | |
| boxjoin(a.sw=b.nw); | |
| boxit.posit(btex 양의 정수 etex); | |
| boxit.zero (btex $0$ etex); | |
| boxit.negat(btex 음의 정수 etex); | |
| boxjoin(a.sw=b.nw); | |
| boxit.yuhan(btex 유한소수 etex); | |
| boxit.repea(btex 순환(무한)소수 etex); | |
| boxjoin(a.sw=b.nw); | |
| boxit.sunsu(btex 순순환(무한)소수 etex); | |
| boxit.honsu(btex 혼순환(무한)소수 etex); | |
| boxjoin(a.sw=b.nw); | |
| boxit.bisun(btex (대수적)비순환(무한)소수 etex); | |
| boxit.trans(btex 초월수 etex); | |
| one.w=posit.e+hspace; | |
| zero.w=integ.e+hspace; | |
| honsu.nw=repea.e+hspace; | |
| repea.nw=noint.e+hspace; | |
| trans.nw=irrat.e+hspace; | |
| ratio.e+hspace=.5[integ.w,noint.w]; xpart integ.w=xpart noint.w; | |
| real.e+hspace=.5[ratio.w,irrat.w]; xpart ratio.w=xpart irrat.w; | |
| ypart negat.s=ypart yuhan.n; | |
| ypart honsu.s=ypart bisun.n; | |
| drawunboxed(real,ratio,irrat,integ,noint,posit,zero,negat,yuhan,repea,prime,one,compo,sunsu,honsu,bisun,trans); | |
| leftbrace(ratio,irrat); | |
| leftbrace(integ,noint); | |
| leftbrace(posit,negat); | |
| leftbrace(prime,compo); | |
| leftbrace(yuhan,repea); | |
| leftbrace(sunsu,honsu); | |
| leftbrace(bisun,trans); | |
| endfig; | |
| \end{mplibcode} | |
| \cropmplibwithmargin{2pt} | |
| \end{document} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment