The idea of generating a program has been around for quite some time.

Now there are IDE’s which can create the scaffolding code so that programmers need to fill in just the application logic.

What I am thinking is little math and little of code generation. I am trying to link 2 different concepts

**Newton–Raphson method**(http://en.wikipedia.org/wiki/Newton’s_method): briefly this helps us approximating a function (*f*) by going over a given set of x and*f*(x). the more the set of x ->*f*(x) the more accurate our f will be.(http://en.wikipedia.org/wiki/Test-driven_development): here we have a set of tests and we write code so that the tests pass, test is an input/output mapping like x ->*TDD**f*(x)

**Clubbing them together:**

can we use both of these together to generate the function (*f*) ?

one issue would be that newton-raphson method works on real numbers, and we can say our functions work on byte arrays or strings.

for this can we map a string to a real number so that test cases are converted from string -> *f*(string) to x -> *f*(x)

some links to read further:

http://en.wikipedia.org/wiki/Program_synthesis

http://research.microsoft.com/en-us/um/people/sumitg/pubs/synthesis.html

http://dl.acm.org/citation.cfm?id=2594297