% series LC fed by a current source
% Node 1 between the L and the Current Source and node 2 between the L and the C, Node 3 is ground.
clear all

%Need to provide Nvals... the number of frequency points
Nvals = 400;

%Specify the number of nodes
N = 3;

%initialise all y

y = zeros(N-1,N,Nvals);

%specify an L and C in SI units
L = 1.e-6; %Henry
C = 1.e-9; %Farads

%Define the frequncies around the resonant frequency
fres = 1/2/pi/sqrt(L*C);

frequency = linspace(.1*fres,10*fres,Nvals);
omega = 2*pi*frequency;

%Obviously...
y(1,2,:) = 1./(j*omega*L);
y(2,1,:) = 1./(j*omega*L);
y(2,3,:) = j*omega*C;
y(3,2,:) = j*omega*C;


