11,373 research outputs found

    The C++0x "Concepts" Effort

    Full text link
    C++0x is the working title for the revision of the ISO standard of the C++ programming language that was originally planned for release in 2009 but that was delayed to 2011. The largest language extension in C++0x was "concepts", that is, a collection of features for constraining template parameters. In September of 2008, the C++ standards committee voted the concepts extension into C++0x, but then in July of 2009, the committee voted the concepts extension back out of C++0x. This article is my account of the technical challenges and debates within the "concepts" effort in the years 2003 to 2009. To provide some background, the article also describes the design space for constrained parametric polymorphism, or what is colloquially know as constrained generics. While this article is meant to be generally accessible, the writing is aimed toward readers with background in functional programming and programming language theory. This article grew out of a lecture at the Spring School on Generic and Indexed Programming at the University of Oxford, March 2010

    Generic programming in the mCRL2 toolset

    Get PDF
    The mCRL2 tool set [GKM+08] is a tool set for verification and validation of concurrent processes, based on process algebra speci??cations. The mCRL2 language is based on the Algebra of Communicating Processes (ACP), which is extended to include data and time. This paper reports on experiences with generic programming in C++ as applied in the implementation of the tool set. C++ concepts, a type system for templates [RS06], form a key ingredient of this style of programming. Using concept definitions, requirements on template types can be defined that are type checked during compile time. The main benefits for the mCRL2 tool set are uniform and exible interfaces that operate on well-defined types, and a signi??cant increase in code reuse. The use of concepts also promotes the writing of code that corresponds closely to pseudo code, since the chosen concepts correspond naturally with domain specific concepts. This will be illustrated by a simple use case, namely substitution functions. Generic programming is about generalizing software components, to enable reuse in a wide variety of situations. In C++, generic programming is enabled using templates. C++ concepts are proposed as a means to type check template types. A concept is a set of requirements (valid expressions, associated types, semantic invariants, complexity guarantees, and so on) that a type must fulfill to be correctly used as an argument in a call to a generic algorithm, see [RS06]. Language support for concepts has been proposed [GJS+06] for the next version of the C++ standard, C++0x. Concepts will be used to make the specification of the C++ standard library more complete and precise. A derivative of the GNU C++ compiler [Gre08] already implements language support for concepts. In the mCRL2 tool set we have used a portable library for concept checking. Most uses of generic programming in general, and more specifically the use of concepts, that are described in the literature treat the construction of data structures and algorithms that operate on these, see e.g. [GL05]

    Mathematizing C++ concurrency

    Get PDF
    Shared-memory concurrency in C and C++ is pervasive in systems programming, but has long been poorly defined. This motivated an ongoing shared effort by the standards committees to specify concurrent behaviour in the next versions of both languages. They aim to provide strong guarantees for race-free programs, together with new (but subtle) relaxed-memory atomic primitives for high-performance concurrent code. However, the current draft standards, while the result of careful deliberation, are not yet clear and rigorous definitions, and harbour substantial problems in their details. In this paper we establish a mathematical (yet readable) semantics for C++ concurrency. We aim to capture the intent of the current (`Final Committee') Draft as closely as possible, but discuss changes that fix many of its problems. We prove that a proposed x86 implementation of the concurrency primitives is correct with respect to the x86-TSO model, and describe our Cppmem tool for exploring the semantics of examples, using code generated from our Isabelle/HOL definitions. Having already motivated changes to the draft standard, this work will aid discussion of any further changes, provide a correctness condition for compilers, and give a much-needed basis for analysis and verification of concurrent C and C++ programs

    Extension of transonic flow computational concepts in the analysis of cavitated bearings

    Get PDF
    An analogy between the mathematical modeling of transonic potential flow and the flow in a cavitating bearing is described. Based on the similarities, characteristics of the cavitated region and jump conditions across the film reformation and rupture fronts are developed using the method of weak solutions. The mathematical analogy is extended by utilizing a few computational concepts of transonic flow to numerically model the cavitating bearing. Methods of shock fitting and shock capturing are discussed. Various procedures used in transonic flow computations are adapted to bearing cavitation applications, for example, type differencing, grid transformation, an approximate factorization technique, and Newton's iteration method. These concepts have proved to be successful and have vastly improved the efficiency of numerical modeling of cavitated bearings

    Polynomial Calculus: Rethinking the Role of Calculus in High Schools

    Get PDF
    Access to advanced study in mathematics, in general, and to Calculus, in particular, depends in part on the conceptual architecture of these knowledge domains, and in this paper we outline an alternative architecture. Our general strategy is to separate advanced concepts from the particular advanced techniques used in their definition and exposition. This alternative architecture, thus, affords access to advanced concepts from an elementary standpoint to a larger group of learners than is presently accomplished. In the case of the Calculus we develop the beginning concepts of the Differential and Integral Calculus using only concepts and skills found in secondary algebra and geometry. The purpose of this reconstruction is not to alter the teaching of limit-based Calculus but rather to affect the content and pedagogy of the secondary mathematics courses which precede it while developing student understanding of key foundational concepts that may enhance the potential for success in post-secondary Calculus for more students

    Agile solar sailing in three-body problem : Motion between artificial equilibrium points

    Get PDF
    This paper proposes a range of time-optimal, solar sail trajectories between artificial equilibria in the Sun-Earth three body system to create an agile solar sailing mission. This allows different mission objectives to be fulfilled at different AEPs during different stages of the mission. The analyses start from a solar sail at the sub-L1 point (sunward of the classical L1 point) which is targeted by NASA’s Sunjammer mission (launch in 2014) for advanced space weather warning. From this sub-L1 point, trajectories are investigated that: 1) take the solar sail to an AEP in the ecliptic plane, but slightly trailing the Earth to be ahead of the Earth in the Parker spiral to potentially increase space weather warning times even further; 2) take the solar sail to and between AEPs displaced above or below the ecliptic plane for high-latitude observations; 3) take the solar sail from the vicinity of the L1 point to the vicinity of the L¬2 point for additional Earth observations, geomagnetic tail investigations and astronomical observations. To find time-optimal trajectories, the optimal control problem associated with each of the transfers is defined and solved using a direct pseudospectral method. The resulting time of flights are reasonable, ranging from 85 days to 232 days, and the transfers are very smooth, requiring only a minimum solar sail steering effort in most cases. Since all results are generated for a sail performance equal to that of the Sunjammer sail, the proposed trajectories provide interesting end-of-mission opportunities for the Sunjammer sail after it retires at the sub-L1 point

    Optimization of space antenna structures

    Get PDF
    Spacecraft antenna concepts, structural types, and material
    • …
    corecore