Network


Latest external collaboration on country level. Dive into details by clicking on the dots.

Hotspot


Dive into the research topics where Shin-Cheng Mu is active.

Publication


Featured researches published by Shin-Cheng Mu.


Higher-order and Symbolic Computation \/ Lisp and Symbolic Computation | 2008

A programmable editor for developing structured documents based on bidirectional transformations

Zhenjiang Hu; Shin-Cheng Mu; Masato Takeichi

This paper presents an application of bidirectional transformation to the design and implementation of a novel editor supporting interactive refinement in the development of structured documents. The user performs a sequence of editing operations on a view of the document, and the editor automatically derives an efficient and reliable document source and a transformation that produces the document view. The editor is unique in its programmability, in the sense that transformations can be obtained through editing operations. It uses the view-updating technique developed in the database community and a new bidirectional transformation language that can describe not only the relationship between the document source and its view, but also the data dependency in the view.


asian symposium on programming languages and systems | 2004

An Algebraic Approach to Bi-directional Updating

Shin-Cheng Mu; Zhenjiang Hu; Masato Takeichi

In many occasions would one encounter the task of maintaining the consistency of two pieces of structured data that are related by some transform — synchronising bookmarks in different web browsers, the source and the view in an editor, or views in databases, to name a few. This paper proposes a formal model of such tasks, basing on a programming language allowing injective functions only. The programmer designs the transformation as if she is writing a functional program, while the synchronisation behaviour is automatically derived by algebraic reasoning. The main advantage is being able to deal with duplication and structural changes. The result will be integrated to our structure XML editor in the Programmable Structured Document project.


mathematics of program construction | 2004

An Injective Language for Reversible Computation

Shin-Cheng Mu; Zhenjiang Hu; Masato Takeichi

Erasure of information incurs an increase in entropy and dissipates heat. Therefore, information-preserving computation is essential for constructing computers that use energy more effectively. A more recent motivation to understand reversible transformations also comes from the design of editors where editing actions on a view need to be reflected back to the source data. In this paper we present a point-free functional language, with a relational semantics, in which the programmer is allowed to define injective functions only. Non-injective functions can be transformed into a program returning a history. The language is presented with many examples, and its relationship with Bennett’s reversible Turing machine is explained. The language serves as a good model for program construction and reasoning for reversible computers, and hopefully for modelling bi-directional updating in an editor.


Journal of Functional Programming | 2009

Algebra of programming in agda: Dependent types for relational program derivation

Shin-Cheng Mu; Hsiang-Shang Ko; Patrik Jansson

Relational program derivation is the technique of stepwise refining a relational specification to a program by algebraic rules. The program thus obtained is correct by construction. Meanwhile, dependent type theory is rich enough to express various correctness properties to be verified by the type checker. We have developed a library, AoPA (Algebra of Programming in Agda), to encode relational derivations in the dependently typed programming language Agda. A program is coupled with an algebraic derivation whose correctness is guaranteed by the type system. Two non-trivial examples are presented: an optimisation problem and a derivation of quicksort in which well-founded recursion is used to model terminating hylomorphisms in a language with inductive types.


mathematics of program construction | 2002

Inverting Functions as Folds

Shin-Cheng Mu; Richard S. Bird

This paper is devoted to the proof and applications of a theorem giving conditions under which the inverse of a partial function can be expressed as a relational hylomorphism. The theorem is a generalisation of a previous result, due to Bird and de Moor, that gave conditions under which a total function can be expressed a relational fold. The theorem is illustrated with three problems, all dealing with constructing trees with various properties.


european symposium on programming | 2010

A grammar-based approach to invertible programs

Kazutaka Matsuda; Shin-Cheng Mu; Zhenjiang Hu; Masato Takeichi

Program inversion has many applications such as in the implementation of serialization/deserialization and in providing support for redo/undo, and has been studied by many researchers. However, little attention has been paid to two problems: how to characterize programs that are easy or hard to invert and whether, for each class of programs, efficient inverses can be obtained. In this paper, we propose an inversion framework that we call grammar-based inversion, where a program is associated with an unambiguous grammar describing the range of the program. The complexity of the grammar indicates how hard it is to invert the program, while the complexity is related to how efficient an inverse can be obtained.


partial evaluation and semantic-based program manipulation | 2008

Maximum segment sum is back: deriving algorithms for two segment problems with bounded lengths

Shin-Cheng Mu

It may be surprising that variations of the maximum segment sum (MSS) problem, a textbook example for the squiggolists, are still active topics for algorithm designers. In this paper we examine the new developments from the view of relational program calculation. It turns out that, while the classical MSS problem is solved by the Greedy Theorem, by applying the Thinning Theorem, we get a linear-time algorithm for MSS with upper bound on length. To derive a linear-time algorithm for the em maximum segment density problem, on the other hand, we purpose a variation of thinning based on an extended notion of monotonicity. The concepts of left-negative and right-screw segments emerge from the search for monotonicity conditions. The efficiency of the resulting algorithms crucially relies on exploiting properties of the set of partial solutions and design efficient data structures for them.


mathematics of program construction | 2008

Algebra of Programming Using Dependent Types

Shin-Cheng Mu; Hsiang-Shang Ko; Patrik Jansson

Dependent type theory is rich enough to express that a program satisfies an input/output relational specification, but it could be hard to construct the proof term. On the other hand, squiggolists know very well how to show that one relation is included in another by algebraic reasoning. We demonstrate how to encode functional and relational derivations in a dependently typed programming language. A program is coupled with an algebraic derivation from a specification, whose correctness is guaranteed by the type system.


asian symposium on programming languages and systems | 2006

A pushdown machine for recursive XML processing

Keisuke Nakano; Shin-Cheng Mu

XML transformations are most naturally defined as recursive functions on trees. A naive implementation, however, would load the entire input XML tree into memory before processing. In contrast, programs in stream processing style minimise memory usage since it may release the memory occupied by the processed prefix of the input, but they are harder to write because the programmer is left with the burden to maintain a state. In this paper, we propose a model for XML stream processing and show that all programs written in a particular style of recursive functions on XML trees, the macro forest transducer, can be automatically translated to our stream processors. The stream processor is declarative in style, but can be implemented efficiently by a pushdown machine. We thus get the best of both worlds — program clarity, and efficiency in execution.


Science of Computer Programming | 2004

Theory and applications of inverting functions as folds

Shin-Cheng Mu; Richard S. Bird

This paper is devoted to the proof, applications, and generalisation of a theorem, due to Bird and de Moor, that gave conditions under which a total function can be expressed as a relational fold. The theorem is illustrated with three problems, all dealing with constructing trees with various properties. It is then generalised to give conditions under which the inverse of a partial function can be expressed as a relational hylomorphism. Its proof makes use of Doornbos and Backhouses theory on well-foundedness and reductivity. Possible applications of the generalised theorem is discussed.

Collaboration


Dive into the Shin-Cheng Mu's collaboration.

Top Co-Authors

Avatar
Top Co-Authors

Avatar
Top Co-Authors

Avatar

Zhenjiang Hu

National Institute of Informatics

View shared research outputs
Top Co-Authors

Avatar
Top Co-Authors

Avatar

Patrik Jansson

Chalmers University of Technology

View shared research outputs
Top Co-Authors

Avatar
Top Co-Authors

Avatar
Top Co-Authors

Avatar

Yu-Hsi Chiang

National Taiwan University

View shared research outputs
Top Co-Authors

Avatar

Keisuke Nakano

University of Electro-Communications

View shared research outputs
Top Co-Authors

Avatar
Researchain Logo
Decentralizing Knowledge