Re: Algorithms



jt wrote:
....
So my question is, when you are sitting down looking at a problem, no matter how simple or complex it may be, how do you come up with an algorithm, or technique to solve it? Do you consult books, online sites or other sources? I remember taking a course in university on Analysis of Algorithms, but there was never anything taught on how to come up with them. I prefer to come up with my own solutions, I find that I learn more that way, but if I have to resort to using a pre-existing algorithm I will. Like that topic I started a while ago about my chess game simulator. Someone had a brilliant idea (I think it was Eric) about using pushers to do some of the work. How did he come up with that?
....

I use a combination of on-line searches, books, and just plain thinking.

There are design patterns for algorithms. Once you learn them, with a
bit of practice algorithm problems start feeling like
divide-and-conquer, or feeling like dynamic programming.

Patricia
.



Relevant Pages

  • Re: Challenae question for mathematician
    ... problems relating to permutation groups. ... adjacent books. ... called "bubble sort" - it is a quadratic time algorithm, ... efficient as a sorting method - efficient sorting is O. ...
    (sci.math)
  • Re: Regularly populating the line - revised version
    ... As I posted, I did hit the books before posting this, but you do raise good ... former life I designed 3D graphics chips). ... this algorithm comes from a rather different domain having no ... > more curious habit of recording much if it in books. ...
    (sci.math.num-analysis)
  • Re: srand() troubles
    ... > books are crap is a different topic.) ... of the lack of goals and direction for this forum and this language are ... > algorithm can be expressed in any Turing-complete language. ... getting those programs running on my implementation. ...
    (comp.lang.c)
  • Re: Image Newbie Question
    ... and I'd like to be able to recover the names on the books. ... processing algorithm to try and recover the ... But it will amplify all the JPEG artefacts as well probably rendering it completely illegible. ...
    (sci.image.processing)
  • Re: Optimization by hand.
    ... How various compiler implement ... the algorithm can vary widely, ... try an algorithms group. ... And there are also always the famous Knuth books. ...
    (comp.lang.cpp)