Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3346062
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T01:15:33+00:00 2026-05-18T01:15:33+00:00

I have written a game playing program for a competition, which relies on some

  • 0

I have written a game playing program for a competition, which relies on some 16 floating point “constants”. Changing a constant can and will have dramatic impact on playing style and success rate.

I have also written a simple genetic algorithm to generate the optimal values for the constants. However the algorithm does not generate “optimal” constants.

The likely reasons:

  • The algorithm has errors (for the time being rule this out!)
  • The population is to small
  • The mutate rate is to high
  • The mate rate could be better

The algorithm goes like this:

  • First the initial population is created
  • Initial constants for each member are assigned (based on my bias multiplied with a random factor between 0.75 and 1.25)
  • For each generation members of the population are paired for a game match
  • The winner is cloned twice, if draw both are cloned once
  • The cloning mutates one gene if random() is less than mutate rate
  • Mutation multiplies a random constant with a random factor between 0.75 and 1.25
  • At fixed intervals, dependent on mate rate, the members are paired and genes are mixed

My current settings:

  • Population: 40 (to low)
  • Mutate rate 0.10 (10%)
  • Mate rate 0.20 (every 5 generations)

What would be better values for population size, mutate rate and mate rate?

Guesses are welcome, exact values are not expected!
Also, if you have insights with similar genetic algorithms, you will like to share, please do so.

P.S.: The game playing competition in question, if anyone is interested: http://ai-contest.com/

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T01:15:34+00:00Added an answer on May 18, 2026 at 1:15 am

    Your mutation size strikes me as surprisingly high. There’s also a bit of bias inherent in it – the larger the current value is, the larger the mutation will be.

    You might consider

    1. Having a (much!) smaller mutation
    2. Giving the mutation a fixed range
    3. Distributing your mutation sizes differently – e.g. you could use a normal distribution with a mean of 1.

    R.A. Fisher once compared the mutation size to focusing a microscope. If you change the focus, you might be going in the right direction, or the wrong direction. However, if you’re fairly close to the optimum and turn it a lot – either you’ll go in the wrong direction, or you’ll overshoot the target. So a more subtle tweak is generally better!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have written a game using Quartz2d. I would like a insert a background
Assume you have written a new function that checks to see if your game
So I have been playing a lot of pacman on my cell lately and
I've already written a game engine in java using eclipse and opengl es, I
I'm currently writing an AI for a game that is written in c++. The
I'm developing a little snake game written in C++ and using SFML 2D library.
I am trying to write some boilerplate code for a game in C++. I
I have written few test scripts using JUnit 4 and Selenium. I have added
I have written a small Asp.net application using Entity Framework. A Stored Procedure accepts
I have written an application called Abacus and released it as free software. Now

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.