diff options
author | Karl Berry <karl@freefriends.org> | 2019-09-05 22:33:48 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2019-09-05 22:33:48 +0000 |
commit | e25c6ee4ea5169bf31ab28ebddcc94c8b4992453 (patch) | |
tree | 855a21705c8e75ed71066d3e6215752d04dd43ba /Master/texmf-dist/doc/latex/circuit-macros/examples/MC.m4 | |
parent | 1047c66359c02d8f8852e0dbdd69f5cf1cd1a76b (diff) |
circuit-macros (all except boxdims.sty in doc due to generic file names)
git-svn-id: svn://tug.org/texlive/trunk@52035 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/circuit-macros/examples/MC.m4')
-rw-r--r-- | Master/texmf-dist/doc/latex/circuit-macros/examples/MC.m4 | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/circuit-macros/examples/MC.m4 b/Master/texmf-dist/doc/latex/circuit-macros/examples/MC.m4 new file mode 100644 index 00000000000..8c8872b9c96 --- /dev/null +++ b/Master/texmf-dist/doc/latex/circuit-macros/examples/MC.m4 @@ -0,0 +1,35 @@ +.PS +# MC.m4 +cct_init + + dv = dimen_*0.6 + dh = dimen_*0.4 + backup = dimen_/6 + + for i=1 to 3 do {{ + if i==2 then { Input: dot } else { line up (2-i)*dv } + source(right_ dimen_,AC); llabel(,,sprintf("$v_{\char%g}$",96+i)) + resistor(right_ dimen_ from Here-(backup/2,0)); if i==1 then { llabel(,R_i)} + inductor(right_ dimen_ from Here-(backup,0),W); if i==1 then { llabel(,L_i)} + line right_ i*dh; b_current(sprintf("$i_{\char%g}$",96+i)); dot + { line down (3-i)*dv; capacitor(down_ dimen_) + if i==1 then { rlabel(,C_i) } + if i==2 then { dot(ifgpic(at last line.end)) } \ + else { line ifgpic(from last line.end) right (2-i)*dh } + } + line right 3*dh; dot + E: Here+((3-i)*dh+dimen_*3/2,(4-2*i)*dv) + for j=1 to 3 do {{ + line up (6-j*3)*dv then right (3-i)*dh + switch(right_ E.x-Here.x) + llabel(,,sprintf("$S_{\char%g\char%g}$",96+i,64+j)) + if i==2 then { dot } else { line down (2-i)*dv } + }} + line from E right dh then down E.y-Here.y + arrow right dimen_/2 ; { sprintf("$i_{\char%g}\quad$",64+i) above } + resistor(right_ dimen_ from Here-(arrowht/2,0)); if i==1 then {llabel(,R_o)} + inductor(right_ dimen_ from Here-(backup,0),W); if i==1 then {llabel(,L_o)} + source(right_ dimen_,AC); llabel(sprintf("$v_{\char%g}$",64+i)) + if i==2 then { Output: dot } else { line down (2-i)*dv } + }} +.PE |