I want to formulate a set $K$ with the set-builder notation, but I am not sure if I am "allowed" to use a function, $m$, as a predicate without explicitly defining the function.
I want to accomplish the following: Given two sets $A$ and $B$, I want to define set $K$ in way that members of $K$ are also members of either set $A$ or $B$, provided that the function $m$ of $k$ evaluates to $e$, where $k \in K$ and $e \in E$. Furthermore, the "inner workings" of $m$ are irrelevant, it only matters that $m$ maps members of $K$ to members of $E$.
I tried to formulate it as follows:
Suppose $m: K \rightarrow E$ and $e \in E$, then $K$ is:
$K = \{x \in (A \cup B)\ :\ e = m(x)\}$