Petra Heijnen

125 Reputation

2 Badges

19 years, 97 days

MaplePrimes Activity


These are questions asked by Petra Heijnen

I use the MaxFlow command from the GraphTheory package, but I don't understand the results that I get.
The max flow value is okay, but the matrix in which the flows from node to node are given, is not what I expected.

Is this problem caused by the fact that the graph is not directed? I don't want to use a directed graph, because flows can choose only one of both directions.

H:=Graph(6,{{1,2},{1,3},{2,4},{4,6},{3,5},{5,6},{4,5}},weighted):
DrawGraph(H,style=spring);
MaxFlow(H,1,4);

As a solution I get:

Download 4171_BioBased.zip
View file details

I've got an XML file from someone, which contains some data from a network. First a list of all the nodes and then a list of all edges.

I would like to read this data in Maple to define a Graph, but I don't know how to do that. Could you please help me?

I added the file as a zip (because XML is not allowed). I hope that that is clear.

As the title says already:
Is it possible to stop Maple when executing the entire worksheet with !!! ?

I want to check some intermediate output before the rest of the worksheet should be executed.
I searched for help on 'break', "quit', "wait', "pause', 'exit', but can't find a command that does the thing I want.

Any ideas?

Petra

I have got a discrete power law distribution from which I would like to sample.
I tried to define a new distribution, but didn't succeed so far.
The probability p(k) = C(gamma)*k^(-gamma),

With ProbabilityTable I've got the problem that my distribution is not limited to a certain range. It starts from a lower limit kmin, but goes to infinity.

And again, I've got a problem with drawing graphs with DrawGraph. I've generated some scale-free networks with Barabasi's algorithm (not implemented in Maple 12. I did that myself).
Now, I wanted to display these graphs in a nice way, in which you can clearly distinguish the hubs from the other nodes. I thought that the "style=spring" command would do so, but it puts nodes very near to each other, sometimes even overlapping.
Is there another solution to draw such a scale-free network in a nice way?
Thanks for helping.

1 2 3 4 Page 3 of 4