In this paper, we introduce a novel method to formally represent elements of control engineering knowledge in a suitable data structure. To this end, we first briefly review existing representation methods (RDF, OWL, Wikidata, ORKG). Based on this, we introduce our own approach: The Python-based imperative representation of knowledge (PyIRK) and its application to formulate the Ontology of Control Systems Engineering (OCSE). One of its main features is the possibility to represent the actual content of definitions and theorems as nodes and edges of a knowledge graph, which is demonstrated by selected theorems from Lyapunov’s theory. While the approach is still experimental, the current result already allows the application of methods of automated quality assurance and a SPARQL-based semantic search mechanism. The feature set of the framework is demonstrated by various examples. The paper concludes with a discussion of the limitations and directions for further development.