LIBRARY
RelativeAngleSensor
Ideal sensor to measure the relative angle between two splines
This component extends from PartialRelativeSensor
Usage
RelativeAngleSensor()
Connectors
spline_a- (Spline)spline_b- (Spline)phi_rel- This connector represents a real signal as an output from a component (RealOutput)
Behavior
Source
dyad
# Ideal sensor to measure the relative angle between two splines
component RelativeAngleSensor
extends PartialRelativeSensor
# Relative angle between two splines as output signal
phi_rel = RealOutput() [{
"JuliaSim": {
"placement": {"icon": {"x1": 450, "y1": 950, "x2": 550, "y2": 1050, "rot": 90}}
}
}]
relations
phi_rel = spline_b.phi-spline_a.phi
0 = spline_a.tau
metadata {
"JuliaSim": {
"icons": {"default": "jsml://RotationalComponents/RelSensor-Angle-Vel-Acc.svg"}
}
}
endFlattened Source
# Ideal sensor to measure the relative angle between two splines
component RelativeAngleSensor
# Left spline of shaft
spline_a = Spline() [{
"JuliaSim": {"placement": {"icon": {"x1": -50, "y1": 450, "x2": 50, "y2": 550}}}
}]
# Right spline of shaft
spline_b = Spline() [{
"JuliaSim": {"placement": {"icon": {"x1": 950, "y1": 450, "x2": 1050, "y2": 550}}}
}]
# Relative angle between two splines as output signal
phi_rel = RealOutput() [{
"JuliaSim": {
"placement": {"icon": {"x1": 450, "y1": 950, "x2": 550, "y2": 1050, "rot": 90}}
}
}]
relations
0 = spline_a.tau+spline_b.tau
phi_rel = spline_b.phi-spline_a.phi
0 = spline_a.tau
metadata {
"JuliaSim": {
"icons": {"default": "jsml://RotationalComponents/RelSensor-Angle-Vel-Acc.svg"}
}
}
end
Test Cases
Related
Examples
Experiments
Analyses