I just noticed your comment under the question that you actually do want new symbols. I shall give an example of that and also multiplication.
It is more efficient to perform the operation (multiplication, etc.) and then make the copies, rather than making copies and performing the operation anew on each.
f[A_, B_, R_, f_: Times] := Inner[ConstantArray, Outer[f, A, B], R, Join]
f[{M, F}, {a, b, c}, {1, 3, 2}
{{a M, b M, b M, b M, c M, c M}, {a F, b F, b F, b F, c F, c F}}
Symbols:
makeSym = Symbol @ ToString @ Row @ {##} &;
f[{M, F}, {a, b, c}, {1, 3, 2}, makeSym]
{{Ma, Mb, Mb, Mb, Mc, Mc}, {Fa, Fb, Fb, Fb, Fc, Fc}}
With argument checking for practical use:
f[A_List, B_List, R : {__Integer}, f_: Times] /;
Min[R] >= 0 && Length@B == Length@R :=
Inner[ConstantArray, Outer[f, A, B], R, Join]
M * a
or a new symbol calledMa
? $\endgroup$Outer
seems like the answer, it combines, and wraps a combination of elements with a specified function, if the function isTimes
, you can get get a M, if it'sList
, you get {M, a} instead. $\endgroup$