LIBRARY
ZeroCrossingClock ​
A zero-crossing clock that ticks once every time the input signal crosses zero.
Connect any real output to the input y here, to force it to be on the clock defined by u.
Warning
There is a known issue with zero crossings in MTK, such that you might have to set dtmax to a value where the integrator can actually catch every zero crossing. This bug is illustrated in the DiscreteComponents.Examples.ZOHBug component.
Usage ​
DiscreteComponents.ZeroCrossingClock()
Parameters: ​
| Name | Description | Units | Default value |
|---|---|---|---|
irreducible | – | false |
Connectors ​
u- This connector represents a real signal as an input to a component (RealInput)y- This connector represents a real signal as an input to a component (RealInput)
Behavior ​
Behavior of this component cannot be rendered because it includes path variables.
Source ​
dyad
"""
A zero-crossing clock that ticks once every time the input signal crosses zero.
Connect any real output to the input `y` here, to force it to be on the clock defined by `u`.
!!! warning
There is a known issue with zero crossings in MTK, such that you might have to set `dtmax`
to a value where the integrator can actually catch every zero crossing. This bug is
illustrated in the `DiscreteComponents.Examples.ZOHBug` component.
"""
external component ZeroCrossingClock@[output clk]
"The input signal whose zero crossings will trigger the clock."
u = RealInput() {
"Dyad": {
"placement": {
"diagram": {"iconName": "default", "x1": -40, "y1": 450, "x2": 60, "y2": 550, "rot": 0}
},
"tags": []
}
}
"Connect any real output to this input, to force it to be on the clock defined here."
y = RealInput@[clk]() {
"Dyad": {
"placement": {
"diagram": {"iconName": "default", "x1": 960, "y1": 450, "x2": 1060, "y2": 550, "rot": 0}
},
"tags": []
}
}
structural parameter irreducible::Boolean = false
relations
metadata {
"Dyad": {
"icons": {"default": "dyad://DiscreteComponents/ZeroCrossingClock.svg"},
"doc": {"behavior": false}
}
}
endFlattened Source
dyad
"""
A zero-crossing clock that ticks once every time the input signal crosses zero.
Connect any real output to the input `y` here, to force it to be on the clock defined by `u`.
!!! warning
There is a known issue with zero crossings in MTK, such that you might have to set `dtmax`
to a value where the integrator can actually catch every zero crossing. This bug is
illustrated in the `DiscreteComponents.Examples.ZOHBug` component.
"""
external component ZeroCrossingClock
"The input signal whose zero crossings will trigger the clock."
u = RealInput() {
"Dyad": {
"placement": {
"diagram": {"iconName": "default", "x1": -40, "y1": 450, "x2": 60, "y2": 550, "rot": 0}
},
"tags": []
}
}
"Connect any real output to this input, to force it to be on the clock defined here."
y = RealInput@[clk]() {
"Dyad": {
"placement": {
"diagram": {"iconName": "default", "x1": 960, "y1": 450, "x2": 1060, "y2": 550, "rot": 0}
},
"tags": []
}
}
structural parameter irreducible::Boolean = false
relations
metadata {
"Dyad": {
"icons": {"default": "dyad://DiscreteComponents/ZeroCrossingClock.svg"},
"doc": {"behavior": false}
}
}
endTest Cases ​
No test cases defined.
Related ​
Examples
Experiments
Analyses