summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/qcircuit
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-08-14 22:00:19 +0000
committerKarl Berry <karl@freefriends.org>2018-08-14 22:00:19 +0000
commit998b6b92c2867ae022c2567c71d507143e989d88 (patch)
treefd1bbd72a22442bee09849a7fb2700a9a06deea8 /Master/texmf-dist/tex/latex/qcircuit
parent3345b51f8b3705001fa10573d43270d5bafe196a (diff)
qcircuit (15aug18)
git-svn-id: svn://tug.org/texlive/trunk@48400 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/qcircuit')
-rw-r--r--Master/texmf-dist/tex/latex/qcircuit/qcircuit.sty17
1 files changed, 14 insertions, 3 deletions
diff --git a/Master/texmf-dist/tex/latex/qcircuit/qcircuit.sty b/Master/texmf-dist/tex/latex/qcircuit/qcircuit.sty
index 89959ecc649..1b936386e14 100644
--- a/Master/texmf-dist/tex/latex/qcircuit/qcircuit.sty
+++ b/Master/texmf-dist/tex/latex/qcircuit/qcircuit.sty
@@ -1,4 +1,4 @@
-% qcircuit version 2.5.3
+% qcircuit version 2.6.0
% Contributors: Steve Flammia, Bryan Eastin, Travis Scholten
% This program is free software; you can redistribute it and/or modify
% it under the terms of the GNU General Public License as published by
@@ -19,7 +19,7 @@
% Thanks also to Dave Clader, Andrew Childs, Rafael Possignolo, Tyson Williams,
% Sergio Boixo, Cris Moore, Jonas Anderson, and Stephan Mertens for helping us test
% and/or develop the new version.
-\ProvidesPackage{qcircuit}[2016/12/29]
+\ProvidesPackage{qcircuit}[2018/08/14]
\RequirePackage{xy}
\DeclareOption{braket}{
@@ -76,6 +76,13 @@
\newcommand{\cds}[2]{*+<1em,.9em>{\hphantom{#2}} \POS [0,0].[#1,0]="e",!C *{#2};"e"+ R \qw}
% Allows the insertion of text without a box and exands circuit around this text.
% This is useful for such things as ... to indicate a generalized circuit.
+\newcommand{\barrier}[2][-0.95em]{\ar @{--}[#2,1]+<#1, -1em>;[0,1]+<#1, 1em>}
+ % Defines a barrier that is represented by a horizontal dashed line.
+ % It takes a a single argument to specify how many bits to cover
+ % To center the barrier between gates you can adjust the horizontal offset
+ % with an optional second parameter. This is the horizontal offset in em.
+ % It defaults to -0.95em
+ % WARNING: Be sure to place the barrier on the topmost bit it covers, it only propogates downwards
\newcommand{\gate}[1]{*+<.6em>{#1} \POS ="i","i"+UR;"i"+UL **\dir{-};"i"+DL **\dir{-};"i"+DR **\dir{-};"i"+UR **\dir{-},"i" \qw}
% Boxes the argument, making a gate.
\newcommand{\sgate}[2]{\gate{#1} \qwx[#2]}
@@ -137,6 +144,10 @@
\newcommand{\ghost}[1]{*+<1em,.9em>{\hphantom{#1}} \qw}
% Leaves space for \multigate on wires other than the one on which \multigate appears. Without this command wires will cross your gate.
% #1 should match the second argument in the corresponding \multigate.
+\newcommand{\cghost}[1]{*+<1em,.9em>{\hphantom{#1}} \cw}
+ % Same as ghost but with a classical incoming wire.
+\newcommand{\nghost}[1]{*+<1em,.9em>{\hphantom{#1}}}
+ % Same as ghost but with no incoming wire.
\newcommand{\push}[1]{*{#1}}
% Inserts #1, overriding the default that causes entries to have zero size. This command takes the place of a gate.
% Like a gate, it must precede any wire commands.
@@ -171,4 +182,4 @@
\newcommand{\pureghost}[1]{*+<1em,.9em>{\hphantom{#1}}}
% Same as \ghost except it omits the wire leading to the left.
-\endinput \ No newline at end of file
+\endinput