summaryrefslogtreecommitdiff
path: root/info/examples/lgc2/4-5-5.mp
blob: af96118b1937f4a744ee807c753960c1f9ef8675 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
% --- start of displayed preamble in the book ---
input makecirc;
initlatex("");
% --- end of displayed preamble in the book ---
defaultfont:="ptmr8r";
warningcheck:=0;
beginfig(1)
resistor.a(origin,normal,90,"R","10\ohm");
centerto.A(R.a.l,R.a.r,2cm,ind);
inductor.a(A,Up,90,"L","");
z1=(xpart L.a.r, ypart R.a.r);
centreof.B(R.a.r,z1,cap);
capacitor.a(c.B,normal,phi.B,"C","");
wire(R.a.r,C.a.l,udsq);wire(C.a.r,L.a.r,rlsq);
wire(L.a.l,R.a.l,udsq);
endfig;
end;