Hi all, I want to find the value of a graph at a certain point of time in simulink.

I have a graph and I want to find the magnitude of graph at time 0.1s. I know the point of time where I have to find the magnitude, I sent the value to workspace and in here, I need to get the magnitude of the value at 0.1s, can some one please help me? thank you.

1 Comment

Is the graph in a Simulink "Scope" block, or a figure generated by using plot()?

Sign in to comment.

 Accepted Answer

The best way is to obtain the data of that graph and then use interp1() to find out the y value corresponding to the x value. For example:
Time=0:0.03:0.3;
Y=1:11;
Mag=interp1(Time,Y,0.1)
Check doc interp1 for many options.

More Answers (0)

Categories

Community Treasure Hunt

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

Start Hunting!