Filter löschen
Filter löschen

Tolerance inside the Test assessment block

5 Ansichten (letzte 30 Tage)
Suresh
Suresh am 24 Okt. 2023
Beantwortet: ag am 2 Nov. 2023
How to intoduce the tolerance inside the test assessment block ?
for example, i want to check/compare the OUT_controller plus or minus 0.1
verify(OUT_controller >= -1 && OUT_controller <=1)
Does simulink test has an option to do this ?

Akzeptierte Antwort

ag
ag am 2 Nov. 2023
Hi Suresh,
I understand that you need to introduce tolerance inside the test assessment block.
To do so, you can write your required condition in the transition block of the “Test assessment” block parameters dialogue box.
Below is an example to demonstrate the same:
OUT_controller >= -1.1 && OUT_controller <=1.1
In the above code I’ve modified the condition based on the required tolerance (± 0.1).
Please refer to the below resources for more details:
Hope this helps!
Best Regards,
Aryan Gupta

Weitere Antworten (0)

Community Treasure Hunt

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

Start Hunting!

Translated by