Results 1 to 6 of 6
  1. #1
    Felicia is offline Member
    Join Date
    Mar 2010
    Posts
    3
    Rep Power
    0

    Default I need help solving this problem.

    The following table is provided by a laboratory, consisting of a serial of samples recorded during the
    bio-chemical refining process
    x f(x)
    0 0
    15 0.221456693
    30 0.415231299
    45 0.581323819
    60 0.719734252
    75 0.830462598
    90 0.913508858
    105 0.968873031
    120 0.996555118
    128 1
    135 0.996555118
    150 0.968873031
    165 0.913508858
    180 0.830462598
    195 0.719734252
    210 0.581323819
    225 0.415231299
    240 0.221456693
    255 0
    We will use this table to model a polynomial that interpolates f(x) at the given point

    ================================================== ========
    This polynomial will be used to calculate the fitness of the individual that we will randomly determine.
    Write a java program that:
    1. Calculates the interpolation polynomial that we will denote P(x).
    The values from the table above are provided by Polynomial.txt file that your Java program
    will open and read through a dialog box.
    2. Initializes the population by using a random number generator (maximum of 16 individuals).
    This initialization should be done by using the binary string (Don’t use native binary, use
    rather Gray representation) of maximum 8 digits
    3. Transforms the gray representation of each individual into the decimal coding
    4. Calculates the fitness of each individual
    a. Calculate the frequency of each individual
    b. Normalize the frequency of each individual
    c. Calculate the cumulative frequency of each individual
    d. Generate 16 random numbers to determine the destiny of each individual
    5. Reproduces new population and pairs up the individuals based on their sequence of
    apparition in 4.d (to be selected).
    6. Applies crossover as follow:
    a. For each pair, a random Boolean will determine if the pair is subject to crossover or
    not (all the pairs should be affected).
    b. If yes, two random numbers between 0 to 7 will be generated to each individual to
    determine the range where crossover will be applied (First number = start, second
    number = end).
    7. Applies randomly one mutation on each individual (jth bit where j = number of bits to “1” in
    this individual. E.g. for 10011000, bit 3 should be muted)
    8. Produce the result of the first generation
    9. Runs recursively until produce the result of the 5th generations
    10. Provide your conclusion
    Bonus : Modify your program and run it until you get all the individual with fitness greater than
    0.95. How many generations were needed to get this output?

  2. #2
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,783
    Blog Entries
    7
    Rep Power
    21

    Default

    Great, and what is your question?

    kind regards,

    Jos

  3. #3
    Felicia is offline Member
    Join Date
    Mar 2010
    Posts
    3
    Rep Power
    0

    Default Java problem

    my question is if you can provide me with the code to achieve numb 1 through to number 4d. Thanks

  4. #4
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,783
    Blog Entries
    7
    Rep Power
    21

    Default

    Quote Originally Posted by Felicia View Post
    my question is if you can provide me with the code to achieve numb 1 through to number 4d. Thanks
    That's not a question either; it's a command such as "do my homework for me". We don't do that here but we're very willing to help when you're stuck with your homework.

    kind regards,

    Jos

  5. #5
    Felicia is offline Member
    Join Date
    Mar 2010
    Posts
    3
    Rep Power
    0

    Default This is what I need actually

    Can you help me with the opening Java statement. I do not want you to do my homework for me. But I just need a lead how to start cos I have no clue what the opening statement is. With that I can do the rest.

  6. #6
    dunafrothint is offline Member
    Join Date
    Oct 2009
    Posts
    26
    Rep Power
    0

    Default

    Here's a good site to start learning Java, if thats what you're looking for: Java Basics.

Similar Threads

  1. Pls help me in solving this java question
    By dunnoGUy in forum New To Java
    Replies: 1
    Last Post: 02-28-2010, 08:10 AM
  2. Replies: 13
    Last Post: 02-20-2010, 08:56 PM
  3. Solving this equations problem in Java
    By matt_well in forum New To Java
    Replies: 17
    Last Post: 08-30-2008, 10:05 PM
  4. Suggestions required for solving a Java problem
    By bilal_ali_java in forum Advanced Java
    Replies: 3
    Last Post: 08-16-2008, 02:11 AM
  5. I need a help in solving this method using vectors
    By java_fun2007 in forum New To Java
    Replies: 2
    Last Post: 11-26-2007, 08:51 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •