subcircuit as class
diode and transistor example fixe
some minor updates