Creating a directed graph in Matlab using Labview inputs

10 views (last 30 days)
I'm working on a project that creates a directed graph in MATLAB (digraph, later I will use shortestpath) with LABVIEW inputs that have been saved from a Webservice regarding surfaces and machining line representation. I added a screenshot with an example of the input I am working with:
See image1
n - represents the number of inputs that have been made (surfaces) t - represents the nodes (surfaces) that have been saved (s1, s2, s3, s3') The 3rd node repeats with a ' character because a new operation will be made on the same surface so it basically starts from
x - represents source nodes dx - represents the sink of the source nodes (x and dx are nodes that must link, from x to dx)
What I want to achieve is a directed graph using these arrays of n nodes (the code should work for any number of input nodes), the relations between x and dx and display them in this way:
See image2
So far I think: For the labels I assume I need to use a For an whenever t[x] repeats I would add a '. I still have no idea how I would includ x and dx into digraph
I'm not as proficient in MATLAB so I wanted to make a post and ask for help regarding the algorithm while I work on it.

Answers (0)

Categories

Find more on Spline Postprocessing in Help Center and File Exchange

Products


Release

R2019a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!