Beruflich Dokumente
Kultur Dokumente
GRAPH MATRICES
AND
APPLICATIONS
Problem with Pictorial Graphs
• Graphs were introduced as an abstraction of software structure.
• Whenever a graph is used as a model, sooner or later we trace paths
through it- to find a set of covering paths, a set of values that will sensitize
paths, the logic function that controls the flow, the processing time of the
routine, the equations that define the domain, or whether a state is
reachable or not.
• Path is not easy, and it’s subject to error. You can miss a link here and there
or cover some links twice.
• One solution to this problem is to represent the graph as a matrix and to
use matrix operations equivalent to path tracing. These methods are more
methodical and mechanical and don’t depend on your ability to see a path
they are more reliable.
The Basic Algorithms
1 0 1 A
a
a
1 2
a
a b
1 2
b
3 a c
1 2
b
4
d
A simple weight
a c 1 1
3
1 2
b 1
4 d 1
Connection Matrix-continued.,
2-1=1
1 1
• Transitive Relations
• Reflexive Relations
• Symmetric Relations
• Antisymmetric Relations
• Equivalence Relations
• Partial Ordering Relations
Transitive Relations
25
Step 1: Represent a Given Flow Graph in the Form of a Matrix The
corresponding relationship matrix of the given flow graph is:
26
• Steps 2 to 3: Node Removal and Replacement with Equivalent Links
In this step, we select one node for removal at a time and identify
equivalent links that bypass that node. Then, we replace the intersection
of the node by equivalent links.
•
Here, first of all we shall remove the node with self-loop. In the given
matrix, node 7 has self loop in the form link e. We remove this link by
identifying equivalent link ef that bypass that node and connects node 8.
By doing this, we arrive at following matrix:
27
28
• After removing self-loops, we observe parallel links from node
3 to 6, one via node4 and another via node 5.
• We remove both node 4 and node 5, by adding link bc and
link hi between node 3 to 6 that are parallel to get bc+hi. Then
we replace this value at intersection of 3 node 3 and 6. By
doing this, we get:
29
30
The resulting matrix is as follows:
31
Software testing tools
Automated Testing Tools
When to Consider Test Automation
• A testing tool should be considered based on the test
objectives.
• As a general guideline, one should investigate the
appropriateness of a testing tool when the human
manual process is inadequate.
• For example, if a system needs to be stress tested, a
group of testers could simultaneously log on to the
system and attempt to simulate peak loads using
stopwatches.
• However,this approach has limitations. One
cannot systematically measure the
performance precisely or repeatably.
• For this case, a load-testing tool can simulate
several virtual users under controlled stress
conditions.
A regression testing tool might be needed under the
following circumstances:
• The LoadRunner Controller allows you to easily and effectively control all the
Vusers — from a single point of control.