où: v est une across quantity représentant la tension entre deux bornes et r la valeur de la résistance
entity
resistor is
generic(r:real:=1.0E3);
port
(terminal rin, rout:electrical);
end
resistor;
architecture
simple of resistor is
begin
quantity
v across i through
rin to rout;
begin
i == v/r; -- characteristic
expression
end
simple;
|
entity
capacitor is
generic(r:real:=1.0E-9);
port
(terminal capin, capout:electrical);
end
capacitor;
architecture
simple of capacitor is
begin
quantity
v across i through
capin to capout;
begin
i == c*v'dot;
-- characteristic expression
end
simple;
|
i == c*v'dot
tolerance "tol_lowcurrent";
|