function [T1,T2,T3] = elm_delay_example(w)

% computes elmore delay to three loads given widths w for additional
% problem in hw5

% capacitive loads
cload1=1.5;
cload2=1;
cload3=5;

% conductances of wire segments
R=1./w;

% capacitance of wire segments
C=w;

% elmore delays to the loads
T1 = (C(3)+cload1)*(R(1)+R(2)+R(3)) + ...
     C(2)*(R(1)+R(2)) + ...
     (C(1)+C(4)+C(5)+C(6)+cload2+cload3)*R(1);
T2 = (C(5)+cload2)*(R(1)+R(4)+R(5)) + ...
     C(4)*(R(1)+R(4)) + ...
     (C(6)+cload3)*(R(1)+R(4)) + ...
     (C(1)+C(2)+C(3)+cload1)*R(1);
T3 = (C(6)+cload3)*(R(1)+R(4)+R(6)) + ...
     C(4)*(R(1)+R(4)) + ...
     (C(1)+C(2)+C(3)+cload1)*R(1) + ...
     (C(5)+cload2)*(R(1)+R(4));
