how to define a function which returns a multiset

115 Views Asked by At

Given graph $G(V,E)$, how can I formally define function $f\prime$ which takes a node $v \in V$ and returns a multiset?

1

There are 1 best solutions below

0
On

A multiset is a function $\nu$ defined on some ground set $X$ with values in ${\mathbb N}_{\geq0}$. Such a function assigns each element $x\in X$ its "multiplicity" $\nu(x)$.

When you have a function $f$ that assigns to each node $v\in V$ a multiset $\nu$ on some ground set $X$ I'd suggest to denote the multiset corresponding to the node $v$ by $\nu_v\>$. In this way $\nu_v(x)$ denotes the multiplicity of $x$ foreseen by $f$ for the given node $v$.