Tag Info

Hot answers tagged

16

Domain-Specific Languages are about as close as we'll ever get. You will always have to give the computer some rules to work with. But the more those rules are defined in a manner specific to their domain, the less input there will have to be. Domain-specific languages that target web development require less coding than languages that are more generic. ...


15

The fitness function evaluates the output of your algorithm. It's quite possible to recognize an ideal output when you see it, but not know the steps to produce that output from any given input. That's where genetic algorithms are most useful. For example, one common fun application of GA is in producing an animation that can move a virtual creature in an ...


14

Genetic algorithms are basically a guided trial-and-error methodology. The only advantage I can think of for a GA over a exhaustive search is that since GA optimizes a fitness function in steps, you might get to an optimal solution faster, because the GA will favor solutions that are incrementally better. An exhaustive search that's guaranteed to find a ...


12

The NP-Hard domain of problems means that, as far as current mathematical knowledge goes, the problem can only be solved by trying every permutation and choosing the correct answer. If you can solve the problem more efficiently than the brute force method, you will win a Noble Prize in mathematics as a bonus. The best mathematicians have been working on a ...


9

GP relies on "evolution", whereas the Infinite Monkey Theorem is just random chance. In GP, you have one or more fitness indicators which are used to evaluate a generation of possible solutions to "breed" to create a new generation. Each one, more than likely, getting a better and better solution. IMT has more to do with enough candidates that eventually ...


8

It's often the case that you can determine the fitness of a solution but can't directly determine the solution itself. Say you're trying to evolve fast rabbits, and there are a handful of genes that impact rabbit speed. You can test rabbit speed, but enumerating all the combinations of speed-related genes would be impractical. In such a case, you might have ...


8

As others have mentioned, the trick is that they must spend exactly $15.05, which does indeed make this an NP-hard problem similar to the knapsack problem. However, "NP-hard" doesn't necessarily mean "hard to solve in practice" -- if the number of appetizers is small, then a brute force solution is relatively easy to code up and will work just fine. We can ...


6

Yes, if computation were free, then you wouldn't need genetic algorithms at all. But remember that this is a huge, huge "if" that none of us will ever live to see! Still, since you're asking... if computation were infinitely fast, there would be no reason whatsoever not to apply the simplest brute-force combinatorial generate-and-test sledgehammer to a ...


6

Encoding the values as bits isn't necessary. Look at 2d box car (don't waste too much time on it) for an example where the crossover is done on whole (float) values. Entire 'assemblies' are crossed over, this adds to the recognizability of the source (part of the aesthetics of the game), but makes it it so that the variations between a given chromosome and ...


5

The entire point of the GA is to give you the solution to the problem that has that fitness level. This solution would be very hard to find using other more conventional search algorithms, which is usually why you're using a GA in the first place. Or instead of a fitness value limit, you could decide how many generations you want to run (the more ...


5

In the 80's and 90's there was a lot of buzz about so called 4th generation languages. From the Wikipedia article: All 4GLs are designed to reduce programming effort, the time it takes to develop software, and the cost of software development. They are not always successful in this task, sometimes resulting in inelegant and unmaintainable code. However, ...


3

The problem with infinitely fast computations is that they infinitely fast cover a state space which is larger than the information limit of our known universe. You mentioned "brute force", however consider that brute forcing chess for example, can produce an output that exceeds in size the number of atoms in the universe. Taking the example of chess ...


3

One of the most discussed approach to automated code generation is "MDA" a.k.a Model driven architecture. Mostly (but not necessarily) one puts up UML through visual GUI editor from which relevant classes are generated. While, i think the expression of fully functional code might be still far, there are pretty good enough systems that generates complete ...


3

The problem you're having with ant colony algorithms and the reason that no one has applied it to solving crosswords is because ACO poorly suited for the problem of crosswords. Artificial intelligence is a MASSIVE field of study. There are a ton of methods and approaches. There are also quite a lot of problems out there that can have AI applied to them. ...


3

What you're referring to is called "constrained optimization". This is a really well-studied branch of evolutionary computation, and you can find dozens of resources describing common techniques for solving these problems. Carlos Coello-Coello does a tutorial on the subject each year at GECCO, the primary EC conference in the field. I found slides from one ...


3

The thing about monkeys is most of them are terrible writers, which is why we would need an infinite number of them. Your infinite monkeys will indeed produce some great literary works (all of them in fact), however they will also produce an awful lot of crap (both literal and figurative). Using a genetic algorithm instead will hopefully let us produce some ...


3

Intuitively, the purpose of a genetic algorithm is to formulate an algorithmic solution to a problem that doesn't lend itself to a straightforward logical analysis. Once that goal is achieved, the GA need not pursue any further. Of course, if better "fitness" is wanted, the genetic algorithm can be left running to see if it can find a more highly optimized ...


3

After that you have generated your initial population (the pool should be quite large) and you apply your fitness function to it, you select your parents for the next generation. Once that you have your parents, you discard the other individuals so that you can replace them with the new generation. This replacing will keep your population size in control, ...


2

A genetic algorithm requires some way to reward good genes with greater propagation. If you had no way to tell good genes from bad genes, you couldn't use a genetic algorithm at all. For a genetic algorithm to work, you must allow the more fit solutions to reproduce in preference to the less fit solutions. Otherwise, you'd just be trying random solutions. ...


2

If you're talking about simulation programming, one important aspect/type is Monte Carlo simulation. Essentially the idea is to randomly generate (many!) several runs of simulation data, then average the runs to get an overall simulation result. The averaging removes any randomness in the data and provides a clearer true result. Statistically, you're ...


2

The infinite monkey theorem relies on the vastness of an infinite number of anything. An infinite number of monkeys bashing at keyboards randomly will instantaneously generate not only Shakespeare but every work ever written and every work ever to be written an infinite number of times. Including what the monkeys just typed. (How does a set contain itself ...


2

I've written many code generators for Java and C# that produce working code for various tasks. There are packages like JAXB, which analyzes an XML document and produces corresponding Java classes and marshalling/unmarshalling code to do the translation, and Entity Framework which produces DTO classes for marshalling data to/from a database. There are also ...


2

Does declarative programming count, e.g. Prolog or SQL? You just describe what the program should accomplish, or what conditions the results should satisfy. Then you query the system, and get results (or "no solutions"). Of course under the hood, there's a program running, but you never see the code. Unfortunately declarative programming is not a silver ...


2

My advice is usually to never use generation count as a performance metric or termination criterion. Aside from the problem you're facing, it's just too dependent on population size to be of much use. You can't compare across runs, because if your GA has a population of 10 and mine has a population of 10,000 then of course mine will be better than yours over ...


2

If by "unlimited computation resources" you mean that your algorithm would take 0 time and that memory is unlimited and electricity is of no concern, I would say the only algorithm to use would be a brute force algorithm that tries every possible input and is guaranteed to find the very best one. If you are referring to unlimited memory but a possible ...


2

Choosing the children that are fit for the next generation of mating is the same fitness calculation that made their parents fit. Also, at the end of the current generation, you should not have more children than the initial population. Remember, this is not a free-for-all but survival of the fittest. You are picking a highly selected group that are fit ...


1

So... a node is a collection of GA population from another computer, hence the distributed aspect? And you're asking about how to join the populations? To reap the benefit of distributing the computation you eventually have to merge the populations. You're worried about merging populations with different amount of time and processing power being thrown at ...


1

Genetic algorithms are population-based optimization methods. So you have a population of candidate solutions at any given time. Suppose you're trying to solve the one-max problem -- a simple problem where the goal is to maximize the number of 1-bits in a binary string of length L. With L=8, each candidate solution looks like 00101101 ==> fitness = 4 ...


1

Hmmm... When I took a class on GA's and EA's, multipoint crossover was not necessarily better than single point crossover or even mutation and no crossover. In this case it seems that multipoint cross over may generate invalid rows and I'm assuming that means your evaluation function can't calculate a meaningful statistic. Given that, your idea to cross ...


1

We're already there! All what we need is a language with today called homo-iconic character and decades earlier "code is data". Define your own environment by bottom-up programming instead designing top-down. You could for instance build your own DSLs inside Lisp. With the approach of Stacking you could putting as much DSLs (layers) on top of each other as ...



Only top voted, non community-wiki answers of a minimum length are eligible