note that when I say "a minimal expression" I mean an expression with a less than or equal number of characters to all other expressions that meat the given criteria.

if we call this function F then some base cases are known

F(0) = ""

F(1) = "+"

F(2) = "++"

F(3) = "+++"

...

but as you get to higher characters smaller expressions start appearing than just a string of '+'s

for instance

"++++++[>+++++<-]>+" is much smaller than 31 characters but never the less computes 31 (I *think* this is a minimal expression for 31 but am unsure)

the above expression corresponds to 6 * 5 + 1 and it seems pretty minimal to me. For numbers of the form X*Y where X and Y are very close you get pretty good results with this. Numbers close to such numbers you also get pretty good results. For larger numbers nesting this method might be in order. This would lead to a decent heuristic but I see no obvious reason why such a heuristic would lead to ideal results.

A more complex problem would be the minimal expression which would print a desired string but that is much harder obviously.

Any thoughts?

This post has been edited by **macosxnerd101**: 05 November 2013 - 03:37 PM

Reason for edit:: Renamed title