|
Chris PeBenito |
e070dd |
########################################
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
# gen_cats(N)
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
# declares categores c0 to c(N-1)
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
define(`decl_cats',`dnl
|
|
Chris PeBenito |
e070dd |
category c$1;
|
|
Chris PeBenito |
e070dd |
ifelse(`$1',`$2',,`decl_cats(incr($1),$2)')dnl
|
|
Chris PeBenito |
e070dd |
')
|
|
Chris PeBenito |
e070dd |
|
|
Chris PeBenito |
e070dd |
define(`gen_cats',`decl_cats(0,decr($1))')
|
|
Chris PeBenito |
e070dd |
|
|
Chris PeBenito |
e070dd |
########################################
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
# gen_sens(N)
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
# declares sensitivites s0 to s(N-1) with dominance
|
|
Chris PeBenito |
e070dd |
# in increasing numeric order with s0 lowest, s(N-1) highest
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
define(`decl_sens',`dnl
|
|
Chris PeBenito |
e070dd |
sensitivity s$1;
|
|
Chris PeBenito |
e070dd |
ifelse(`$1',`$2',,`decl_sens(incr($1),$2)')dnl
|
|
Chris PeBenito |
e070dd |
')
|
|
Chris PeBenito |
e070dd |
|
|
Chris PeBenito |
e070dd |
define(`gen_dominance',`s$1 ifelse(`$1',`$2',,`gen_dominance(incr($1),$2)')')
|
|
Chris PeBenito |
e070dd |
|
|
Chris PeBenito |
e070dd |
define(`gen_sens',`
|
|
Chris PeBenito |
e070dd |
# Each sensitivity has a name and zero or more aliases.
|
|
Chris PeBenito |
e070dd |
decl_sens(0,decr($1))
|
|
Chris PeBenito |
e070dd |
|
|
Chris PeBenito |
e070dd |
# Define the ordering of the sensitivity levels (least to greatest)
|
|
Chris PeBenito |
e070dd |
dominance { gen_dominance(0,decr($1)) }
|
|
Chris PeBenito |
e070dd |
')
|
|
Chris PeBenito |
e070dd |
|
|
Chris PeBenito |
e070dd |
########################################
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
# gen_levels(N,M)
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
# levels from s0 to (N-1) with categories c0 to (M-1)
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
define(`decl_levels',`dnl
|
|
Chris PeBenito |
e070dd |
level s$1:c0.c$3;
|
|
Chris PeBenito |
e070dd |
ifelse(`$1',`$2',,`decl_levels(incr($1),$2,$3)')dnl
|
|
Chris PeBenito |
e070dd |
')
|
|
Chris PeBenito |
e070dd |
|
|
Chris PeBenito |
e070dd |
define(`gen_levels',`decl_levels(0,decr($1),decr($2))')
|
|
Chris PeBenito |
e070dd |
|
|
Chris PeBenito |
e070dd |
########################################
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
# Basic level names for system low and high
|
|
Chris PeBenito |
e070dd |
#
|
|
Chris PeBenito |
e070dd |
define(`mls_systemlow',`s0')
|
|
Chris PeBenito |
e070dd |
define(`mls_systemhigh',`s`'decr(mls_num_sens):c0.c`'decr(mls_num_cats)')
|
|
Chris PeBenito |
e070dd |
define(`mcs_systemlow',`s0')
|
|
Chris PeBenito |
e070dd |
define(`mcs_systemhigh',`s0:c0.c`'decr(mcs_num_cats)')
|
|
Chris PeBenito |
e070dd |
define(`mcs_allcats',`c0.c`'decr(mcs_num_cats)')
|