Skip to content

Instantly share code, notes, and snippets.

@takumim
Last active July 27, 2017 22:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save takumim/2cfefa4487accf70cffb053e6070f1a1 to your computer and use it in GitHub Desktop.
Save takumim/2cfefa4487accf70cffb053e6070f1a1 to your computer and use it in GitHub Desktop.
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
\documentclass[12pt]{article}
\usepackage{stix}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}[domain=0:5]
\path[fill=gray!20] (0,3) -- (4,0) -- (4.9,0) -- (4.9,3.9) -- (0,3.9) -- (0,3);
\draw[very thin,color=gray] (-0.1,-0.1) grid (4.9,3.9);
\draw[->] (-0.2,0) -- (5.1,0);
\draw[->] (0,-0.2) -- (0,4.1);
\filldraw[black] (0,3) circle (2pt);
\filldraw[black] (3,1) circle (2pt);
\filldraw[black] (4,0) circle (2pt);
\draw[dashed] (0,3) -- (4,0);
\end{tikzpicture}
\end{document}
Display the source blob
Display the rendered blob
Raw
<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="91pt" height="170pt" viewBox="0 0 91 170" version="1.1">
<defs>
<clipPath id="clip1">
<path d="M 7 0 L 9 0 L 9 169.660156 L 7 169.660156 Z M 7 0 "/>
</clipPath>
<clipPath id="clip2">
<path d="M 37 151 L 59 151 L 59 169.660156 L 37 169.660156 Z M 37 151 "/>
</clipPath>
<clipPath id="clip3">
<path d="M 0 114 L 56 114 L 56 169.660156 L 0 169.660156 Z M 0 114 "/>
</clipPath>
</defs>
<g id="surface1">
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(89.99939%,89.99939%,89.99939%);fill-opacity:1;" d="M 8.273438 122.308594 L 47.605469 161.636719 L 83.003906 161.636719 L 83.003906 8.246094 L 8.273438 8.246094 L 8.273438 122.308594 "/>
<path style="fill:none;stroke-width:0.19925;stroke-linecap:butt;stroke-linejoin:miter;stroke:rgb(50%,50%,50%);stroke-opacity:1;stroke-miterlimit:10;" d="M -2.833532 0.000986126 L 53.858473 0.000986126 M -2.833532 28.345581 L 53.858473 28.345581 M -2.833532 56.692991 L 53.858473 56.692991 M -2.833532 85.040401 L 53.858473 85.040401 M -0.00132432 -2.834036 L -0.00132432 110.552788 M 28.346086 -2.834036 L 28.346086 110.552788 " transform="matrix(1.3875,0,0,-1.3875,8.275275,161.638087)"/>
<path style="fill:none;stroke-width:0.3985;stroke-linecap:butt;stroke-linejoin:miter;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:10;" d="M -5.668554 0.000986126 L 59.128743 0.000986126 " transform="matrix(1.3875,0,0,-1.3875,8.275275,161.638087)"/>
<path style="fill:none;stroke-width:0.3985;stroke-linecap:round;stroke-linejoin:round;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:10;" d="M -2.072649 2.391189 C -1.692581 0.955378 -0.850802 0.279702 -0.000576577 0.000986126 C -0.850802 -0.27773 -1.692581 -0.956221 -2.072649 -2.392032 " transform="matrix(1.3875,0,0,-1.3875,90.59455,161.638087)"/>
<g clip-path="url(#clip1)" clip-rule="nonzero">
<path style="fill:none;stroke-width:0.3985;stroke-linecap:butt;stroke-linejoin:miter;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:10;" d="M -0.00132432 -5.669059 L -0.00132432 115.823058 " transform="matrix(1.3875,0,0,-1.3875,8.275275,161.638087)"/>
</g>
<path style="fill:none;stroke-width:0.3985;stroke-linecap:round;stroke-linejoin:round;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:10;" d="M -2.071964 2.391527 C -1.694712 0.955716 -0.850117 0.280041 0.000108108 0.00132432 C -0.850117 -0.280207 -1.694712 -0.955883 -2.071964 -2.391694 " transform="matrix(0,-1.3875,-1.3875,0,8.275275,0.6564)"/>
<path style="fill-rule:nonzero;fill:rgb(0%,0%,0%);fill-opacity:1;stroke-width:0.3985;stroke-linecap:butt;stroke-linejoin:miter;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:10;" d="M 30.339329 28.345581 C 30.339329 29.446369 29.446874 30.338824 28.346086 30.338824 C 27.245297 30.338824 26.355658 29.446369 26.355658 28.345581 C 26.355658 27.247608 27.245297 26.355153 28.346086 26.355153 C 29.446874 26.355153 30.339329 27.247608 30.339329 28.345581 Z M 30.339329 28.345581 " transform="matrix(1.3875,0,0,-1.3875,8.275275,161.638087)"/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(0%,0%,0%);fill-opacity:1;" d="M 50.371094 161.636719 C 50.371094 160.109375 49.132812 158.875 47.605469 158.875 C 46.078125 158.875 44.84375 160.109375 44.84375 161.636719 C 44.84375 163.164062 46.078125 164.402344 47.605469 164.402344 C 49.132812 164.402344 50.371094 163.164062 50.371094 161.636719 Z M 50.371094 161.636719 "/>
<g clip-path="url(#clip2)" clip-rule="nonzero">
<path style="fill:none;stroke-width:0.3985;stroke-linecap:butt;stroke-linejoin:miter;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:10;" d="M 30.339329 0.000986126 C 30.339329 1.101774 29.446874 1.991414 28.346086 1.991414 C 27.245297 1.991414 26.355658 1.101774 26.355658 0.000986126 C 26.355658 -1.099802 27.245297 -1.992257 28.346086 -1.992257 C 29.446874 -1.992257 30.339329 -1.099802 30.339329 0.000986126 Z M 30.339329 0.000986126 " transform="matrix(1.3875,0,0,-1.3875,8.275275,161.638087)"/>
</g>
<path style="fill-rule:nonzero;fill:rgb(0%,0%,0%);fill-opacity:1;stroke-width:0.3985;stroke-linecap:butt;stroke-linejoin:miter;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:10;" d="M 1.991919 85.040401 C 1.991919 86.141189 1.099464 87.033644 -0.00132432 87.033644 C -1.099297 87.033644 -1.991752 86.141189 -1.991752 85.040401 C -1.991752 83.939612 -1.099297 83.047157 -0.00132432 83.047157 C 1.099464 83.047157 1.991919 83.939612 1.991919 85.040401 Z M 1.991919 85.040401 " transform="matrix(1.3875,0,0,-1.3875,8.275275,161.638087)"/>
<path style="fill-rule:nonzero;fill:rgb(0%,0%,0%);fill-opacity:1;stroke-width:0.3985;stroke-linecap:butt;stroke-linejoin:miter;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:10;" d="M 1.991919 56.692991 C 1.991919 57.793779 1.099464 58.686234 -0.00132432 58.686234 C -1.099297 58.686234 -1.991752 57.793779 -1.991752 56.692991 C -1.991752 55.592202 -1.099297 54.699747 -0.00132432 54.699747 C 1.099464 54.699747 1.991919 55.592202 1.991919 56.692991 Z M 1.991919 56.692991 " transform="matrix(1.3875,0,0,-1.3875,8.275275,161.638087)"/>
<path style="fill-rule:nonzero;fill:rgb(0%,0%,0%);fill-opacity:1;stroke-width:0.3985;stroke-linecap:butt;stroke-linejoin:miter;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-miterlimit:10;" d="M 1.991919 28.345581 C 1.991919 29.446369 1.099464 30.338824 -0.00132432 30.338824 C -1.099297 30.338824 -1.991752 29.446369 -1.991752 28.345581 C -1.991752 27.247608 -1.099297 26.355153 -0.00132432 26.355153 C 1.099464 26.355153 1.991919 27.247608 1.991919 28.345581 Z M 1.991919 28.345581 " transform="matrix(1.3875,0,0,-1.3875,8.275275,161.638087)"/>
<g clip-path="url(#clip3)" clip-rule="nonzero">
<path style="fill:none;stroke-width:0.3985;stroke-linecap:butt;stroke-linejoin:miter;stroke:rgb(0%,0%,0%);stroke-opacity:1;stroke-dasharray:2.98883,2.98883;stroke-miterlimit:10;" d="M -0.00132432 28.345581 L 28.346086 0.000986126 " transform="matrix(1.3875,0,0,-1.3875,8.275275,161.638087)"/>
</g>
</g>
</svg>
\documentclass[12pt]{article}
\usepackage{stix}
\usepackage{tikz-cd}
\begin{document}
\begin{tikzpicture}[domain=0:2]
\path[fill=gray!20] (0,1) -- (1,0) -- (1.9,0) -- (1.9,3.9) -- (0,3.9) -- (0,1);
\draw[very thin,color=gray] (-0.1,-0.1) grid (1.9,3.9);
\draw[-cm to] (-0.2,0) -- (2.1,0);
\draw[-cm to] (0,-0.2) -- (0,4.1);
\filldraw[black] (1,1) circle (2pt);
\filldraw[black] (1,0) circle (2pt);
\filldraw[black] (0,3) circle (2pt);
\filldraw[black] (0,2) circle (2pt);
\filldraw[black] (0,1) circle (2pt);
\draw[dashed] (0,1) -- (1,0);
\end{tikzpicture}
\end{document}
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
\documentclass[12pt]{article}
\usepackage{stix}
\usepackage{tikz-cd}
\begin{document}
\begin{tikzpicture}[domain=0:3]
\path[fill=gray!20] (0,1) -- (2,0) -- (2.9,0) -- (2.9,3.9) -- (0,3.9) -- (0,1);
\draw[very thin,color=gray] (-0.1,-0.1) grid (2.9,3.9);
\draw[-cm to] (-0.2,0) -- (3.1,0);
\draw[-cm to] (0,-0.2) -- (0,4.1);
\filldraw[black] (2,3) circle (2pt);
\filldraw[black] (2,2) circle (2pt);
\filldraw[black] (2,1) circle (2pt);
\filldraw[black] (2,0) circle (2pt);
\filldraw[black] (1,2) circle (2pt);
\filldraw[black] (1,1) circle (2pt);
\filldraw[black] (0,1) circle (2pt);
\draw[dashed] (0,1) -- (2,0);
\end{tikzpicture}
\end{document}
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
\documentclass[12pt]{article}
\usepackage{stix}
\usepackage{tikz-cd}
\begin{document}
\begin{tikzpicture}[domain=0:7]
\path[fill=gray!20] (0,1) -- (1,0) -- (6.9,0) -- (6.9,3.9) -- (0,3.9) -- (0,1);
\draw[very thin,color=gray] (-0.1,-0.1) grid (6.9,3.9);
\draw[-cm to] (-0.2,0) -- (7.1,0);
\draw[-cm to] (0,-0.2) -- (0,4.1);
\filldraw[black] (6,3) circle (2pt);
\filldraw[black] (6,2) circle (2pt);
\filldraw[black] (6,1) circle (2pt);
\filldraw[black] (6,0) circle (2pt);
\filldraw[black] (4,2) circle (2pt);
\filldraw[black] (4,1) circle (2pt);
\filldraw[black] (4,0) circle (2pt);
\filldraw[black] (3,2) circle (2pt);
\filldraw[black] (3,1) circle (2pt);
\filldraw[black] (3,0) circle (2pt);
\filldraw[black] (2,1) circle (2pt);
\filldraw[black] (2,0) circle (2pt);
\filldraw[black] (1,1) circle (2pt);
\filldraw[black] (1,0) circle (2pt);
\filldraw[black] (0,1) circle (2pt);
\draw[dashed] (0,1) -- (1,0);
\end{tikzpicture}
\end{document}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment