Skip to content

Doc: Graph transformation process #40

Closed

Description

@pfannkuch3n

Background

One main objective of uesgraphs is to generate modelica code based on an uesgraphs and another is to visualize the results or even analyze them properly. While uesgraphs is a graph representation of for example an heating network, a modelica simulation is an object-oriented approach with pipes. A pipe has furthermore ports, where other pipes, or more precise the ports of other pipes, are connected with. Some sizes are constant over a pipe like the mass flow (extensive sizes) and some are constant on ports (intensive) like pressure. In a graph representation one would assign the mass flow to an edge and the pressure to a node. So while its easy to assign a pipe to an edge its mor complicate to assign a port to a node in a bidirectional heating network. The picture below show the difference when plotting:

Image
Graph representation in uesgraphs

Image
Graph representation in modelica

To map the simulation results properly onto an uesgraphs the first transformation from uesgraph to modelica has to be understood.

Key findings

Before the modelica code is generated a new uesgraphs object is created where nodes and edges are switched. Every edge of the former uesgrpahs becomes a node, what later gets a pipe. Every node is then an edge connecting two nodes (later pipes). The new edges are kind of the blue connection lines in the upper picture

In a uesgraph representation from above that would be:

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions