matlab debounce,Debounce Temporal Properties

matlab debounce,Debounce Temporal PropertiesTemporalOperatorsTheSimulink®DesignVerifier™libraryprovidesthreebasictemporaloperatorblockscanbeusedtomodeltemporalproperties.Theintentofthetemporaloperatorsistosupportthe…

大家好,又见面了,我是你们的朋友全栈君。

Temporal Operators

The Simulink® Design Verifier™ library provides three basic temporal operator blocks can be used to model temporal properties. The intent of the temporal operators is to support the specification of temporal requirements, such that the modeled property has a closer co-relation to the actual textual requirement. These blocks are low-level building blocks for constructing more complex temporal properties.

Debounce Model and Requirements

Consider a debounce logic that debounces between values of 0 and 1 based on the input holding a value for a fixed number of time steps.

The debounce functionality is captured in the containing Stateflow® chart.

open_system(‘sldvdemo_debounce_to’)

open_system(‘sldvdemo_debounce_to/debounce’)

56e4f0795cf35e4d8361ab78e9761491.png

Consider two requirements of the debounce model that you would like to verify.

Requirement 1:

Whenever the input equals 1 for more than 6 steps, the output shall be equal to 2.

Requirement 2:

Whenever the input becomes 0 for more than 5 steps after the output was 2, the output shall equal 1 as long as the input stays at 0.

Property Specification

For specifying Requirement 1, you first represent the constraint that input equals 1 for more than 6 steps. This can be captured by the Detector block from the Temporal Operator Blocks Library. On detecting that the input value is 1 for 7 (or more than 6) time steps, you want to check that the output equals 2 as long as input stays equal to 1 after the detection. Use the “Synchronized” option of the Detector block followed by an Implies block to capture this.

open_system(‘sldvdemo_debounce_to/Verify True Output1’)

831c63f08e426cd8f76a897c5ad4eb78.png

Multiple temporal operator blocks can be combined to construct more complex temporal properties. Consider Requirement 2.

open_system(‘sldvdemo_debounce_to/Verify True Output2’)

3d83642ce91a6ce889855e08445257b1.png

For illustration, this requirement is broken down roughly into three pieces of interest:

After the output was 2: This is an enabling condition for your property. While checking the rest of the constraints, you want to know if this condition was true at some point in the past. This type of an enabling condition is typically followed by an Extender (either “Finite” or “Infinite”) that, in combination with other constraints, might form the first input to your implication.

The input becomes 0 for more than 5 steps and check something as long as input stays 0: For the same reason as the first property, you use a Detector with “Synchronized” output (“Time steps for input detection” = 6).

The output shall equal 1: This is the condition that you want to verify whenever the first two constraints hold. This is captured through a logical Implies block. Note that you cannot use Within Implies block here.

Property Proving

Once the temporal requirements have been modeled, you can perform property proving on these using Simulink Design Verifier.

Clean Up

To complete the example, close all the opened models.

close_system(‘sldvdemo_TOBlocks’,0);

close_system(‘sldvdemo_debounce_to’,0);

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/151555.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • 视频目标检测识别

    视频目标检测识别之前文章目标检测API已经介绍过API的基本使用,这里就不赘述了,直接上本次内容的代码了,添加的内容并不多。将测试的test.mp4原文件放到models-master\research\object_detection路径下,并创建一个detect_video.py文件,代码内容如下:importosimportcv2importtimeimportargparseim…

    2022年6月11日
    29
  • 大数据数仓建模

    大数据数仓建模        大数据项目之电商数仓(用户行为数据采集)数据仓库简介      1.什么是数据库?    数据库(database)是按照数据结构来组织,存储和管理数据的建立在计算机存储设备上的仓库。    数据库是长期存储在计算机内,有组织的,可共享的数据集合。数据库中的数据指的是以一定的数据模型组织,描述和存储在一起,具有尽可能小的冗余度,较高的数据独立性和易扩展性的特点并可在一定范围内为多个用户共享。    常用的数据库有mysql,oracle,sqlserver等。作用不一样,数据库是

    2022年5月7日
    50
  • 为什么不提供连接功能呢?

    为什么不提供连接功能呢?

    2021年7月23日
    53
  • tpshop带微分销_TPshop分销商城的分销模式

    tpshop带微分销_TPshop分销商城的分销模式TPshop针对不同的应用场景提供了多款微商城模板,今天我们一起来看看TPshop分销系统支持哪些分销模式,如何促进分销渠道的扩展和分销商管理,是否支持三级分销?推客模式:是微商城系统提供的最基础的一种分销模式,即以粉丝为中心、以社交分享为主要推广裂变方式、以佣金结算为激励手段的分销。推客模式采取的是“无限级分销、三级分佣”的模式,也就是每一个推客都可以推荐发展下一级推客,佣金的计算从直接完成销售…

    2022年5月13日
    34
  • elk面试题_百家公司运维面试题汇总

    elk面试题_百家公司运维面试题汇总备注:这一我在去年国庆节期间,整理的整个19年,学员的面试遇到的问题,整理出来之后发给后期的学员,让他们做参考和学习,看看公司会面试哪些问题。前言小的时候,哭着哭着就笑了;长大后笑着笑着就哭了,这是一种人生经历,当你经历的越多,你越发现世界不像童话里那么美好。真正值得在乎的东西,不会越来越多,只会越来越少,所以珍惜你当下的每一寸时光。现在的每一份努力,都会变成倍增的回收,在公众面前表现出来。距…

    2022年6月3日
    114
  • CAS单点登录原理分析(一)

    CAS单点登录原理分析(一)一,业务分析在分布式系统架构中,假设把上述的三个子系统部署在三个不同的服务器上。前提是用户登录之后才能访问这些子系统。那么使用传统方式,可能会存在这样的问题:1.当访问用户中心,需要用户登录帐号2.当访问购物车,还需要用户登录帐号3.当访问商品结算,又一次需要用户登录帐号访问每一个子系统都需要用户登录帐号,这样的体验对于用户来说是极差。而使用单点登录就可以很好地解决上述的问题。二,单…

    2022年6月8日
    30

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号