As described in The core libraries section the modules in MITIE that do most of the work are one of four types, processes, link selectors, node selectors, or link dimensioners. Below is a list of the currently available modules in the core library of modules in MITIE.
Specifically this page contains detailed information on:
Processes [ addLink | grow | linkNodes | redim | remLink | adjLDump | degDistDump | distDistDump | distancesDump | eigenvalDump | pajekDump | routesDump | topStatDump | weightDistDump | weightsDump ]
Link Selectors [ degree | geoabs | geopow | geowax | random | rpl | wt ]
Node Selectors [ D | EP | EW | R | RPN | node | prev ]
Link Dimensioners [ const | nroutes ]
Add a link between two nodes, selecting the pair with a link selector.
Usage: addLink{link_selector_name,link_dimensioner_name}
Where:
link_selector_name
The name of the link selector to use to chose a node pair which to connect.link_dimensioner_name
The name of the link dimensioner to use on the new link.addLink{degree{diff,exp=-1},const=1}
adds a new link between an existing node pair which aren't currently connected. The new link is assigned a weight of 1. The nodes to connect are chosen based on a normalised probability which is the reciprocal of the difference of the degrees of a candidate node pair.Adds a single node to the network (assuming -maxSize hasn't been exceeded) and connects it to the existing nodes with the specified node selector.
Usage: grow{destination_selector_name,link_dimensioner_name}
Where:
destination_selector_name
The node selector which will choose which node the new node will connect to.link_dimensioner_name
The name of the link dimensioner to use on the new link.grow{R,const=1}
Add a link between two nodes, selecting each node with two node selectors.
Usage: linkNodes{node_selector_name1,node_selector_name2,link_dimensioner_name[,dupe_ok]}
Where:
node_selector_name1
node_selector_name2
The names of the two nodes selectors to use to chose a node pair which to connect.link_dimensioner_name
The name of the link dimensioner to use on the new link.[dupe_ok]
If specified a node pairs which are already connected are included in the node-pair selection(only applies when adding links).addLink{D,D,const=1}
Redimensions all links in the network.
Usage: redim{link_dimensioner_name}
Where:
link_dimensioner_name
The name of the link dimensioner to use on the new link.Remove a link from the network, selecting it with a link selector.
Usage: remLink{link_selector_name}
Where:
link_selector_name
The name of the link selector to use to select the link to remove.
A number of the output modules have the following common set of options:
[append_epoch]
Appends the epoch number after the label of each line.[overwrite]
specifies whether to overwrite the file in case of output to file.[label]
The label to print at the start of each output line.[header]
This is printed above any information dumped.[fn=filename]
The filename of the file to secnd output to. If not specified output will be sent to std out.So, for example, if mitie is called with: -initChain 4 '0:linkNodes{D,D,const=1}' '0:adjLDump{append_epoch,label=somelabel_,header=This is an example header}' 'END:topStatDump{}' 'END:distDistDump:{append_epoch,label=anotherlabel,header = Another header}'
The output is:
Parsed 2 epoch processes and 2 END processes. Starting main loop.. send SIGUSR1 to see progress or SIGINT/^C to terminate main loop early. This is an example header somelabel_0 0 ( 1 ): 1 somelabel_0 1 ( 3 ): 0 2 3 somelabel_0 2 ( 2 ): 1 3 somelabel_0 3 ( 2 ): 1 2 This is an example header somelabel_1 0 ( 2 ): 1 2 somelabel_1 1 ( 3 ): 0 2 3 somelabel_1 2 ( 3 ): 0 1 3 somelabel_1 3 ( 2 ): 1 2 This is an example header somelabel_2 0 ( 3 ): 1 2 3 somelabel_2 1 ( 3 ): 0 2 3 somelabel_2 2 ( 3 ): 0 1 3 somelabel_2 3 ( 3 ): 0 1 2 Failed to complete process in epoch 3: CjNP_grow::performAction: Couldn't find a node to connected new node to. Terminating main loop. Network now has 4 nodes and 12 links. Invoking END processes.. Invoking topStatDump numlinks 12 numnodes 4 frac_connected_node_pairs_no_self_loops 0.75 frac_connected_node_pairs_inc_self_loops 1 numSelfLoops 0 isPartitioned false Invoking distDistDump ..APSP done in 2.8e-05 seconds. Another header anotherlabelEND 0 4 anotherlabelEND 1 12
The use of header
and label
should make it easier to delimit and parse the output for further processing.
Prints the adjacency list of the topology. The column after the label is the source node, the fourth column (the number in brackets) is the out-degree, and the number after the colon are the nodes that this node connects to. The options are as per the Common output options.
The output of '0:adjLDump{append_epoch,label=somelabel_,header=This is an example header}'
is:
This is an example header somelabel_0 0 ( 1 ): 1 somelabel_0 1 ( 3 ): 0 2 3 somelabel_0 2 ( 2 ): 1 3 somelabel_0 3 ( 2 ): 1 2
Prints the frequency distribution of node degrees of the topology. The column after the label is the node degree number, and the last column is the frequency. The options are as per the Common output options.
The output of '0:degDistDump{append_epoch,label=somelabel_,header=This is an example header}'
is:
This is an example header somelabel_0 1 1 somelabel_0 2 2 somelabel_0 3 1
Prints the frequency distribution of distances (sum of wieghts in minimum cost path) between all node pairs. The column after the label is the distance and the last column is the frequency. The options are as per the Common output options.
The output of '0:distDistDump{append_epoch,label=somelabel_,header=This is an example header}'
is:
This is an example header somelabel_0 0 4 somelabel_0 1 8 somelabel_0 2 4
Prints a matrix of distances (minimum total-weight paths) between all pairs in the topology. The options are as per the Common output options.
The output of '0:distancesDump{append_epoch,label=somelabel_,header=This is an example header}'
is:
This is an example header somelabel_0 0 1 1 2 somelabel_0 1 0 1 2 somelabel_0 1 1 0 1 somelabel_0 2 2 1 0
Prints the adjacency list of the topology. The options are as per the Common output options, additionally the following options are supported:
[count=integer]
Outputs only first integer number of eigenvalues asc|desc
Sorts the eigenvalues in ascending or descending order prior to output.
[prec=integer] Sets the number of decimal places to print when outputting the eigenvalues (adj|comb_lap|sign_lap|norm_lap)
Which decides how the adjacency matrix is generated before the eigenvalue is calculated. adj
takes the eigenvalue of the adjacency matrix where adj(i,j) is 1.0 if i and j are connected, 0.0 otherwise. comb_lap
takes the eigenvalue of the combinatorial laplacian adjacency matrix where adj(i,j) is -1.0 if i and j are connected, adj(i,i) is the degree of node i, and 0.0 otherwise. sign_lap
takes the eigenvalue of the sign-less combinatorial laplacian adjacency matrix where adj(i,j) is 1.0 if i and j are connected, adj(i,i) is the degree of node i, and 0.0 otherwise. norm_lap
takes the eigenvalue of the normalised laplacian adjacency matrix where adj(i,j) is -( (deg(i)*deg(j))^-0.5 ) if i and j are connected, adj(i,i) is 1.0, and 0.0 otherwise. Sample output for '0:eigenvalDump{adj,desc,append_epoch,label=somelabel_,header=This is an example header}'
:
This is an example header somelabel_0 2.17009 0.311108 -1 -1.48119
Output the topology to a Pajek file.
Usage: {fn_base=file_prefix [,fn_ext=ext] [,overwrite]}
Where:
fn_base=
Specifies the start of the filename fn_ext=
Specifies the file extension overwrite
Specifies that the file can be overwrittene.g. 0:pajekDump{fn_base=expt1_,fn_ext=.net}
Will output the topology at every epoch to a file called expt1_#####.net where ##### is the epoch number.
So, calling mitie with the following options: -initChain 4 'END:pajekDump{fn_base=filebase_,fn_ext=.net,overwrite}'
Would result in the following been written to file filebase_END.net:
*Vertices 4 1 0 2 1 3 2 4 3 *Edges 1 2 2 1 2 3 3 2 3 4 4 3
Prints the routes between every node pair. The options are as per the Common output options.
The output of '0:routesDump{append_epoch,label=somelabel_,header=This is an example header}'
is:
This is an example header somelabel_0 0-0: 0 somelabel_0 0-1: 0 1 somelabel_0 0-2: 0 1 2 somelabel_0 0-3: 0 3 somelabel_0 1-0: 1 0 somelabel_0 1-1: 1 somelabel_0 1-2: 1 2 somelabel_0 1-3: 1 0 3 somelabel_0 2-0: 2 1 0 somelabel_0 2-1: 2 1 somelabel_0 2-2: 2 somelabel_0 2-3: 2 3 somelabel_0 3-0: 3 0 somelabel_0 3-1: 3 0 1 somelabel_0 3-2: 3 2 somelabel_0 3-3: 3
Prints various topology statistics, including: number of nodes, number of links, the number of nodes that are connected to themselves (self-loops), whether the topology is partitioned, and what fraction of node pairs are connected. The options are as per the Common output options.
The output of '0:topStatDump{append_epoch,label=somelabel_,header=This is an example header}'
is:
This is an example header somelabel_0 numlinks 8 somelabel_0 numnodes 4 somelabel_0 frac_connected_node_pairs_no_self_loops 0.5 somelabel_0 frac_connected_node_pairs_inc_self_loops 0.666667 somelabel_0 numSelfLoops 0 somelabel_0 isPartitioned false
Prints the frequency distribution of the link weights. The options are as per the Common output options.
The output of '0:weightDistDump{append_epoch,label=somelabel_,header=This is an example header}'
is:
This is an example header somelabel_0 0 8 somelabel_0 1 8
Prints the weights matrix (the weight of each link). The options are as per the Common output options.
The output of '0:weightsDump{append_epoch,label=somelabel_,header=This is an example header}'
is:
This is an example header somelabel_0 0 1 0 1 somelabel_0 1 0 1 0 somelabel_0 0 1 0 1 somelabel_0 1 0 1 0
Below is a list and overview of the link selector modules available in the MITIE core library. Their use is always through invocation in a network process.
Selects a link or node-pair based on the degree of the nodes. Whether a connected or disconnected node pair are selected is dependant on the context (i.e. if used in an addLink{} context then only node pairs which aren't already connected will be considered (unless dupe_ok is specified), ).The probability of a two endpoints being chosen The endpoints are selected by either the diff
Usage: degree={(add|diff)[,exp=float][,dupe_ok]}
Where:
(diff|add) Specify whether the difference or sum of the degrees should be put into the wheel for selection.
[exp=float] The sum or difference is taken to this power before it is placed in the selection wheel.
[dupe_ok] If specified a node pairs which are already connected are included in the node-pair selection(only applies when adding links).
Example1: degree={add,exp=-1}
Would populate the roulette wheel with values which are the reciprocal of the sum of degrees of the two end-points. This effectively increases poor-club (I guess that's what the opposite of rich club is) connectivity.
Example2: degree={diff}
Would populate the roulette wheel with values which are the difference of the degrees of the two end-points. This leads to higher dis-assortitative mixing (i.e. nodes of a non-similar degree have a tendancy to be linked).
Selects the link or node-pair which has the highest, or lowest absolute value for geographic/euclidean distance between them.
Usage: geoabs={(min|max)[,dupe_ok]}
Where:
(min|max) Specify whether the absolute minimum or maximum geographic distance node-pair should be selected.
[dupe_ok] If specified a node pairs which are already connected are included in the node-pair selection(only applies when adding links).Selects a link or node-pair preferring those with a higher value of alpha*geographic_distance_between_nodes_in_pair^beta.
Usage: geopow={alpha=float,beta=float[,no_warn][,dupe_ok]}
Where:
alpha=float
Specifies the value to use for the distance co-efficient.beta=float
Specifies the value to use for the distance exponent.
[no_warn] Disables the warning about values of alpha and beta outside of expected bounds.
[dupe_ok] If specified a node pairs which are already connected are included in the node-pair selection(only applies when adding links). geopow={alpha=0.00003,beta=-1.9104,no_warn}
Selects a link or node-pair preferring those with a higher Waxman probability i.e. alpha * exp(-geographic_distance_between_nodes_in_pair/beta).
Usage: geowax={alpha=float,beta=float[,no_warn][,dupe_ok]}
Where:
alpha=float
Specifies the value to use for the exponent co-efficient.beta=float
Specifies the value to use for the distance co-efficient.
[no_warn] Disables the warning about values of alpha and beta outside of expected bounds.
[dupe_ok] If specified a node pairs which are already connected are included in the node-pair selection(only applies when adding links). geowax={alpha=0.1150,beta=0.00685,no_warn}
Selects a link or node-pair at random, with a uniform probability distribution.
Usage: random={[dupe_ok]}
Where:
[dupe_ok] If specified a node pairs which are already connected are included in the node-pair selection(only applies when adding links).Selects a link, preferring with a higher value of rpl^exp, where rpl is the number of routes passing across the link (routes, not load, so equivalent to a full mesh of unity load).
Usage:
Where:
[exp=float] The optional exponent to which to raise the rpl value.Selects a link based on its weight.
Usage:
Where:
(min|max|pref) Specifies whether to select the link with the absolute minimum or maximu, or whether to use roulette wheel selection preferring links with a high weight^exp value.
[exp=float] The optional exponent of the link weight when using pref selection.Below is a list and overview of the node selector modules available in the MITIE core library. Their use is always through invocation in a network process.
Select a node based on its out-degree.
Usage: D[={[exp=float],[dupe_ok]}]
Where:
[exp=float] The optional exponent to which to raise the node outdegree value.
[dupe_ok] If specified, and if this is the second selector in a process, the selector may return a node which is already connected to this node.Selects a second node preferring those with a higher value of alpha*geographic_distance_between_nodes_in_pair^beta.
Usage: EP={alpha=float1,beta=float2[,no_warn][,dupe_ok]}
Where:
alpha=float
Specifies the value to use for the distance co-efficient.beta=float
Specifies the value to use for the distance exponent.
[no_warn] Disables the warning about values of alpha and beta outside of expected bounds.
[dupe_ok] If specified, and if this is the second selector in a process, the selector may return a node which is already connected to this node.Selects a second node preferring those with a higher Waxman probability i.e. alpha * exp(-geographic_distance_between_nodes_in_pair/beta).
Usage: EW={alpha=float1,beta=float2[,no_warn][,dupe_ok]}
Where:
alpha=float
Specifies the value to use for the distance co-efficient.beta=float
Specifies the value to use for the distance exponent.
[no_warn] Disables the warning about values of alpha and beta outside of expected bounds.
[dupe_ok] If specified, and if this is the second selector in a process, the selector may return a node which is already connected to this node.Select a node based at random with a uniform porbability.
Usage: R[={dupe_ok}]
Where:
[dupe_ok] If specified, and if this is the second selector in a process, the selector may return a node which is already connected to this node.Select a node preferring nodes with a higher number of routes that ingress and egress the node. Can also consider transit only routes.
Usage: RPN={[transit][,ave][,exp=float][,dupe_ok]}
Where:
[transit] Instead of considering all routes at the interfaces of each node, only consider routes that transit the node (2*N fewer than if were considered)
[ave] Specifies whether the number of routes is to be divided by the out-degree.
[exp=float] If specified the [average] number of routes is taken to this exponent before being placed in selection wheel.
[dupe_ok] If specified, and if this is the second selector in a process, the selector may return a node which is already connected to this node.Selects the node specified as an argument.
Usage: node=M
Beware that if M is fully connected then the process will return an error and the simulation will probably terminate.
Where:
node=M
Always selects node number M.Selects a node from a previous operation.
Usage: prev={(rem,add),(bigD|smallD|old|new)}
Where:
rem
states that the choice should be between the two nodes most recently disconnected.add
that the choice should be between the two nodes most recently connected.bigD
selects the node with the higher degree of the two.smallD
selects the node with the smaller degree of the two.old
selects the node with the lower node number of the two.new
selects the node with the higher node number of the two.Below is a list and overview of the link dimensioner modules available in the MITIE core library. Their use is always through invocation in a network process - probably a addLink but also redim.
Sets the link to the constant value specified.
Usage: const=1
Where:
const=N
where N is an integer greater than 0Sets the link to a function of the number of routes (routes, not load) that traverse it. Sets the weight of the link to alpha*number_of_routes_on_link^beta. If alpha or beta are not specified then their value defaults to 1.0. min_val is the minimum value a link weight could be.
Usage: nroutes={min_val=1[,alpha=float][,beta=float][,no_warn]}
Where:
[alpha=float] The optional co-efficient of the number of routes. This value must be positive.
[beta=float] The optional exponent of the link weight when using pref selection.min_val=integer
The minimum link weight that will be returned. This value will be returned if the dimensioning is for a new link (therefore no routes to count). This can be any integer greater than 0.
[no_warn] Prevents the printing of a warning message every time the minimum value is used.