Method to manipulate data

2 次查看(过去 30 天)
Shaun Lim
Shaun Lim 2018-7-27
回答: Aquatris 2018-8-1
Is there any model in simulink that can block the data input in a specific time to create a fault condition. For example, I need to block 30 seconds of data in a 10 minutes dataset to creata a fault condition
  1 个评论
Christopher Wallace
When you say "block the data" what do you mean? Should the data change to 0's or NaN's?

请先登录,再进行评论。

回答(1 个)

Aquatris
Aquatris 2018-8-1
You can use "Switch" blocks change your signal from whatever it is to a constant 0 using the time as a determining factor.
Alternatively you can use "Matlab Function" block where inputs would be time and the signal and output will be determined with an if statement with in;
function y = blockSignal(t,x)
if t > 10 && t < 20
y = 0;
else
y = x;
end
end

类别

Help CenterFile Exchange 中查找有关 Modeling 的更多信息

产品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by