Manuscript Offprint
arXiv:2608.27007Metamorphism: A mathematical challenge for antivirus technology
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
Abstract
Metamorphic viruses, currently the most advanced computer viruses in the wild, have the unique ability of mutating their own code virtually into infinitely many highly dissimilar copies of themselves that nevertheless have the same functionality. This ability—metamorphism—together with other advanced obfuscation techniques makes these computer viruses virtually undetectable by the antivirus technology available in the market today. In this paper, I show that viral metamorphism is fully attainable by the employment of van Wijngaarden grammars. The challenge then for an antivirus software is to embed the Turing machine that decides the language generated by the grammar.
1 Introduction
Computer viruses, which have been around since the early 1970s, are essentially computer programs that can replicate their own code in their infected targets. Their growth in number and type has been exponential from early on: Tellingly, in less than five years M. A. Ludwig had to revise the title of his book first published in 1991 by changing it from The Little Black Book of Computer Viruses [1] to The Giant Black Book of Computer Viruses [2]—my bold-font emphasis. But then things got much, much worse when antivirus software companies had to worry not only about the number of viruses in the wild but also with the mathematical properties of a few of them. In effect, in the early 2000s some clever computer virus designers realized the malicious potential hidden in mathematics. This general approach to the design of malware, now known as malicious mathematics and generally explored in a few monographs (e.g., [3,4]) and papers (e.g., [5,6]), forced antivirus software companies to upgrade their staff and technology to the highest level in computing.
As a matter of fact, not all software companies bothered to do so, as only—possibly negligibly—few virus designers can cope with the hard requirements of mathematics, malicious or otherwise.
*Published as a working paper in of Formal Languages under the title “Metamorphism: A mathematical challenge for antivirus software”; submitted for standard publication in August 2026.
Malicious mathematics finds applications in other fields of malicious intent, such as cryptography; see, e.g., [7].
This is a particularly Herculean task in the case of the metamorphic viruses, i.e. viruses that generate highly dissimilar replicas of themselves to escape detection and analysis by antivirus technology (AVT); see, e.g., [8-12]. Every computer virus is a program written in some computer language such as an assembly language or a programming language; as such, writing a “typical” virus requires from a virus designer no more maths than writing a typical program does from a programmer. In fact, your usual “lamers” or “script kiddies” (i.e. unskilled malware users) can easily, albeit illegally, download kits available on the Internet that basically write the viruses for them. In contrast, metamorphic viruses require, besides the usual computing expertise, strong mathematical skills both in formal languages and automata theory and in computability theory, two subjects that are typically conjoined in a single course in a computer science curriculum (e.g., [13]).
Thus, writing a successful metamorphic virus is a computational feat, so much so that most antivirus companies regard the threat of one such virus as abstract as the mathematics it is created on. (An honorable exception is Symantec, which as early as 2003 already included these viruses in its white paper; cf. [15].) But the payoff of going to the great lengths of writing a metamorphic virus is their undetectability, with polymorphic techniques, less advanced than metamorphism, already placing a virus in the NP-complete class [16]. In other words, the payload for these virtually undetectable viruses may belie the old motto that “crime does not pay.” These viruses are evolving slowly, but their hybridization with advanced obfuscation techniques such as k-ary coding simply cannot be ignored; see, e.g., [17] and [18]. Additionally, their predictably core role in future warfare makes their comprehensive analysis not only necessary, but also urgent.
Here, drawing on F. Cohen's original formalization of computer virology based on the Turing machine I associate metamorphic viruses with a special kind of formal grammars, to wit, the van Wijngaarden grammars. I claim that a pure metamorphic virus can be designed entirely by means of a van Wijngaarden grammar; the challenge then for an AVT is to embed the Turing machine that decides the language generated by the given grammar. The present discussion continues previous work in [19-21] on the syntax and semantics of these grammars and sets a formal research program in computer virology.
2.1 The Turing Machine and the Formal Definition of a Computer Virus
2.1.1 Computable and partial computable functions
A computer virus (henceforth often just “virus”) is essentially a computer program capable of replicating its own code in a host program or file and possibly evolving different copies of itself in this act. This process, in which host programs and files are modified, can be compared to a viral infection in the biological realm; hence the coinage of these specific programs. The payload of a virus is typically—albeit not necessarily—malicious: Causing denial of service or even system collapse, compromising data confidentiality or integrity, and extortion and blackmail are among the most frequent payloads as mentioned in, for example, [22]. These pernicious results typically take dramatic proportions when the targets are so-called critical systems, not only causing substantial financial damage but also endangering human lives. For this reason, virus designers take great care that their creations are not easily detected by the many antivirus software available in the
The first published paper in which this employment of maths in writing metamorphic viruses was elaborated on was [14].
market and to achieve this goal they are willing to go to great lengths, including the employment of advanced mathematical skills. In effect, all these aspects, to wit, self-replication, evolution, and obfuscation are mathematically well-founded. The most successful virus is, however, the one that simply cannot be identified as viral code, a result that only undecidability can provide. All these aspects emphasized in italics find their mathematical support in computability theory.
In this Section, I elaborate on these mathematical results. The core result is the canonical definition of computable function:
Definition 1. A function is computable if and only if (abbr.: iff) it is effectively calculable, i.e. iff there is an algorithm that calculates it.
A special group of computable functions are the primitive computable functions:
Definition 2. A function over the natural numbers is said to be primitive computable if it can be generated from the functions , , and —known as zero function, successor function, and projection function, respectively—by zero or more applications of the following schemata known as the composition or substitution schema (1) and the primitive recursive schema (2):
(1)
If
(3)
known as minimalization schema and where R is a relation symbol, is also applied then the function obtained is partial computable.
I can now refine Definition 1 above as follows:
Definition 3. A function f is computable iff it is total and effectively calculable; it is partial computable iff it is effectively calculable.
The primitive computable functions allow for an enumeration of the partial computable functions:
Theorem 4. There are exactly countably infinitely many partial computable functions and there are exactly countably infinitely many computable functions.
Recall here that “countably infinitely many” is denoted by , where and for a set the notation denotes the cardinality of .
Also often, but less and less frequently, called recursion theory. For this synonymy-loss phenomenon, see [23,24].
I assume the reader has basic knowledge of mathematical objects such as functions and sets; the reader is referred to [13] for these foundational objects and for the essential aspects of computability theory, which include a formal discussion on the Turing machine.
Recall that we write “ ” as an abbreviation for “ ”. It is right to speak of recursiveness w.r.t. (2), but we can also say that (2) is the primitive computable schema.
2.1.2 Turing machines with temporal functions and computer viruses
Recall that function is written if it is a partial function, i.e. if it is undefined for some element(s) in its domain. As usually, my model of effective calculability or computability will be the Turing machine in the following sense known as Church-Turing thesis or Turing's theorem (cf. [25]):
Theorem 5. A function that is effectively calculable is a function that can be computed by a Turing machine.
Definition 6. I define a Turing machine to be the 6-tuple where is the set of states with the initial state, is the n-letter machine alphabet, is the set of the possible tape motions left, stop, or right, is the output function, is the state-transition function, and is the motion function.
For my purposes, with F. Cohen [26,27] I define a Turing machine performing temporal functions in the following way:
Definition 7. Let be a Turing machine. Let the tape of be the set where denotes the -th tape cell s.t. is the leftmost tape cell and is the -th empty cell. Further define the set of steps or moves of a Turing machine to be for the -th step taken by and s.t. is the first step taken by . Let now the notion of time instant, denoted by and s.t. is the successor instant of if , coincide with the notion of step or move. Define now the following temporal functions performed by :
With the function triple Cohen defines the history of at time as
and s.t.
where is the initial state of , is the complete history—i.e. the computation—of .
Note in this definition that we consider a Turing machine computation to be complete iff it is performed in finite time in at least one step or move, i.e. for some .
Definition 8. A Turing machine M halts at instant t iff
and
Note that Definition 8 employs the language of first-order predicate logic. Let now , over the alphabet s.t. , , , etc., where is the -th letter in . We define and , where for practical ends we limit to some .
Definition 9. A Turing machine program is a finite sequence of letters from , called a string, constructed as
(ψ)
if
where M is the countable set of all the Turing machines and denotes the program of Turing machine M.
Remark 10. More strictly defined, we have , where is an index, i.e. every Turing machine has at least a code number that unequivocally describes it. This code number is typically the Gödel number of a given Turing machine.
We now prevent the existence of an empty set of Turing machine programs in the following way:
Definition 11. The set s.t. is formally defined as:
Employing the language of second-order logic, we define mathematically a computer virus in the following way:
Definition 12. Let denote a Turing machine as defined above and let us identify a Turing machine with its program s.t. . A computer virus, denoted by , is defined as:
where is as in Definition 9 above and is the string , ..., .
See, e.g., [28] for this language.
We set it so that is the empty Turing machine. See any of the cited texts on computability for the calculation of Gödel numbers for Turing machines.
See [28] for the basic aspects of this language.
This definition, where denotes the set of all viral sets, states that the pair is a viral set iff for each virus and for all the computations of Turing machine we have, for all instants and cells , if the tape head is in front of cell at , and is in its initial state at , and the tape cells starting at cell and ending at cell hold virus , then there exists a virus at time instant and at cell s.t. cell is far enough from position , the tape cells starting at hold virus , and at some time instant s.t. virus is written by .
2.2 Self-Replication and Kleene's Fixpoint Theorem
The formalization in Definition 12 can be abbreviated as
where denotes that Turing machine copies any virus v into set V.
The self-replicating ability of a virus is formally secured by Kleene’s recursion theorem, also known as Kleene’s fixpoint theorem:
Theorem 13. For any computable function , there is an such that .
The proof of this theorem, whose meaning is that the partial computable functions are closed under fixpoint definitions, can be found in any standard work in computability theory (cf. cited literature). A good reference to understand this theorem in the framework of self-replicating machines—and hence of computer viruses—is [29], where it is shown that for any Turing machine there is a partial function , for a countable class of objects called representations, s.t. where is thus the representation of by (e.g., a string of 1s and 0s). Let now ; the author shows that there is an integer s.t. for all inputs , where is the index or code number (the Gödel number) of , i.e. 's formal self-description in the guise of a fixed natural number, yields as output. Intuitively, must be understood as a special Turing machine that, given any , outputs a replica of the Turing machine with code number . Then, the fixpoint theorem shows that there must be a Turing machine that on any input whatsoever outputs its own replica or self-representation by .
Recall that if is a function with , then a fixpoint of is any point such that .
The proof runs as follows: We let be a code number for Turing machine . For any , we let be the constant function whose output on any input is . As the instructions for will depend on we can find a computable function s.t.
By applying the fixpoint theorem we get an integer n s.t.
and hence
But given that by the definition of we have , by setting we get
We can improve on the above results by modifying Kleene's fixpoint theorem in the following way:
Theorem 14. For any computable function , there is an such that .
In this reformulation, I add the detail—that amounts to a giant leap—that the partial computable functions and are computably equivalent, a property that I denote by the symbol “=” and call computable equivalence. By writing “ ”, I emphasize that and yield the same output because the Turing machines with Gödel numbers and compute the same function, whereas the notation “ ” merely denotes that and yield the same value.
2.3 Viral Evolution: Cohen's Largest Viral Set
Any virus is by definition capable of self-replication:
Proposition 15. For all and , we have:
The next best thing is evolution, i.e. the ability of a virus to modify its own code when replicating itself, so that in each replication of v we have it that is a mutation of v. Cohen [26,27] defined this property in the following way:
Definition 16. A virus is said to evolve into a virus if there is a Turing machine s.t. the computation is performed. More specifically, is an evolution of iff, for the pair , there are and s.t. and for all it is the case that and there are s.t. and and .
Theorem 17. For all and all we have for all :
Intuitively, this theorem states that any union of (a finite number of viral sets) is also a viral set. If we next consider that there is a set s.t. and for all it is the case that , we have the following definition:
Definition 18. U is called the largest viral set w.r.t. , denoted by .
Then, the following result follows naturally from Theorem 17 and from the consideration that if , then :
Corollary 19. Let the pair denote that is a viral set w.r.t. , a denotation that is abbreviated as . Then:
We can set the s.t. where denotes the fixed number of evolved forms of a virus . Clearly, the definition of as the union of all the entails that at least one of the , namely s.t. , is a smallest viral set w.r.t. , denoted by . A virus is a virus that does not evolve; formally, we have:
Proposition 20. For all and all s.t. , we have:
Compare this with Proposition 15 above. In the next Section, I explain the practical meaning of this proposition.
3 Evolving Viruses and Further Computability Theory
3.1 Back to the Turing Machine
With the formal definition of a virus at hand, from the viewpoint of computability theory three questions are now posed. In order both to pose them and to reply to them we simplify the halting function defined for a Turing machine (cf. Def. 8):
Definition 21. Given a Turing machine , the function , where is a set of time instants and denotes the state set of Turing machine , is called the halting function for .
Clearly, the halting function for a Turing machine has a value iff at a given time machine halts at state , i.e. iff we have . Otherwise, does not halt; for instance, it loops forever. Recall from Definition 8 that in this case it is not possible to describe the complete computation performed by .
Problem 22. The three questions are as follows:
- Given some code , is there a Turing machine that can decide in finite time whether is a virus? Formally:
- Given a pair , is there a Turing machine that can decide in finite time whether is an evolution of ? Formally:
- Given any string for , is there a particular class of Turing machines that can decide whether is a viral evolution? Formally:
Question 1 is the viral detection problem, Question 2 constitutes the viral evolution problem, and Question 3 is the viral computability problem. Each of these three questions is a decidability problem, i.e. a computability problem for total functions (cf. [30]). More specifically, these total functions are mappings from the set M to the set V. Additionally, a decidability problem requires an algorithm that provides a Yes/No-answer in finite time. Cohen gave a negative answer to the first two problems by reduction to the halting problem (see [13] for the halting problem and for reducibility). With respect to the viral computability problem, the answer is positive: Any string that can be computed by the universal Turing machine W may be a viral evolution. Cohen draws the conclusion that viral evolution exhibits the same computational abilities and power of a Turing machine, so that we have a bijection from M onto V; in particular, there is also a universal viral machine V. If we consider this result as a theorem, then we have the following result associated with it:
Corollary 23. There are exactly viruses.
3.2 Code Camouflage Techniques
Code camouflage is here the technical term for the code-writing techniques employed by virus designers that aim at evading detection and analysis by AVT. From garbage code insertion to real code mutation s.t. for a virus v s.t. where is highly dissimilar w.r.t. v, anything goes; the objective is to disable the detection and analysis techniques employed by the available AVT. There are three main code camouflage techniques, to wit, encryption, polymorphism, and metamorphism (e.g., [31]).
In order to define each of these camouflage techniques we now need a more practical definition of a virus that changes its code in its self-replications:
Definition 24. A pair s.t. where but is a mutating virus. Given a mutating virus , we call any replication or copy a mutation or generation of root virus .
Proposition 25. Let where is a mutating virus. Then, the set is countable.
The proof is intuitively obvious; we let be the root virus and , be its successive mutations or generations.
Let us begin by considering that a mutating virus has two parts to it, to wit, a main body and a decryption code, or decryptor for short. The three main code camouflage techniques can be briefly defined as follows:
Definition 26. Let for some given Turing machine s.t. . If for all s.t.
-
the main body of is encrypted and from generation to generation the decryptor remains constant, we say that the pair is an encrypted virus.
-
the main body of remains constant, albeit encrypted, and the decryptor changes from generation to generation, we say that the pair is a polymorphic virus.
-
both the main body of and the decryptor change from generation to generation, we say that the pair is a metamorphic virus.
To be more precise, we speak of code camouflage w.r.t. viral detection and of code obfuscation w.r.t. viral analysis. In any case, we can also employ the term obfuscation for both detection and analysis.
From this definition, we can make a further distinction by claiming that only polymorphic and metamorphic viruses are truly evolving viruses, with non-evolving viruses constituting the class of monomorphic viruses, or viruses with a single form. Encryption is considered essentially a static camouflage technique; in effect, encryption merely hides the main body of a virus, reason why a common antivirus software can easily detect an encrypted virus, as will be seen in the next Section. This leaves us with two dynamic camouflage techniques of interest for this study, to wit, polymorphism and metamorphism.
3.3 Antiviral Techniques vs. Code Camouflage
Let us divide the antiviral techniques into two major classes, to wit, also static and dynamic techniques. Although static analysis may be quite advanced (e.g., heuristic and spectral analysis) it essentially tries to find a viral signature, i.e. a string of typically sixteen unique bytes that remains unchanged in all the self-copies of a given virus, by scanning or searching in the code. This is a highly successful, usually no-false positives antiviral technique that keeps AVT in the market despite the fast proliferation of viruses in the wild: Every new signature that is identified is added to the software's database. This antiviral technique is adequate for the detection of both simple or encrypted viruses; in this latter case, the code pattern of the decryptor is all that the AVT needs for detection.
A crucial point for the anti-antiviral success of metamorphic viruses lies in the fact that the code mutations in each replication leave fewer than the unique sixteen bytes required for detection. For viruses whose code mutates when replicating themselves static analysis is insufficient and antiviral software resorts to dynamic techniques; instead of a signature database, these techniques compare the suspicious behavior of a given code with a database of known viral behavior. Code emulation, a technique that emulates the decryption process of a given evolving virus in a sandboxed environment, is the most advanced dynamic technique.
Although polymorphic viruses generally pose a challenge to AVT they can be detected by employing emulation. This is not the case with metamorphic viruses, because, as a matter of fact, against what I stated above in Definition 26.3, they need not even have a constant body, let alone a decryptor: All they need is a metamorphic engine. In particular, in a metamorphic virus data is carried as code. I next compare these two types of virus from the viewpoint of the integration of data and program in the viral code. Again, my starting point is a core computability result, to wit, the s-m-n theorem.
3.4 Data and Programs: The s-m-n Theorem
The first step is the formal elaboration on the distinction between data and programs. Let us consider a universal Turing machine s.t. given any partial computable function , where is the index of a given Turing machine and denotes some data, we have . Recall that a Turing machine just is the program ; doing justice to its name, the universal Turing machine is the unique Turing machine that, given any index and data , computes exactly the same output as . Clearly, if is the -ary partial computable function computed by the Turing machine with index , then we have
(★)
See [3] and Ször [32] for comprehensive discussions of malware detection techniques.
where the left side of corresponds to the function computed by the universal Turing machine and the right side of corresponds to the function computed by the Turing machine on the input . The meaning of this equation is that given a universal Turing machine we are no longer allowed to distinguish between data and programs; in the words of virology, both data and programs are potential virus hosts.
Consider now the following result first formulated in [33], the same source as for Kleene's fixpoint theorem:
Theorem 27. (s-m-n theorem) Given , consider the computable function of variables:
Let now define computably. Then, there is a primitive computable function s.t. for fixed numbers
(*)
computably defines
as a function of the remaining variables.
Clearly, then we have
it being the case that the , each denoting the substitution of variable by some constant s.t. for , correspond to data. The juice to be extracted from this at first sight innocuous theorem is that data can be incorporated in a program as a sub-program or, what is the same formally:
3.5 Polymorphic vs. Metamorphic Viruses
It will now be useful, with [34] and [35], to consider an evolving virus from the viewpoint of its core constituent:
Definition 28. The kernel of a virus is a 4-tuple
where and denote respectively data and program, and are two computable predicates, and and are two computable functions.
In practical terms, is the infection trigger condition, is the payload routine, is the payload trigger condition, and is a selection function. Note here that, in contrast to the remaining constituents of a kernel, function S acts solely on programs, altogether neglecting data. We denote that conditions and are satisfied by writing respectively and .
Definition 29. Let be two total computable functions. The pair for some Turing machine is a polymorphic virus with two forms if, for every , it satisfies
and
Intuitively put, in function outputs (1) the payload if the payload trigger condition is satisfied, (2) an evolved replica if the infection trigger condition is satisfied (i.e. the prospective host has not already been infected), or (3) itself otherwise. (Note here Kleene's fixpoint theorem in 3, a behavior that can be called imitation.) In the roles of functions and are inverted and we have a polymorphic virus with only two forms. This is to be contrasted with the following definition, which gives us the infinite set of polymorphic generations:
Definition 30. A total computable function is a polymorphic virus with an infinite number of forms if, for all , it satisfies
and if, for every , we have .
Clearly, we have where specifies a polymorphic largest viral set for some Turing machine . Figure 1 displays the general structure of a polymorphic engine.

Figure 1: General structure of a polymorphic engine.
As for the metamorphic viruses, we have the following results:
Definition 31. Let be two different total computable functions. The pair is a metamorphic virus if, for all , it satisfies
and
where , , , and are different from, respectively, , , , and .
This definition can be generalized to any tuple of total computable functions giving us the set where specifies a metamorphic largest viral set for some Turing machine . To be noted is the fact that the main difference between the polymorphic and the metamorphic viruses lies in the fact that . In practice, this formalization is realized in two very distinct mutation engines, as shown in Figures 1 and 2.

Figure 2: General structure of a metamorphic engine.
4 Viral Metamorphism and Formal Grammars
4.1 The Viral Decision Problem and Formal Language Theory
It is assumed here that a successful virus is a largest viral set that escapes detection by an AVT. As already claimed above, metamorphic viruses are currently the most successful in the wild. Thus, it is important to elaborate on why metamorphism poses a greater challenge to AVT than polymorphism. To put it in a nutshell, we say that metamorphic viruses constitute a more intractable decision problem than polymorphic ones. In effect, broadly conceived tractability is a measure of practical computability, or how difficult it is to solve a given decision problem for a specific language; we say that a decision problem is intractable, or unsolvable, if there is no efficient algorithm that solves it.
It will now be relevant to remark that metamorphism is a code property that finds applications other than in malware. In particular, metamorphism is employed in the software industry to protect proprietary code from attacks (e.g., [36]). It is precisely the intractability of metamorphic coding that secures the protection of the proprietary code, so the reader can have an intuitive conception of how intractable metamorphic code is. With respect now to viral metamorphism, the decision problem for pure metamorphic viruses is unsolvable, i.e. given a virus v and a largest viral set , there is no algorithm that answers the question
if v is a pure metamorphic virus.
I shall shortly give a definition of a pure metamorphic virus. In order to analyze this it will be useful to move from the vocabulary and formalism of F. Cohen, which directly captures virology, to that of N. Chomsky, which deals with grammars and languages. As seen above, viruses just are computer programs, and these in turn just are strings of symbols of a given language. The viral decision problem can then be posed simply as the general decision problem for a given formal language, i.e. as
(DP)
where w is a given word and L is a specific language. This move will then allow us to approach the intractability of metamorphic viruses in the framework of the basic complexity classes P and NP.
For the sake of self-containment, I provide here the essentials of this classification. The reader is referred to [37] for a comprehensive textbook in complexity theory.
Definition 32. Let denote a Turing machine on an input string such that . Let denote the time complexity of , i.e. the maximum number of moves that makes before halting on input string . We say that runs in polynomial time, or that has polynomial-time complexity, iff there is a polynomial such that runs in time bounded by , , such that for .
Recall that the notation denotes that is an (asymptotic) upper bound for . Consider now that a Turing machine can be either deterministic (if the next step in a computation is unique) or non-deterministic (otherwise), and let us denote them by DTM and NTM, respectively.
Definition 33. Let be given for some input string such that .
(1) We say that a DP is solvable in deterministic polynomial time iff there is a DTM that solves it in a number of moves bounded above by a polynomial . This defines the complexity class that contains all languages that are decidable by a DTM with polynomial-time complexity, i.e.
(2) We say that a DP is solvable in nondeterministic polynomial time iff there is an NTM that solves it in a number of moves bounded above by a polynomial . This defines the complexity class NP that contains all languages that are decidable by an NTM with polynomial-time complexity, i.e.
Theoretically, one is told that the problems in P are those for whose solution there is an efficient algorithm, whereas those in NP can have their solution efficiently verified; in practice, problems in P are tractable while NP-problems may be intractable. The NP-complete class is constituted by the hardest-to-solve problems in the NP class.
Recall from above that for every virus we have where . Note now that is the set of all the strings, including the empty string , that can be built over alphabet . Any subset is a language if contains only terminal symbols. The strings that constitute a given language are constructed according to the rules of a specific grammar. The following definition is very general, but Table 1 provides specifications. (See [13] for further contents).
Definition 34. A formal grammar is a 4-tuple , where for the finite disjoint sets and of variable symbols and terminal symbols, respectively, is called the alphabet, is the start symbol, and is a finite set of production rules (abbr.: ) of the form , read “ is rewritten as ,” where is the left-hand side of the rule (abbr.: LHS), , , and is the right-hand side of the rule (RHS), so that the empty symbol “ ” is allowed only on the RHS.
Note in this definition the notation to denote . By a slight abuse of terminology, is also called a generative system and the language generated by is defined as:
Definition 35. A formal language L is a set of strings of terminal symbols generated by a formal grammar G, i.e.
where “” denotes a string of terminal symbols (the concatenation of the terminal symbols ) called a word, “” denotes a derivation step such that we have for the sentential form in derivation steps, and “*” (Kleene star) denotes the reflexive and transitive closure of the relation . A derivation of a word from is a finite sequence of steps each of which is the application of some production rule in :
A derivation is called a leftmost derivation, denoted by , (a rightmost derivation, denoted by ) if at each step a production rule is applied to the leftmost (respectively, rightmost) variable in .
The sequence of the k rules applied in n steps in a derivation is called a parse and is defined as:
A parse of a word w that is represented as a tree is called a parse tree for w, denoted by . A parse is said to be left (right) if the rules are applied in a leftmost (respectively, rightmost) sequence.
Importantly, there is a word derivation or parse iff there is a recognizer that accepts the given word as an element in . This allows for a reformulation of the definition of a language as follows:
Definition 36. A formal language L is a set of words accepted by a recognizer M:
Figure 3 shows the basic postulate of the Chomsky hierarchy, to wit, for every language there is both a grammar that generates it and a recognizer that accepts it. This postulate provides us with the following core result:

Figure 3: The basic postulate of the Chomsky hierarchy.
Theorem 37. Given a grammar G and a recognizer M, M decides whether . Thus, M is a solution for the decision problem for a given language .
The proof of this theorem depends on the recognizer and its corresponding grammar type; see [13] for the proofs of the four languages of the Chomsky hierarchy. I give a sketch of the proof for the CFGs, because I shall require this result below: If is a CFG, then for any word there is a pushdown automaton that constructs a leftmost derivation for it s.t. . Note that the CFGs have the property that there is a one-to-one correspondence between leftmost derivations and left parses.
It will now be convenient to elaborate briefly on the simplest grammars in the Chomsky hierarchy, the linear grammars.
Definition 38. A linear grammar is a grammar with rules of the form in which , , and . A linear grammar can be right- or left-linear if it has rules of the form or , respectively, for , . In a linear grammar, every derivation is either a leftmost or a rightmost derivation. A left- or right-linear grammar is a regular grammar. The words generated by a regular grammar follow a given pattern called regular expressions.
Example 39. Consider the following grammar with
This is a right-linear grammar. The language generated by this grammar is defined as:
The regular expression for this language is . The derivation of the word is given by
Figure 4 displays the corresponding parse tree.
Table 1: The Chomsky hierarchy. (Adapted from [13])
| Type | Name of Grammar | Language | Recognizer | Decision Problem | |
|---|---|---|---|---|---|
| 0 | Unrestricted (UG) | Recursively enumerable (REL) | Turing machine | Unsolvable | |
| 1 | Context-sensitive (CSG) | Context-sensitive (CSL) | Linear-bounded automaton | NP | |
| 2 | Context-free (CFG) | Context-free (CFL) | Pushdown automaton | NP | |
| 3 | Regular | Regular (REG) | Finite automaton | P |

Figure 4: Parse tree for the word generated by grammar .
4.2 Viral Polymorphism and Polymorphic Grammars
I begin this Section by giving an example of a polymorphic grammar that has starred in the literature (e.g., [14]).
Example 40. Consider the grammar where the production set is as follows:
This is a right-linear grammar that generates words of the form
where . Note that this grammar has in fact fourteen production rules; we managed to reduce this number to three by collecting rules with the same LHS as alternative RHSs. This allows for enumeration of the rules as
etc.
The simplest word this grammar generates is rt, namely when we have . The word arcccdt belongs to the language generated by this grammar. The derivation of this word is given by:
See Figure 5 for the parse tree for this word.
Definition 41. With respect to Example 40, let us call the word a root word of and the expression its mutation pattern.

Figure 5: Parse tree for the word arcccdt generated by the polymorphic grammar .
Some basic mutation rules are as follows:
Definition 42. Let , be a mutation of .
-
If , mutation is called an expansion of ; otherwise, it is called a compression of .
-
If but while the letters in are exactly the same as in , we say that is a permutation of .
In Example 40, there is a single root word for the given language, but this need not be the case; a language may have as many root words as required. If the grammar at hand is a regular grammar, the mutation pattern can be given by a regular expression. It should be easy to see that a mutation pattern should be constructed in such a way as to allow for potentially infinite mutations of a given root word.
Definition 43. Let be a formal grammar. G is called a polymorphic grammar if it generates multiple mutations of root words of .
Example 44. Let us consider again the grammar in Example 40. If the root word is composed of two instructions solely, to wit, and , then the components in correspond to garbage code insertion. We may make it so that generates further polymorphic code by introducing production rules for the permutation of the instructions, so that we have also a root word and a mutation pattern .
We can find further ways to make it more difficult to be able to identify words of this language, but this grammar generates a decidable language, as is shown by the fact that (unambiguous) parse trees can be built for every of its words. (See Fig. 5.) This is a consequence of employing a regular language, for which the decision problem is in the complexity class P (cf. Table 1). One may in fact employ a CFG or even a CSG to generate a polymorphic virus, but this will only move the problem from class P to class NP. To be sure, this might make it far more difficult for an AVT to identify a polymorphic virus. Nevertheless, if you check Table 1 for the status of the decision problem for the different languages you will see that only the RELs have an unsolvable decision problem; hence, this polymorphic language can pose a challenge to an AVT only if it is generated by a UG.
4.3 Pure Metamorphic Viruses and the van Wijngaarden grammars
From the contents above, it should be evident that metamorphic viruses successfully evade antiviral detection and analysis by keeping their functionality—their meaning—while changing their appearance—the code—in each and every self-replication. This, however, can be attained by means of polymorphism, so there must be additionally something that accounts for the greater challenge posed to an AVT by a metamorphic virus. The intuition to be extracted from the formalization in Section 3.5 above is as follows: Polymorphism is the case when from mutation to mutation a virus changes its words; as seen above, a regular grammar can be employed to that end. In contrast, metamorphism entails not only this word change phenomenon, but also the change from mutation to mutation of the very mutation engine or, what is the same if we identify a grammar with the mutation engine, the grammar itself. This poses an additional challenge—and a substantial one at that—to the virus designer. It suffices to compare the general structure of a polymorphic engine (see Fig. 1) with that of a metamorphic one (Fig. 2) to see that the task ahead for a metamorphic virus designer is no simple one.
The ways to design a virus that has the evolving property of changing its appearance while preserving its functionality have been well explored in the antiviral literature (e.g., [4,8,14,38,39]). Essentially, the methods listed in these references include actions that make it more difficult for an AVT to identify and/or analyze a metamorphic virus; examples of such actions are instruction reordering, garbage code inclusion, code permutation, data reordering, etc. These actions can take up to 90% of the virus' code for the metamorphic engine.
One aspect that contributes to an undecidable problem in formal language theory is when we succeed in generating several levels to a single language s.t. we have , where . The decision problem for such a language becomes more complex to solve if there is more than one grammar involved, so that we have languages , for . As a matter of fact, it suffices to generate a language with only two levels, in the sense that the language is typically undecidable. Certainly with this mathematical result in mind, E. Filiol proposed the following formal-grammar definition for a metamorphic virus [14]:
Definition 45. Let and be two grammars where is a set of formal grammars, is the (starting) grammar , and is a rewriting system w.r.t. . A metamorphic virus is described by and every of its mutated forms is a word in .
This definition is redundant in the following sense: It is not required that we have two distinct grammars , as specified in Definition 45; it suffices that the language be generated by a two-level grammar, namely a van Wijngaarden grammar (abbr.: WG), in which case we write . Filiol leaves it as an open question whether Definition 45 is a particular case of a WG. I do not aim here at closing the question, but simply at showing that a metamorphic virus can in principle be designed entirely by employing solely a WG.
Definition 46. Let denote an arbitrary WG and let . We say that is a pure metamorphic virus if for any mutated form of .
Claim 47. A pure metamorphic virus can be constructed.
The papers [40,41] explore the design of metamorphic viruses employing WGs in practice.
In order to support this claim I need to show four things: (1) every word generated by a WG belongs to the language ; (2) the number of mutations of a given virus can in principle be infinite, namely in the sense that there is a possibly infinite number of strict subgrammars associated with a single WG; (3) a virus generated by a WG is a metamorphic virus, i.e. it preserves functionality in syntactic change; and (4) the decision problem for languages generated by WGs is unsolvable.
The following is a summary elaboration on WGs for the sake of self-containment, and the reader is referred to [19,20] and [21] for comprehensive discussions on the syntax and the semantics, respectively, of WGs.
Definition 48. A WG is constituted by a deep grammar and a surface grammar. (A) The deep grammar is a 7-tuple
where
, , , , and are sets of notions, and and are sets of rules built over these notions. The sets of notions are as follows: is a set of metanotions and is a set of protovariables with , is a set of hypernotions, is a set of terminals, and s.t. is the start hypernotion. The elements in the set are called protonotions. Set contains the metarules of the grammar and set contains its hyper-rules. (See Table 2 for the form of these rules.)
(B) The surface grammar of a WG is a 4-tuple
where is a set of strict notions, is a set of terminal protonotions, is the start strict notion derived from , and is a set of strict production rules. (See Table 2 for the form of these rules.)
Table 2: Grammars and levels of a WG with respective rules.
| Grammar & Level | Rule | LHS | RHS | |
|---|---|---|---|---|
| Metanotion | Meta-alternatives in | |||
| Hypernotion | Hyper-alternatives in | |||
| Strict Notion | Strict Alternatives in |
Remark 49. Notions are sequences of symbols s.t. called syntactic marks that can be uppercase or lowercase, called respectively large syntactic marks and small syntactic marks.
This distinction is crucial to segregate the different kinds of notions: Metanotions are written with large syntactic marks, protonotions are written with small syntactic marks, and hyper-notions are written with both. Terminal symbols must be followed by “symbol.” For example, a symbol corresponds to the terminal symbol a. I remark that metanotions can also be terminal (e.g., ALPHA symbol).
The rules in specify which replacements by protonotions are admissible in for the metanotions and the rules in describe the properties that the words generated by satisfy. Grammars and interact in the following way:
Definition 50. Let and denote respectively a metarule and a hyper-rule. A uniform replacement rule, written , instructs that the metanotion in metarule be replaced uniformly in hyper-rule by the protonotion .
I abbreviate as and I write to denote a in . The interaction of the deep and surface grammars of a WG is as follows: A hyper-rule derives a strict production rule whenever one or more rules are applied to it. Note thus that whereas the grammar levels describe the URRs of a given language the interaction between the deep and the surface grammar actually generates the language. We have the following definitions:
Definition 51. Given a WG G, let
for arbitrary . Then, describes the language of as
where is the start hyper-notion s.t. we have equivalently the language
The language generated by G is defined as
where is the start strict notion.
Note that is not a word derivation proper: It is rather the description of the *-step derivation from to based on . In effect, describes the derivation, or generation, of any specific word for in the sense that a applied uniformly to all the hypernotions in containing the metanotion derives a strict production rule s.t. the protonotion is in . We thus have the set of production rules
Table 3: Grammars and levels of a WG and corresponding rules.
| Grammar | Subgrammar | Level | Rules |
|---|---|---|---|
| Deep | Metagrammar | Metarules | |
| Hypergrammar | Hyper-rules | ||
| Surface | Strict Grammars | Strict Production rules | |
where denotes the derivation of a rule in from the -th rule in . A rule in can derive an infinite number of strict production rules, reason why parse trees for languages generated by WGs are exclusively based on the hyper-rules. This is an important remark, because a WG whose surface grammar has only a finite number of strict production rules is no different from a CFG. On the other hand, a hyper-rule need not derive any strict production rule.
As a matter of fact, rather than generating a single language the grammar actually generates a (possibly infinite) number of strict languages. When a protonotion occupies the LHS of a strict production rule it is called a strict notion and is abstractly denoted by .
Definition 52. Let be a strict notion in a production rule and such that is the strict grammar for A string of terminal symbols derived from , denoted by , such that we have , is called a strict word. The set of all the strict words that can be generated by is called the strict language of , and it is defined as:
Table 3 gives the complete structure of a WG .
I now give an example of a simple WG that captures the contents above.
Example 53. The WG , abbreviated as Alpha, is given by the following rules in its deep grammar:
| ALPHA | :: | a; b; c; ...; y; z. | |
|---|---|---|---|
| s | : | ALPHA. | |
| ALPHA | : | letter ALPHA symbol; | |
| ALPHA, letter ALPHA symbol. |
Metarule has twenty-six meta-alternatives, hyper-rule has a single hyper-alternative, and hyper-rule has two hyper-alternatives. These rules describe the language
For instance, by applying (ALPHA, a), the (rightmost) derivation of the word aaa is as follows:
Note that the strict notion can coincide with the strict start notion s.
Note in this word derivation that the comma is “absorbed” when its role of separating strings of terminals from strings of variables is finished, and the same happens to the notion symbol when letter a symbol is substituted for the terminal Grammar Alpha generates twenty-six strict languages, one for each of the letters of the Roman alphabet. In effect, we have:
We thus have the strict languages:
The (ALPHA, a) applied to the entire set of Alpha gives a strict subgrammar, namely the set of strict productions that generates the surface strict language ,
where I abbreviate “letter a symbol” as “a”. Thus, the language generated by the WG Alpha is the union of all the strict languages generated by its strict subgrammars, i.e.
I now retake Claim 47 by addressing the points (1) through (4) above.
(1) THE LANGUAGE
From Definition 51, we can infer the identity
Theorem 54. Given a WG G, every word in is a word in .
Proof. The deep grammar does not generate words; rather, it specifies the URRs admissible in the grammar. The words generated in by the rules derived from are those strings in which these admissible URRs are implemented.
In effect, for every word , the parse tree is built over the grammar . This is so because the number of rules in can be infinite, whereas the number of rules in and , which correspond to CFGs, is necessarily finite.
(2) WGS GENERATE A LARGE, POSSIBLY INFINITE, NUMBER OF GRAMMARS
Such notions are called paranotions.
I stated above that what distinguishes a metamorphic from a polymorphic virus in practice is that the former changes not only the words from mutation to mutation, but also the grammar. It should now be easy to see how a WG can generate a large, possibly infinite, number of grammars by its surface grammar. I speak here, of course, of the strict subgrammars. I give an example by way of a constructive proof.
Example 55. Consider the following deep grammar
| SEQUENCE | :: | statement; digit; letter. | |
|---|---|---|---|
| ALPHA | :: | a; b; ...; z. | |
| NUMBER | :: | zero; one; ...; nine. | |
| N1 | :: | ||
| N2 | :: | ||
| program | : | statement sequence. | |
| statement | : | N1 letter sequence, becomes symbol, N2 digit sequence. | |
| letter | : | letter ALPHA symbol. | |
| digit | : | digit NUMBER symbol. | |
| SEQUENCE sequence | : | SEQUENCE; SEQUENCE sequence, SEQUENCE. |
It is easy to see that this deep grammar describes a language of words of the form “” where is a sequence of letters, is the becomes symbol, and is a sequence of digits. For this reason I call this grammar AlphaDigit (abbreviated as AlphaDig). For instance, the word “age ” belongs to the language described by , i.e. the language . The representation table for this grammar is given in Table 4 in an abbreviated way; note in particular the typographical characters for the terminal notation for digits.
Table 4: Representation table (abbreviated) for .
| Terminal Notation | Typographical Character |
|---|---|
| becomes symbol | |
| letter a symbol | |
| letter z symbol | |
| digit zero symbol | |
| digit nine symbol |
The start hypernotation is program. The language of is
The RHS of metarule instructs that the metanotion N1 (respectively, N2) is to be replaced by a sequence of letters ( digits, respectively). I simplify here the rules for exponentiation; see [19-21] for comprehensive discussions.
which can be further specified as:
contains already all the words of as non-terminal words, even if the syntactic mark “:=” occurs in as a terminal.
The following are the production rules of the WG :
| program | :\ statement sequence. | |
|---|---|---|
| statement sequence | : statement; statement sequence, statement. | |
| statement | : n letter sequence, becomes symbol, m digit sequence. | |
| n letter sequence | : letter; letter sequence, letter. | |
| letter | : letter a symbol; ...; letter z symbol. | |
| m digit sequence | : digit; digit sequence, digit. | |
| digit | : digit zero symbol; ...; digit nine symbol. |
Note that this set of production rules is infinite, because for each program we must specify beforehand the length of the letter sequence (rule ) and the length of the digit sequence (rule ). That is, each program is specified as an program, for . For instance, the word “” is generated by the strict grammar . The language generated by this WG is thus the infinite (but recursively enumerable) strict language:
(3) WGS NATURALLY PRESERVE MEANING IN SYNTACTIC CHANGE
Above, I defined metamorphism generally as the code property that preserves meaning in syntactic change. WGs do this by specifying a fixed set of Cartesian products in what can be called an intrinsic semantics (cf. [21]).
Definition 56. Let an atomic metarule be semantically defined as
where denotes a metanotion and denotes a protovariable. A WG semantics is the (possibly infinite) set of pairs formed by a pairing function that pairs types with values as stipulated in the metarules. I accordingly call this a type-by-value uniform replacement semantics (abbr.: TVURS).
It is the coincidence , where denotes the semantics of a strict language generated by a WG , that provides a WG language with metamorphism. See [21] for the formal aspects of this coincidence.
Example 57. Let us consider again the WG AlphaDig (for the sake of simplicity, I omit the URRs for exponentiation). We have the set
that specifies all the URRs for this grammar. It is easy to see that .
(4) WGS ARE RELS
Theorems 58 and 59 below handle the fourth aspect listed above.
Theorem 58. A language is a REL iff there exists a WG s.t. .
See [42] for the original proof. However, I remark that a language generated by a WG is a REL only if the set in is infinite; otherwise, it is equivalent to a CFL. Additionally, there are syntactic aspects that determine the unsolvability of a language generated by a given WG (see [20]). In particular, we have the following result:
Theorem 59. It is undecidable whether or not an arbitrary WG has the property that for each leftmost derivation there is at most one left parse.
Instead of the proof, which the reader can find in [43], I give an example that shows how easy it is to construct a WG for which the decision problem is unsolvable via the unsolvability of the parsing problem.
Example 60. Consider the following deep grammar for a given WG in which :
| A | aA; a. | ||
|---|---|---|---|
| B | A. | ||
| s | : | A; B. | |
| A | : | . | |
| B | : | . | |
| : | a symbol. |
Obviously, by hyper-rule 4 this WG has a single strict language such that . Then, there are infinitely many leftmost derivations for the single left parse :
Conversely, there are two left parses for the leftmost derivation , to wit:
Recall from the remarks on Problem 22 that the viral detection problem and the viral evolution problem were given negative answers by F. Cohen, but he answered the viral computability problem in an affirmative way, in the specific sense that there is a bijection from the set V of all viruses to the set M of all the Turing machines. I now state the challenge posed by a pure metamorphic virus to an AVT:
Problem 61. Let be a pure metamorphic virus. Then, for a WG. To identify as a virus, an AVT must embed the Turing machine s.t. .
References
-
Ludwig, M. A. (1991). The little black book of computer viruses. American Eagle Press.
-
Ludwig, M. A. (1995). The giant black book of computer viruses. American Eagle Press.
-
Filiol, E. (2005). Computer viruses: From theory to applications. Springer-Verlag France.
-
Filiol, E. (2007). Techniques virales avancées. Springer-Verlag France.
-
Bonfante, G., Kaczmarek, M., & Marion, J.-Y. (2006). On abstract computer virology from a recursion-theoretic perspective. Journal in Computer Virology, 1(3-4), 45-54.
-
Zbitskiy, P. V. (2009). Code mutation techniques by means of formal grammars and automata. Journal in Computer Virology, 5(3), 199-207.
-
Filiol, E. (2012). Malicious cryptology and mathematics. In J. Sen (ed.), Cryptography and security in computing (pp. 23-50). Rijeka & Shanghai: InTech.
-
Beaucamps, P. (2007). Advanced metamorphic techniques in computer viruses. International Conference on Computer, Electrical, and Systems Science, and Engineering - CESSE'07, Nov. 2007, Venice, Italy.
-
Konstantinou, E. (2008). Metamorphic viruses: Analysis and detection. Technical Report RHUL-MA-2008-02. Royal Holloway, University of London.
-
Ször, P. (2000). The new 32-bit medusa. Virus Bulletin, Dec., 8-10.
-
The Mental Driller (2003). Metamorphism in practice. 29A E-zine.
-
Zhang, Q. & Reeves, D. S. (2007). Metaaware: Identifying metamorphic malware. In Proceedings of the Annual Computer Security Applications Conference (ACSAC) (pp. 411-420). IEEE.
-
Augusto, L. M. (2021). Languages, machines, and classical computation. 3rd ed. London: College Publications.
-
Filiol, E. (2007). Metamorphism, formal grammars and undecidable code mutation. International Journal of Computer and Information Engineering, 1(2), 281-286.
-
Ször, P. & Ferrie, P. (2003). Hunting for metamorphic. Symantec Security Response White Paper.
-
Spinellis, D. (2003). Reliable identification of bounded-length viruses is NP-complete. IEEE Transactions on Information Theory, 49(1), 280-284.
-
Filiol, E. (2007). Formalisation and implementation aspects of k-ary (malicious) codes. Journal in Computer Virology, 3(2), 75–86.
-
Harter, G. T. (2020). Metamorphic and polymorphic techniques for obfuscation of k-ary malicious codes. M.Sc. in Computer Science. Naval Postgraduate School, Monterey, California. (Security Classification of Report: Unclassified.)
-
Augusto, L. M. (2023). Two-level grammars: Some interesting properties of van Wijngaarden grammars. Omega - Journal of Formal Languages, 1, 3-34.
-
Augusto, L. M. (2023). The van Wijngaarden grammars: A syntax primer with decidable restrictions. Journal of Knowledge Structures & Systems, 4(2), 1-39.
-
Augusto, L. M. (2024). Little ado about meaning: The intrinsic semantics of van Wijngaarden grammars. Journal of Knowledge Structures & Systems, 5(2), 1-42.
-
McAfee (2005). McAfee virtual criminality report. Technical report. McAfee Inc.
-
Soare, R. I. (1996). Computability and recursion. Bulletin of Symbolic Logic, 2, 284-321.
-
Soare, R. I. (1999). The history and concept of computability. In E. R. Griffor (ed.), Handbook of computability theory (pp. 3-36). Amsterdam: North-Holland.
-
Soare, R. I. (2016). Turing computability. Theory and applications. Berlin & Heidelberg: Springer.
-
Cohen, F. (1984). Computer viruses - Theory and experiments. Computers & Security, 6, 22-35.
-
Cohen, F. (1986). Computer viruses. Ph.D. Thesis at the University of Southern California.
-
Augusto, L. M. (2019). Formal logic: Classical problems and proofs. London: College Publications.
-
Rogers, H. (1967). Theory of recursive functions and effective computability. New York, etc.: McGraw-Hill.
-
Cutland, N. J. (1980). Computability. An introduction to recursive function theory. Cambridge, etc.: Cambridge University Press.
-
Rad, B., Masrom, M., & Ibrahim, S. (2012). Camouflage in malware: From encryption to metamorphism. International Journal of Computer Science and Network Security, 12, 74-83.
-
Ször, P. (2005). The art of computer virus research and defense. Addison-Wesley.
-
Kleene, S. K. (1938). On notations for ordinal numbers. Journal of Symbolic Logic, 3(4), 150-155.
-
Zuo, Z. & Zhuo, M. (2004). Some further theoretical results about computer viruses. The Computer Journal, 47(6), 627-633.
-
Zuo, Z., Zhu, Q., & Zhou, M. (2005). On the time complexity of computer viruses. IEEE Transactions on Information Theory, 51(8), 2962-2966.
-
Caliandro, P., Ciccaglione, M., Pepe, A., Bianchi, G., & Pellegrini, A. (2025). VMorph: A virtualization/metamorphic framework for binary obfuscation and intellectual property protection. In Proceedings of the Joint National Conference on Cybersecurity (ISASEC & SERICS), Bologna.
-
Arora, S. & Barak, B. (2009). Computational complexity. A modern approach. Cambridge: Cambridge University Press.
-
Campion, M., Dalla Preda, M., & Giacobazzi, R. (2021). Learning metamorphic malware signatures from samples. Journal of Computer Virology and Hacking Techniques, 17, 167-183.
-
Desai, P. & Stamp, M. (2010). A highly metamorphic virus generator. International Journal of Multimedia Intelligence and Security, 1(4), 402-407.
-
Gueguen, G. (2010). Van Wijngaarden grammars, metamorphism and k-ary malwares. arXiv preprint. arXiv:1009.4012.
-
Gueguen, G. (2011). Van Wijngaarden grammars and metamorphism. 6th International Workshop on Frontiers in Availability, Reliability and Security 2011 (ARES/FARES'11), Vienna, Austria.
-
Sintzoff, M. (1967). Existence of a Van Wijngaarden system for every recursively enumerable set. Annales de la Société Scientifique de Bruxelles, 81, 115-118.
-
Wegner, L. M. (1980). On parsing two-level grammars. Acta Informatica, 14, 175-193.