Engee documentation
Notebook

Bipolar transistor in low-voltage mode

In this example, we use an equivalent substitution circuit to evaluate the performance of a bipolar transistor. The transistor is switched on according to a common-emitter circuit and operates in a low-signal (linear) mode.
We will use the Mask to create our own transistor block.

Description of the model

image.png

The transistor is represented by an equivalent circuit with h-parameters:

- input resistance,

- output conductivity,

- current transfer coefficient,

- voltage feedback coefficient.

The parameters are set for the BC107-B transistor:

In [ ]:
h_ie = 3000.0;
h_oe = 60e-6;
h_fe = 300.0;
h_re = 3e-4; 

There are two resistors in the model:

  • Rbias (47 kOhm) is a bias resistor. Sets the nominal operating point.
  • Rload (470 ohms) - load resistor.

The gain is approximately determined by the expression:

The separation capacitor C1 (1 UF) is selected so that its resistance at a frequency of 1 kHz is negligible compared to the input resistance . The peak output voltage should be .

Simulation of the model

In [ ]:
engee.addpath(@__DIR__)
if "SmallSignalBipolarTransistor" in [m.name for m in engee.get_all_models()]
    m = engee.open( "SmallSignalBipolarTransistor" ) # загрузка модели
else
    m = engee.load( "SmallSignalBipolarTransistor.engee" )
end
results = engee.run(m, verbose=true)
Building...
Progress 0%
Progress 34%
Progress 100%
Progress 100%
Out[0]:
SimulationResult(
    run_id => 9,
    "V_b" => WorkspaceArray{Float64}("SmallSignalBipolarTransistor/V_b")
,
    "V_load" => WorkspaceArray{Float64}("SmallSignalBipolarTransistor/V_load")

)
In [ ]:
t = results["V_b"].time;            # Время
V_b  = results["V_b"].value;        # Напряжение смещения
V_load  = results["V_load"].value;  # Напряжение нагрузки
In [ ]:
plot(t, V_b, title="Напряжение транзистора", xlabel="Время, c", ylabel="Напряжение, В", w = 2, label="База")
plot!(t, V_load, xlabel="Время, c", ylabel="Напряжение, В", w = 2, label="Коллектор")
Out[0]:

The model shows how more complex elements, in this case a transistor, can be built from blocks of the Physical Modeling/Fundamental library and hidden under a Mask.