Network Algorithms Flashcards

1
Q

What are the six steps to Prims algorithm (graphically) ?

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are some common errors in doing prims algorithm graphically?

A
  • not starting from specific node given in the question
  • forming a cycle by accident
  • not looking at all the connected vertices
  • not showing working out of each edge
  • not stating the total weight
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the steps to Prims algorithm (tabular)?

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What are some common errors when doing Prims Algorithm (tabular)

A
  • not deleting a row
  • not looking down on all the avaible rows
  • not recording edges and weights
  • not showing working out
  • not stating the total weight of MST
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is a greedy algorithm?

A

it maximises the immediate rewards without considering future choices/consequences

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Why are the steps for carrying out Kruskal’s algorithm?

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What are the common errors in kruskals algorithm?

A
  • not listing the order of arcs
  • accidentally forming cycles (constnatly look at the graph)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Why can kruskals algorithm not be used in tabular form?

A

no way of knowing when cycle will be made

∴ cannot be used by computers

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

what is a common mistake in dijkstras?

A

not starting the order of becoming permenant from 1

this is dijkstras not critical path

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What are the steps for Dijkstra’s algorithm?

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

How would you find the shortest route and length from this completed

A
17
Q

what is the complexity of kruksals, primms and dijksras?

A

O (n^^2)
* Dijkstra’s is as a function of number of vertices
* Primms/ Kruksals is a function of the number of edges

18
Q
A
19
Q

What is the shortest distance from A-E and A-F

A