Genetic Algorithms using Python

Project: Looking for Dark Matter in the Rotation Curves of the Hubble Tuning Fork Galaxy Diagram

Department of Natural Sciences: Physics

Project adviser:  Dr. Scott Schneider

Researched by: Ceré L. Rettig

E-mail: crettig@ltu.edu

Project Summary as of: 10/21/2014

IMG_20141026_114558_289

What is a galaxy rotation curve?

Galaxy rotation curves are a graphical analysis obtained from the magnitude of the orbital velocities of visible stars in a particular galaxy and their radial distance from the galaxies center, typically depicted with a scatter plot.

What is the Hubble Tuning Fork Galaxy Diagram?

The Hubble Tuning Fork Galaxy Diagram is a way to classify galaxies.  Mr. Edwin Hubble believed that the elliptical galaxies (E0, E3, E5, E7) are “early galaxies” and that the lenticular (S0), and spiral galaxies (Sa, Sb, Sc, SBa, SBb, SBc) or “late galaxies” evolved from the elliptical galaxies.  In this model the lenticular galaxies are viewed as a transition type between the elliptical and spiral galaxies.  While this evolution model has been found to be incorrect, this is a good diagram used for galaxy classification.

What is dark matter?

Dark matter accounts for effects that appear to be the result of mass where such mass cannot be seen.  It attracts or exerts a gravitational inward pull on the visible matter surrounding it.

Are we sure it is not dark energy?

Yes, because dark energy repels or pushes outward.

What is already known about spiral galaxy rotation curves?

Rotation curves are an essential tool for determining mass distribution in spiral galaxies, and provide fundamental information.

The existing programs that will be used were created by:

Dane Falberg is another student at Lawrence Technological University who is working on an astrophysics project advised by Dr. Scott Schneider.  He is creating a genetic algorithm program using java for his project that I will be able to use and modify for this project.

Project Objectives:

  • Research galaxy rotation curves for the six different types of spiral galaxies.
  • Investigate mathematical models for ordinary matter and dark matter to generate rotation curves.
  • Research genetic algorithms.
  • Study Dane Falberg’s programing with genetic algorithms. (Not exactly…)
  • Modify the software, to fit galaxy rotation.
  • If time is available see if this process can be done with lenticular galaxies.

References

J.Q. Feng and C.F. Gallo, Res. Astron. Astrophys. 11 1429-1449, 1 (2011).

Charbonneau, Astrophys. J. Suppl. Ser. 101 309-334, 1 (1995)

Sofue and V. Rubin, Ann. Rev. Astron. Astrophys. 39 181-0015, 1(2000).

____________________________________________________________________________________________________

What I’ve been working on:

  • Researching galaxy rotation curves for spiral galaxies, including: mathematical models for ordinary matter and dark matter to generate rotation curves.  
  • Researching Vera Rubin and her work on galaxy rotation curves.

Why Vera Rubin?

Vera Rubin’s work on galaxy rotation curves is why it is possible for my project to exist today.  The discovery of her work was presented to both myself and Dr. Scott in the series finale of COSMOS: A Spacetime Odyssey with Neil deGrasse Tyson.

“We have peered into a new world and have seen that it is more mysterious and more complex than we had imagined.  Still more mysteries of the universe remain hidden.  Their discovery awaits the adventurous scientists of the future.  I like it this way.”

Genetic Algorithm (GA) Software

I will not be using Dane Falberg’s programming with genetic algorithms, it is too complicated.  Dane Falberg was using a tutorial from the Project Spot.  While I may not being using this code, I’d like to take the time to re-state some of key points from this website.

What does the Project Spot tell us about GA’s?

  • It’s great for finding solutions to complex search problems. Isn’t that fantastic, because using data points to match up galaxy rotation curves is definitely a complex search problem.  Without the use of a genetic algorithm it can be quite a lengthy process.
  • They are based on the process of evolution by natural selection which has been observed in nature. This process they are talking about is quite lengthy to discuss in a short bullet point but it will be discussed further later on.
  • As previously stated, they can be used to find solutions to complex problems, and are relatively simple to use and understand. The fact they are simple, is good for someone like myself who does not have a lot of programming experience, but would like to use them to further their research.

In this next section I may use exact phrases from the Project Spot, as they are simplistically stated, so I am going to apologize in advance to the Project Spot and its creator Lee Jacobson of Bristol, UK.  I would also like to thank the Project Spot and Lee for all the work put into sharing his knowledge of genetic algorithms.

  • Initialization – creates a randomly generated initial population and can be any desired size.
  • Evaluation – Each member of the initial population is then evaluated and a ‘fitness’ is calculated for that individual in the initial population.
  • Fitness – This fitness is calculated by how well it fits with our desired requirements.
  • Selection – Since we want to constantly improve our population’s overall fitness, selection helps us to do this by discarding the bad designs and only keeping the best individuals in the population. We want to make it more likely that individuals with the best fitness will be selected for the next generation.
  • Crossover – A crossover is done to create new individuals by combining aspects of our selected individuals. It can be thought of as simulating how sex works in nature.  The hope is by combining certain traits from two or more individuals we will create an even ‘fitter’ offspring which will inherit the best traits from each of its parents.
  • Mutation – This creates a little bit of randomness into out populations’ genetics otherwise every combination of solutions we can create would be in our initial population. Mutation *typically* works by making very small changed at random to an individual’s genome.
  • Now repeat starting from the evaluation step with our new generation until we reach a termination condition.

In my previous post I stated we would either obtain or create a genetic algorithm program using Python.  I chose to obtain working code created by another individual from GitHubGist and modified it for galaxy rotation.

GApy

Again, Why Python?  Dr. Scott felt it was a good language to work with.  I’ve also heard it is widely used and simple to learn for someone not familiar with programing.  How was this decided?  Well, one of the sources for the P. Charbonneau (1995) article, Genetic Algorithms + Data Structures = Evolution Programs which has a much more simplistic way of using genetic algorithms.

Am I effectively working through my project objectives?

Yes, I would like to use the scientific writing style outlined in my Introduction to Senior Projects in Science course, to improve upon my scientific writing skills.

Introducing Genetic Algorithms for Galaxy Rotation Curves

Project: Looking for Dark Matter in the Rotation Curves of the Hubble Tuning Fork Galaxy Diagram

Department of Natural Sciences: Physics

Project adviser:  Dr. Scott Schneider

Researched by: Ceré L. Rettig

E-mail: crettig@ltu.edu

Project Summary as of: 10/16/2014

What is a galaxy rotation curve?

Galaxy rotation curves are a graphical analysis obtained from the magnitude of the orbital velocities of visible stars in a particular galaxy and their radial distance from the galaxies center, typically depicted with a scatter plot.

cropped-rotationcurve_3.jpg

What is the Hubble Tuning Fork Galaxy Diagram?

The Hubble Tuning Fork Galaxy Diagram is a way to classify galaxies.  Mr. Edwin Hubble believed that the elliptical galaxies (E0, E3, E5, E7) are “early galaxies” and that the lenticular (S0), and spiral galaxies (Sa, Sb, Sc, SBa, SBb, SBc) or “late galaxies” evolved from the elliptical galaxies.  In this model the lenticular galaxies are viewed as a transition type between the elliptical and spiral galaxies.  While this evolution model has been found to be incorrect, this is a good diagram used for galaxy classification.

Hubble Tuning Fork Galaxy Diagram

What is dark matter?

Dark matter accounts for effects that appear to be the result of mass where such mass cannot be seen.  It attracts or exerts a gravitational inward pull on the visible matter surrounding it.

Are we sure it is not dark energy?

Yes, because dark energy repels or pushes outward.

What is already known about spiral galaxy rotation curves?

Rotation curves are an essential tool for determining mass distribution in spiral galaxies, and provide fundamental information 

The existing programs that will be used were created by:

Dane Falberg is another student at Lawrence Technological University who is working on an astrophysics project advised by Dr. Scott Schneider.  He is creating a genetic algorithm program using java for his project that I will be able to use and modify for this project.

Project Objectives:

  • Research galaxy rotation curves for the six different types of spiral galaxies.
  • Investigate mathematical models for ordinary matter and dark matter to generate rotation curves.
  • Research genetic algorithms.
  • Study Dane Falberg’s programing with genetic algorithms.
  • Modify the software, to fit galaxy rotation.
  • If time is available see if this process can be done with lenticular galaxies.

References

J.Q. Feng and C.F. Gallo, Res. Astron. Astrophys. 11 1429-1449, 1 (2011).

Charbonneau, Astrophys. J. Suppl. Ser. 101 309-334, 1 (1995)

Sofue and V. Rubin, Ann. Rev. Astron. Astrophys. 39 181-0015, 1(2000).

____________________________________________________________________________________________________

What I’ve been working on:

  • Researching galaxy rotation curves for spiral galaxies, including: mathematical models for ordinary matter and dark matter to generate rotation curves.  
    • Read Charbonneau 1995 and found sources (data related).
  • Researching Vera Rubin and her work on galaxy rotation curves.
    • Read Sofue and Rubin 2000 and in progress of finding sources.
    • E-mailed Vera Rubin about data sets.

verarubin4

Why Vera Rubin?

Vera Rubin’s work on galaxy rotation curves is why it is possible for my project to exist today.  The discovery of her work was presented to both myself and Dr. Scott in the series finale of COSMOS: A Spacetime Odyssey with Neil deGrasse Tyson

“We have peered into a new world and have seen that it is more mysterious and more complex than we had imagined.  Still more mysteries of the universe remain hidden.  Their discovery awaits the adventurous scientists of the future.  I like it this way.”

tumblr_n94lv07RO21qio57co2_500

Genetic Algorithm Software

I will not be using Dane Falberg’s programming with genetic algorithms, it is too complicated.  Will be obtaining or creating a genetic algorithm program using Python.  Why Python?  Dr. Scott felt it was a good language to work with.  I’ve also heard it is widely used and simple to learn for someone not familiar with programming.  How was this decided?  Well, one of the sources for the Charbonneau 1995 article, Genetic Algorithms + Data Structures = Evolution Programs which has a much more simplistic way of using genetic algorithms.

Am I effectively working through my project objectives?

Yes, I would like to use the scientific writing style outlined in my Introduction to Senior Projects in Science course, to improve upon my scientific writing skills.

The Beginning of a Wonderful Project and an Incredibly Short Introduction to Vera Rubin

Project: Looking for Dark Matter in the Rotation Curves of the Hubble Tuning Fork Galaxy Diagram

Department of Natural Sciences: Physics

Project adviser:  Dr. Scott Schneider

Researched by: Ceré L. Rettig

E-mail: crettig@ltu.edu

Project Summary as of: 9/21/2014

Ceré L. Rettig June 2014

What is a galaxy rotation curve?

Galaxy rotation curves are a graphical analysis obtained from the magnitude of the orbital velocities of visible stars in a particular galaxy and their radial distance from the galaxies center, typically depicted with a scatter plot.

ngc3198_rc

What is the Hubble Tuning Fork Galaxy Diagram?

The Hubble Tuning Fork Galaxy Diagram is a way to classify galaxies.  Mr. Edwin Hubble believed that the elliptical galaxies (E0, E3, E5, E7) are “early galaxies” and that the lenticular (S0), and spiral galaxies (Sa, Sb, Sc, SBa, SBb, SBc) or “late galaxies” evolved from the elliptical galaxies.  In this model the lenticular galaxies are viewed as a transition type between the elliptical and spiral galaxies.  While this evolution model has been found to be incorrect, this is a good diagram used for galaxy classification.

Hubble Tuning Fork Galaxy Diagram

What is dark matter?

Dark matter accounts for effects that appear to be the result of mass where such mass cannot be seen.  It attracts or exerts a gravitational inward pull on the visible matter surrounding it.

Are we sure it is not dark energy?

Yes, because dark energy repels or pushes outward.

What is already known about spiral galaxy rotation curves?

Rotation curves are an essential tool for determining mass distribution in spiral galaxies, and provide fundamental information for understanding the evolution and formation of spiral galaxies.

The existing programs that will be used were created by:

Dane Falberg is another student at Lawrence Technological University who is working on an astrophysics project advised by Dr. Scott Schneider.  He is creating a genetic algorithm program using java for his project that I will be able to use and modify for this project.

Project Objectives:

  • Research galaxy rotation curves for the six different types of spiral galaxies.
  • Investigate mathematical models for ordinary matter and dark matter to generate rotation curves.
  • Research genetic algorithms.
  • Study Dane Falberg’s programing with genetic algorithms.
  • Modify the software, to fit galaxy rotation.
  • If time is available see if this process can be done with lenticular galaxies.

References

J.Q. Feng and C.F. Gallo, Res. Astron. Astrophys. 11 1429-1449, 1 (2011).
P. Charbonneau, Astrophys. J. Suppl. Ser. 101 309-334, 1 (1995)
Y. Sofue and V. Rubin, Ann. Rev. Astron. Astrophys. 39 181-0015, 1(2000).

What am I currently working on?

  • Researching galaxy rotation curves for spiral galaxies, including: mathematical models for ordinary matter and dark matter to generate rotation curves.  
  • Researching Vera Rubin and her work on galaxy rotation curves.

VeraRubin

Why Vera Rubin?

Vera Rubin’s work on galaxy rotation curves is why it is possible for my project to exist today.  The discovery of her work was presented to both myself and Dr. Scott in the series finale of COSMOS: A Spacetime Odyssey with Neil deGrasse Tyson.

neil_degrasse_tyson_quote

Written Proposal

Project: Looking for Dark Matter in the Rotation Curves of the Hubble Tuning Fork Galaxy Diagram

Department of Natural Sciences: Physics

Project adviser:  Dr. Scott Schneider

Researched by: Ceré L. Rettig

E-mail: crettig@ltu.edu

Ceré L. Rettig June 2014

What is a galaxy rotation curve?

Galaxy rotation curves are a graphical analysis obtained from the magnitude of the orbital velocities of visible stars in a particular galaxy and their radial distance from the galaxies center, typically depicted with a scatter plot.

ngc3198_rc

What is the Hubble Tuning Fork Galaxy Diagram?

The Hubble Tuning Fork Galaxy Diagram is a way to classify galaxies.  Mr. Edwin Hubble believed that the elliptical galaxies (E0, E3, E5, E7) are “early galaxies” and that the lenticular (S0), and spiral galaxies (Sa, Sb, Sc, SBa, SBb, SBc) or “late galaxies” evolved from the elliptical galaxies.  In this model the lenticular galaxies are viewed as a transition type between the elliptical and spiral galaxies.  While this evolution model has been found to be incorrect, this is a good diagram used for galaxy classification.

Hubble Tuning Fork Galaxy Diagram

What is dark matter?

Dark matter accounts for effects that appear to be the result of mass where such mass cannot be seen.  It attracts or exerts a gravitational inward pull on the visible matter surrounding it.

Are we sure it is not dark energy?

Yes, because dark energy repels or pushes outward.

What is already known about spiral galaxy rotation curves?

Rotation curves are an essential tool for determining mass distribution in spiral galaxies, and provide fundamental information for understanding the evolution and formation of spiral galaxies.

The existing programs that will be used were created by:

Dane Falberg is another student at Lawrence Technological University who is working on an astrophysics project advised by Dr. Scott Schneider.  He is creating a genetic algorithm program using java for his project that I will be able to use and modify for this project.

Project Objectives:

  • Research galaxy rotation curves for the six different types of spiral galaxies.
  • Investigate mathematical models for ordinary matter and dark matter to generate rotation curves.
  • Research genetic algorithms.
  • Study Dane Falberg’s programing with genetic algorithms.
  • Modify the software, to fit galaxy rotation.
  • If time is available see if this process can be done with lenticular galaxies.

References

J.Q. Feng and C.F. Gallo, Res. Astron. Astrophys. 11 1429-1449, 1 (2011).
P. Charbonneau, Astrophys. J. Suppl. Ser. 101 309-334, 1 (1995).
Y. Sofue and V. Rubin, Ann. Rev. Astron. Astrophys. 39 181-0015, 1(2000).

PSC 3001 Spring 2014 – Senior Project Proposal Requirements

PSC 3001 Spring 2014 – Senior Project Written Proposal FINAL CLR

PSC 3001 Spring 2014 – Senior Project Written Proposal Evaluation Rubric

PSC 3001 Spring 2014 – Final Proposal_Cere Rettig

Proposal Presentation

Project: Looking for Dark Matter in the Rotation Curves of the Hubble Tuning Fork Galaxy Diagram

Department of Natural Sciences: Physics

Project adviser:  Dr. Scott Schneider

Presented by: Ceré L. Rettig

E-mail: crettig@ltu.edu

Ceré L. Rettig June 2014

Project Objectives:

  • Research galaxy rotation curves for the six different types of spiral galaxies.
  • Investigate mathematical models for ordinary matter and dark matter to generate rotation curves.
  • Research genetic algorithms.
  • Study Dane Falberg’s programing with genetic algorithms.
  • Modify the software, to fit galaxy rotation.
  • If time is available see if this process can be done with lenticular galaxies.

Dane Falberg is another student at Lawrence Technological University who is working on an astrophysics project advised by Dr. Scott Schneider.  He is creating a genetic algorithm program using java for his project that I will be able to use and modify for this project.

Where did the idea come from?

The idea of doing a galaxy rotation curve project for the different types of spiral galaxies while accounting for dark matter came from Dr. Scott Schneider.  The idea of using genetic algorithms came from: P. Charbonneau, The Astrophysical Journal Supplemental Series 309, 101 (1995).  I decided to bring it all together with the Hubble Tuning Fork Galaxy Diagram because it is a general galaxy diagram that works for this project.

Hubble Tuning Fork Galaxy Diagram

What is dark matter?

Dark matter accounts for effects that appear to be the result of mass where such mass cannot be seen.  It attracts or exerts a gravitational inward pull on the visible matter surrounding it.

Are we sure it is not dark energy?

Yes, because dark energy repels or pushes outward.

What is a galaxy rotation curve?

Galaxy rotation curves are a graphical analysis obtained from the magnitude of the orbital velocities of visible stars in a particular galaxy and their radial distance from the galaxies center, typically depicted with a scatter plot.

What does this look like?

ngc3198_rc

Similar to Dr. Scott's in office drawing.

Thank you Dr. Julie Zwiesler-Vollick for pointing out unlike the first graph (the one in my midterm presentation) the one I drew and used in my proposal presentation does not have the axes labeled.

What is a genetic algorithm?

Genetic algorithms are a quick computational approach using evolution through natural selection. They are often used in computer science, artificial intelligence and computer-aided engineering design but not as often in physical sciences. In this project they will be used as a quick but effective approach to solving mathematical equations.

A special thanks to Len Hernandez for attending my presentation!

Faculty: Dr. Shannon TimmonsDr. Julie Zwiesler-VollickDr. Nicole VilleneuveJeffery Morrissette, student presentations.

PSC 3001 Spring 2014 Proposal Presentation Dark Matter in the Rotation Curves FINAL

PSC 3001 Spring 2014 – Proposal Presentation Evaluation Rubric

PSC 3001 Spring 2014 – Proposal Presentation Evaluation_Cere Rettig

PSC 3001 Spring 2014 – Senior Project Proposal Requirements

Proposal Requirements and Tips for a Successful Project

While a lot of this seemed rather elementary, the main focus was “work hard, but remember to have fun.”  As so many people get so caught up into seeing results they do not always have as much fun as they could working on their project.  Being a serious student, this was good to hear for an hour straight.  I am often one of those people so caught up in “doing well” and getting “desirable results” that I do not take enough time to realize how awesome it is to be at Lawrence Tech.  Lawrence Tech isn’t just another private university, it’s home until graduation, even for those who do not live on campus.  We spend so much time there it is definitely our home during the school year.  The relationships we form with are professors are so wonderful and they are just as much family to us as our friends are.  It’s a place you go for an education and in the process are transformed into a person you never thought you could be.

work hard

Faculty: Dr. Shannon Timmons

PSC 3001 Spring 2014 – Tips for a Successful Project