# How to mathematically formulate and illustrate the following statement?

English is not my native language and I'm trying formulate the following statement as simple and as mathematical as I can:

A code is composed of a family name followed by n option(s):

1: {family}
n: option(s)

I have n+1 in mind but I'm sure I can use it in there.

Could it be formulated or illustrated any better?

EDITS
The choice of family is independent of the choice of options..
The family name could be anything really, "abc", "a100", etc..
An option is a facet or characteristic of a product..
An option could be anything: "-Z", "01", "HH"..

Random-on-the-fly possible codes:

abc-Z01HH
a100-NFF02
a250-V204C

I am trying to document the composition of product codes in a system.
I'm questioning my usage of n in the above statement.

Thanks

-
It would help to have more information. For example, how many choices of family name are possible? How many choices for each of the options are possible, and does this number vary with the option or is this number constant for all the $n$ options? Is the choice of family name independent of the choice of options? –  Dave L. Renfro Feb 3 '12 at 20:01
Added some meat, thanks :). –  maxbeaudoin Feb 3 '12 at 20:12
I really screwed lol. –  maxbeaudoin Feb 3 '12 at 20:21

## 1 Answer

Though you've already accepted my answer, I wanted to try to give a less technical phrasing (though it might be more suited to English.SE, I suppose):

A product code $P$ consists of a family name $f$, followed by some number of options $o_1,\ldots, o_n$.

For example, the product code $P$ of a product with family name $f=\text{ABC}$ and with options $o_1=\text{21}$ and $o_2=\text{ZZ}$ would be

$$P = \text{ABC}{-}21\text{ZZ}$$

Here is an attempt to capture what (I think) you're saying:

Let $F$ be the set of all family names.

For each $1\leq k\leq n$, let $O_k$ be the set of all possible values for the $k$th option.

Then a code is defined to be an element of $$F\times O_1\times\cdots\times O_n.$$

See Cartesian product - given a set of objects $A$, and a set of objects $B$, their Cartesian product is the set $A\times B$ consisting of ordered pairs, the first entry taken from $A$, the second taken from $B$. Thus, an element of $$F\times O_1\times\cdots\times O_n$$ looks like $$(f,o_1,\ldots,o_n)$$ where $f$ is a family name, $o_1$ is one of the possible choices for option 1, etc. This sounded like your description of what you want a "code" to be.

-
Oh noes!!! Please read my edits, I realize I've been too vague and now you have crafted some mathematical formulas that could literally kill the people who would dare read my documentation, lol. –  maxbeaudoin Feb 3 '12 at 20:11
However, what you've provided help understanding the combination of family names and options and possibly document the math behind the generation of such codes. Talking about: F×O1×⋯×On –  maxbeaudoin Feb 3 '12 at 20:20
Actually.. you're right. –  maxbeaudoin Feb 3 '12 at 20:29
@maxbeaudoin: Thanks, I agree my proposal was probably too technical for the layperson (though it is in the style of a mathematical definition). I've added a second try, perhaps it'll suit your needs better. –  Zev Chonoles Feb 3 '12 at 20:38
Thanks for taking that effort. I really appreciate it! Right on. –  maxbeaudoin Feb 3 '12 at 21:04