SPST Switch
Single-pole single-throw switch
Libraries:
Simscape /
Electrical /
Switches & Breakers
Description
The SPST Switch block models a single-pole single-throw switch:
When the switch is open, port p is connected to port n through a resistance with value equal to the reciprocal of the Open conductance parameter value.
When the switch is closed, port p is connected to port n through a resistance with value equal to the Closed resistance parameter value.
If the Threshold width parameter is set to zero, the switch is closed if the voltage presented at the vT control port exceeds the value of the Threshold parameter.
If the Threshold width parameter is greater than zero, then switch conductance G varies smoothly between off-state and on-state values:
The block uses the function 3λ2 – 2λ3 because its derivative is zero for λ = 0 and λ = 1.
Defining a small positive Threshold width can help solver convergence in some models, particularly if the control port signal vT varies continuously as a function of other network variables. However, defining a nonzero threshold width precludes the solver making use of switched linear optimizations. Therefore, if the rest of your network is switched linear, set Threshold width to zero.
Optionally, you can add a delay between the point at which the voltage at
vT passes the threshold and the switch opening
or closing. To enable the delay, on the Dynamics tab,
set the Model dynamics parameter to Model
turn-on and turn-off times
.
Model Gate Control Port
You can control the switch gates by using a physical signal port or electrical conserving ports. To select the gate control port, set the Modeling option parameter to either:
PS control port
— The block contains a physical signal port that is associated with the threshold voltage.Electrical control port
— The block contains electrical conserving ports that are associated with the threshold voltage.
Examples
Ports
Refer to the figure for port locations.
Input
Conserving
Parameters
Extended Capabilities
Version History
Introduced in R2012b