Abstract:For graphical modeling languages, there are three problems on the notation definition: How to define graphical symbols for modeling elements; How to define the location relations between symbols; How to map the symbols and the location relations to the abstract syntax. For model transformation and code generation, the notation has to be represented as models. This paper proposes the notation definition metamodel (NDM) for metamodeling tools by summarizing and analyzing the notation of UML and UML family. For the three problems on notation definition, NDM is composed of three parts: basic figures and layouts, location relations and abstract syntax bridges. The notation model defined by NDM can be transformed to usable source codes. This paper also makes a comparison between NDM and other methods, and the results show that NDM have some advantages over other methods. NDM has been implemented in PKU MetaModeler, and some practices of NDM are introduced.