计算机科学 ›› 2026, Vol. 53 ›› Issue (11): 53-67.doi: 10.11896/jsjkx.260400079

• 具身智能赋能智能交通:关键技术与前沿应用 • 上一篇    下一篇

Ptolemy同步响应模型的形式化验证方法

王瑞, 张腾飞, 赵亚钦, 关永   

  1. 首都师范大学信息工程学院 北京 100048
  • 收稿日期:2026-04-13 修回日期:2026-10-09 出版日期:2026-11-15 发布日期:2026-11-10
  • 通讯作者: 关永(yongguan@cnu.edu.cn)
  • 作者简介:(rwang04@163.com)
  • 基金资助:
    国家自然科学基金(62272322)

Formal Verification Approach for Ptolemy Synchronous-Reactive Model

WANG Rui, ZHANG Tengfei, ZHAO Yaqin, GUAN Yong   

  1. School of Information Engineering,Capital Normal University,Beijing 100048,China
  • Received:2026-04-13 Revised:2026-10-09 Published:2026-11-15 Online:2026-11-10
  • About author:WANG Rui,born in 1981,Ph.D,professor.Her main research interests include formal verification and their applications in embedded systems.
    GUAN Yong,born in 1966,Ph.D,professor.His main research interests include formal verification of embedded system design and so on.
  • Supported by:
    National Natural Science Foundation of China(62272322).

摘要: Ptolemy是一个面向角色、具有可视化界面的建模与仿真工具包,为信息物理融合系统的开发提供了实验环境。它主要通过仿真的方式保证模型的正确性,但该方法只能检测模型中的某条特定路径,无法对整个模型进行全面验证,因而不足以证明模型的正确性。形式化方法是保证系统正确性的重要方法,因此文中提出了一种基于模型转换的形式化验证方法,选用符号模型检测器NuSMV作为形式化验证工具,用于验证Ptolemy的同步响应模型。首先,定义了一组将SR模型转换为NuSMV模型的映射规则;其次,设计并实现了一个插件工具以完成自动转换;最后,以一个超车控制系统和交通灯控制系统为案例进行了建模与验证。实验结果证实了该方法能够有效验证Ptolemy SR模型的正确性。

关键词: 形式化验证, Ptolemy 同步响应模型, 模型自动化转换, NuSMV

Abstract: Ptolemy is a modeling and simulation toolkit with a role-oriented and visual interface.It provides an experimental environment for CPS(Cyber-Physical System) development.It primarily ensures the correctness of the model by simulation.How-ever,this approach only verifies a specific path within the model and does not provide comprehensive verification of the entire mo-del,making it insufficient to prove the model’s correctness.Formal verification is a critical method to guarantee the correctness of the system.This paper proposes a model translation-based formal method to verify the SR(Synchronous-Reactive) model in Ptolemy,which uses the symbolic model checker NuSMV as the formal verification tool.Firstly,a set of translation rules are defined for converting the SR model to the NuSMV model.Secondly,a plugin tool is designed to achieve automated translation.Finally,an overtaking control system and traffic light control system are modeled and verified as a case study.Experimental results demonstrate that the proposed approach is useful to verify the Ptolemy SR model.

Key words: Formal verification, Ptolemy SR model, Automatic model translation, NuSMV

中图分类号: 

  • TP311
[1] BAE K,ÖLVECZKY P C.Extending the Real-Time Maude Semantics of Ptolemy to Hierarchical DE Models[PP/OL].arXiv(2010-09-22).https://arxiv.org/abs/1009.4261.
[2] RAN S,LIN J Z,WU Y,et al.Converting Ptolemy II Models to SpaceEx for Applied Verification[C]//Algorithms and Architectures for Parallel Processing.Cham:Springer,2014:669-683.
[3] CARNEVALI L,PINZUTI A,VICARIO E.Compositional Verification for Hierarchical Scheduling of Real-Time Systems[J].IEEE Transactions on Software Engineering,2013,39(5):638-657.
[4] PTOLEMAEUS C.System Design,Modeling,and Simulation Using PtolemyII[M].Berkeley:Ptolemy.org,2014.
[5] LEE E A.Cyber Physical Systems:Design Challenges[C]//2008 11th IEEE International Symposium on Object and Component-Oriented Real-Time Distributed Computing(ISORC).IEEE,2008:363-369.
[6] SENDALL S,KOZACZYNSKI W.Model Transformation:The Heart and Soul of Model-Driven Software Development[J].IEEE Software,2003,20(5):42-45.
[7] LIU X J,LIU J,EKER J,et al.Heterogeneous Modeling and Design of Control Systems[M]//Software-Enabled Control:Information Technology for Dynamical Systems.Hoboken:Wiley-IEEE Press,2003:105-122.
[8] BROOKS C,LEE E A,LIU X J,et al.Heterogeneous Concurrent Modeling and Design in Java(Volume 1:Introduction to Ptolemy II)[R].Berkeley:EECS Department,University of Ca-lifornia,Berkeley,2008.
[9] GUO Z N,LI R F,HUANG D,et al.An Embedded Firewall System Design Based on Ptolemy II[J].Journal of System Simulation,2004,16(6):1361-1363.
[10] VERHAAR K.An Integrated Embedded Control Software Design Case Study Using PtolemyII[D].Enschede:University of Twente,2008.
[11] MA X X,LIU X Z,XIE B,et al.Software Development Methods:Review and Outlook[J].Ruan Jian Xue Bao/Journal of Software,2019,30(1):3-21.
[12] CHENG C P,FRISTOE T,LEE E A.Applied Verification:The Ptolemy Approach[R].Berkeley:EECS Department,University of California,Berkeley,2008.
[13] LU Z H,WANG R,GUAN Y.Formal Verification of Discrete Event Model[C]//Proceedings of the 4th ACM SIGSOFT International Workshop on Testing,Analysis,and Verification of Cyber-Physical Systems and Internet of Things.New York:ACM,2020:3-4.
[14] TRIPAKIS S,STERGIOU C,SHAVER C,et al.A ModularFormal Semantics for Ptolemy[J].Mathematical Structures in Computer Science,2013,23(4):834-881.
[15] LIU Y,MA Z Y,HE X,et al.Approach to Transforming UML Model to Reliability Analysis Model[J].Ruan Jian Xue Bao/Journal of Software,2010,21(2):287-304.
[16] BERTHOMIEU B,BODEVEIX J P,CHAUDET C,et al.For-mal Verification of AADL Specifications in the Topcased Environment[C]//Reliable Software Technologies-Ada-Europe 2009.Berlin:Springer,2009:207-221.
[17] LIANG M L,WANG X P,XUE X P,et al.Formal Verification of UML Models Based on TLA[J].Computer Engineering,2011,37(2):72-74.
[18] LIU B,LI S Y.Research on Verification Method of AADL Behavior Model Based on NuSMV[J].Computer Technology and Development,2012,22(2):110-113.
[19] RYABTSEV M,STRICHMAN O.Translation Validation:From Simulink to C[C]//Computer Aided Verification.Berlin:Sprin-ger,2009:696-701.
[20] WU R F,DU Y,LI M H.A Model Transformation MethodBased on Simulink/Stateflow for Validation of UML Statechart Diagrams[J].Mathematics,2025,13(5):1-31.
[21] CHEN S,HU J,TANG H Y,et al.Transformation Method for AltaRica3.0 Model to NuSMV Model[J].Computer Science,2020,47(12):73-86.
[22] XAVIER M,DUBININ V,PATIL S,et al.A Framework for the Generation of Monitor and Plant Model from Event Logs Using Process Mining for Formal Verification of Event-Driven Systems[J].IEEE Open Journal of the Industrial Electronics Society,2024,5:517-534.
[23] CIMATTI A,CLARKE E M,GIUNCHIGLIA E,et al.NuSMV 2:An OpenSource Tool for Symbolic Model Checking[C]//Computer Aided Verification.Berlin:Springer,2002:359-364.
[24] FREHSE G,LE GUERNIC C,DONZÉ A,et al.SpaceEx:Scalable Verification of Hybrid Systems[C]//Computer Aided Verification.Berlin:Springer,2011:379-395.
[25] ZHANG X Z,YANG Z M,KONG H,et al.Verification of Safety for Synchronous-Reactive System Using Bounded Model Checking[J].International Journal of Software Engineering and Knowledge Engineering,2023,33(6):885-932.
[26] DIAS I L,SILVA L C E,FILHO S E A.TADEM:A Ptolemy II Model Transformation Framework for Simulink[C]//Book of Abstracts of the LVII Brazilian Symposium on Operations Research.Campinas:Galoá,2025.
[27] LEE A,MANRIQUE NEGRIN D A,CLEOPHAS L G W A.Evaluating Open-Source Tools for Heterogeneous Model-Based Digital Twin Development:A Microbrewery Case Study[C]//2024 Annual Modeling and Simulation Conference(ANNSIM).IEEE,2024:434-446.
[28] HENZINGER T A,MAJUMDAR R,RASKIN J.A Classification of Symbolic Transition Systems[J].ACM Transactions on Computational Logic,2005,6(1):1-32.
[29] TRETMANS J.Conformance Testing with Labelled Transition Systems:Implementation Relations and Test Generation[J].Computer Networks and ISDN Systems,1996,29(1):49-79.
[30] CLARKE E M,MCMILLAN K L,CAMPOS S,et al.Symbolic model checking[C]//Computer Aided Verification.Lecture Notes in Computer Science.Berlin:Springer,1996:419-422.
[31] CIMATTI A,CLARKE E M,GIUNCHIGLIA F,et al.NuSMV:A New Symbolic Model Checker[J].International Journal on Software Tools for Technology Transfer,2000,2(4):410-425.
Viewed
Full text


Abstract

Cited

  Shared   
  Discussed   
No Suggested Reading articles found!