The article presents a method for constructing a model of an object-oriented program in terms of multilabeled Petri nets. Only encapsulation-one of the three concepts of object-oriented paradigm-is considered. To mode...
详细信息
The article presents a method for constructing a model of an object-oriented program in terms of multilabeled Petri nets. Only encapsulation-one of the three concepts of object-oriented paradigm-is considered. To model a different aspects of encapsulation a Petri net structured object is proposed. It consists of a Petri net defining its behavior and a set of organized access points specifying its structural properties. Formal composition operations to construct a program model from the models of its methods, classes, objects, functions, and modules are introduced and a source code translation algorithm to Petri net representation is proposed. A special section of the article considers in detail a process of model construction of a real object-oriented program (OOP). Source code of the program, figures with Petri net objects modeling different elements of the program and the resulting model of the program are presented.
The non-executable language T belongs to the class of open languages initially defined in [Sunik 1,2]. Open languages are artificial human languages with the grammar of OO programming languages. Similar to a natural l...
详细信息
The non-executable language T belongs to the class of open languages initially defined in [Sunik 1,2]. Open languages are artificial human languages with the grammar of OO programming languages. Similar to a natural language, an open language is not confined to any particular representation domain and may be applied in any tasks requiring explicit informing. T can be used for producing OO specifications of various entities representing software, hardware, technical appliances, biology systems, knowledge representation systems, etc. It also allows explicit representation of semantics of programming languages and produces executable code compliant with the semantics represented.
The identification of abstractions within existing software systems is an important problem to be solved to facilitate program comprehension and the construction of a set of reusable artifacts. In particular, of inter...
详细信息
The identification of abstractions within existing software systems is an important problem to be solved to facilitate program comprehension and the construction of a set of reusable artifacts. In particular, of interest is the identification of object-like features in procedural programs. Existing techniques and algorithms achieve some level of success but do not, in general, always precisely identify a coherent set of objects. The identified objects tend to contain spurious methods that are only tenuously related to the object and require a great deal of human effort and understanding to unravel. This paper presents an improved algorithm that overcomes these drawbacks and enables the precise identification of objects with less human intervention and understanding by exploiting simple statistical techniques. The algorithm is applied to several sample programs and the results are compared with existing algorithms. Finally, the application of the algorithm to a real medium-size system is described and discussed. The algorithm was developed as part of the RE(2) project in which the identification of object-like features in existing systems is the basis for a re-engineering process aimed at populating a repository of reusable assets.
The paper proposes a general approach to recovering faulty versions and adjudicating complete states of versions in object-oriented N-version programming which is based on the concepts of the abstract version state an...
详细信息
The paper proposes a general approach to recovering faulty versions and adjudicating complete states of versions in object-oriented N-version programming which is based on the concepts of the abstract version state and mapping functions. Our recent progress in developing recovery features is reported (the previous results are presented in [1, 2]). We propose employing adjudication of version states as a means for advanced error detection. The properties which the abstract version state and mapping functions should have, in order to be used in both version recovery and state adjudication, are formulated. We introduce state and result adjudication which are useful for object-oriented programming, demonstrate how they can serve the purpose of error detection and discuss situations when the former can be effective (assuming that the latter is always used to guarantee the correctness of results). The paper describes the engineering of abstract version states: we consider three types of programmers involved in N-version programming and show how they share responsibilities and cooperate while applying the approach proposed. The paper discusses important practical issues related to implementation and application of the concepts proposed and demonstrates, with numerous examples, the usability of the approach. A thorough comparison of the existing schemes with our proposal concludes the paper.
Code smells are symptoms of sub-optimal software design and implementation choices. Detection tools were actively developed for general code smell related to coupling and cohesion issues, but such tools cannot capture...
详细信息
Code smells are symptoms of sub-optimal software design and implementation choices. Detection tools were actively developed for general code smell related to coupling and cohesion issues, but such tools cannot capture domain-specific problems. In this work, we fill the gap in data persistence and query code quality by proposing HBSNIFF, i.e., a static analysis tool for detecting 14 code smells as well as 4 mapping metrics in Java Hibernate object-Relational Mapping (ORM) codes. HBSNIFF is tested, documented, and manually validated. It also generates readable and customizable reports for every project. Moreover, it is beneficial to Mining Software Repository (MSR) research requiring large-scale analysis since project compilation is not needed for detection. (c) 2022 Elsevier B.V. All rights reserved.
Most numerical ODE solvers require problems to be written as systems of first-order differential equations. This normally requires the user to rewrite higher-order differential equations as coupled first-order systems...
详细信息
Most numerical ODE solvers require problems to be written as systems of first-order differential equations. This normally requires the user to rewrite higher-order differential equations as coupled first-order systems. Here, we introduce the treeVar class, written in object-oriented Matlab, which is capable of algorithmically reformulating higher-order ODEs to equivalent systems of first-order equations. This allows users to specify problems using a more natural syntax and saves them from having to manually derive the first-order reformulation. The technique works by using operator overloading to build up syntax trees of expressions as mathematical programs are evaluated. It then applies a set of rules to the resulting trees to obtain the first-order reformulation, which is returned as another program. This technique has connections with algorithmic/automatic differentiation. We present how treeVar has been incorporated in Chebfun, greatly improving the ODE capabilities of the system.
Current programming languages and software engineering paradigms are proving insufficient for building intelligent multi-agent systems-such as interactive games and narratives-where developers are called upon to write...
详细信息
Current programming languages and software engineering paradigms are proving insufficient for building intelligent multi-agent systems-such as interactive games and narratives-where developers are called upon to write increasingly complex behavior for agents in dynamic environments. A promising solution is to build adaptive systems;that is, to develop software written specifically to adapt to its environment by changing its behavior in response to what it observes in the world. In this paper we describe a new programming language, An Adaptive Behavior Language (A(2)BL), that implements adaptive programming primitives to support partial programming, a paradigm in which a programmer need only specify the details of behavior known at code-writing time, leaving the run-time system to learn the rest. Partial programming enables programmers to more easily encode software agents that are difficult to write in existing languages that do not offer language-level support for adaptivity. We motivate the use of partial programming with an example agent coded in a cutting-edge, but non-adaptive agent programming language (ABL), and show how A(2)BL can encode the same agent much more naturally.
hpGEM, a novel framework for the implementation of discontinuous Galerkin finite element methods (FEMs), is described. We present data structures and methods that are common for many (discontinuous) FEMs and show how ...
详细信息
hpGEM, a novel framework for the implementation of discontinuous Galerkin finite element methods (FEMs), is described. We present data structures and methods that are common for many (discontinuous) FEMs and show how we have implemented the components as an object-oriented framework. This framework facilitates and accelerates the implementation of finite element programs, the assessment of algorithms, and their application to real-world problems. The article documents the status of the framework, exemplifies aspects of its philosophy and design, and demonstrates the feasibility of the approach with several application examples.
We present Seismo-VLAB (SVL), a new open-source, object-oriented finite element software designed to optimize meso-scale simulations in the context of structural and geotechnical engineering. To this end, state-of-the...
详细信息
We present Seismo-VLAB (SVL), a new open-source, object-oriented finite element software designed to optimize meso-scale simulations in the context of structural and geotechnical engineering. To this end, state-of-the-art tools and parallel computing capabilities required for efficient modeling of soil- structure interaction and wave propagation in heterogeneous half-spaces are included. For example, perfectly matched layer, domain reduction method, dynamic nonlinear solvers, cutting edge parallel linear system solvers, domain decomposition method, and a series of plasticity models are some of the features available in SVL. In this work, we present the numerical implementation and software structure so enthusiastic developers can contribute to this open-source project and showcase some software capabilities using an illustrative example. (c) 2022 The Authors. Published by Elsevier B.V.
One key to several quality factors of software is the way components are connected. Software coupling can be used to estimate a number of quality factors, including maintainability, complexity, and reliability. object...
详细信息
One key to several quality factors of software is the way components are connected. Software coupling can be used to estimate a number of quality factors, including maintainability, complexity, and reliability. object-oriented languages are designed to reduce the number of dependencies among classes, which encourages separation of concerns and should reduce the amount of coupling. At the same time, the object-oriented language features change the way the connections are made, how they must be analyzed, and how they are measured. This paper discusses software couplings based on object-oriented relationships between classes, specifically focusing on types of couplings that are not available until after the implementation is completed, and presents a static analysis tool that measures couplings among classes in Java packages. Data from evaluating the tool on several open-source projects are provided. The coupling measurement is based on source code, which has the advantage of being quantitative and more precise than previous measures, but the disadvantage of not being available before implementation, and thus not useful for some predictive efforts.
暂无评论