+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    Junior Member
    Join Date
    Apr 2009
    Posts
    1

    Java help request with bacteria colony problem

     
    This thing is due Wednesday and I have NO clue on how to do this. I don't even know where to start. This is what I have to do:

    If a colony of bacteria grows at the rate of 9% per hour, then in eight hours the colony will double its size. Thus, the doubling time is eight hours. The so-called rule of 72 can be used to compute doubling times. If a quantity grows by R percent in a single period of time, then the number of periods required for the quantity to double is approximately 72/R. Given the growth rate and the original quantity, print the hourly size of the bacteria colony until it doubles. Have the computer compare the doubling time found by the rule-of-72 approach with the answer determined iteratively from the growth rate.

    Read the hourly growth rate (as a decimal) and the colony size in individuals. Print meaningful headers. For each hour, print the number of the hour just ended, the initial colony size for that hour, and the new colony size computed from the rate of growth. Repeat until the colony has at least doubled. Interpolate your final hour, and beginning and ending colony sizes to get the doubling times in hours. Then computer the doubling size using the rule of 72. At the end, print both doubling times, to the nearest tenth, with appropriate labels.

    Write a class method to compute each hour's growth in population by the growth-rate method. Write a class method to compute the doubling time using the rule of 72. Use formatted print statement(s), centering the computed data under their headings. Spread the headings and columns out so that the output is easy to read. Make sure no Java line is so long that it wraps when you print it.

    I also HAVE to use Eclipse because that is all we have to use at the school and that's all the teacher was teaching us with. I appreciate everyone who comes in and helps me out. I have no clue where to start and end this thing and I have barely understood Java from where we started like a month ago.

  2. #2
    Super F@D Folder
    Join Date
    Jun 2004
    Posts
    5,091
    My recommendation if you really don't even have any idea where to start would be to ask your teacher for help.

    I'll give you a little nudge though. Break it down into steps. Do you understand the rule of 72? Do you understand how to get the input? Do you understand how to get the population growth mathematically by the hour?

    Break it down into steps that you can manage. Then go through and code them one by one.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Java help request
    By cowgirl1976 in forum Webmastering and Programming
    Replies: 1
    Last Post: April 20th, 2009, 11:16 PM
  2. Some bacteria needs only 1 gene to move from one species to another.
    By no1_vern in forum DebateIMO: Politics, Religion, Controversy
    Replies: 2
    Last Post: February 2nd, 2009, 02:11 PM
  3. Africain Bacteria Ate Holes In Her Eyes..
    By TrendyMartini in forum IMO Community
    Replies: 3
    Last Post: May 22nd, 2007, 02:34 PM
  4. Bacteria froze the Earth
    By no1_vern in forum IMO Community
    Replies: 2
    Last Post: August 8th, 2005, 07:22 AM
  5. Our Colony
    By butch81385 in forum General Gaming Discussion
    Replies: 202
    Last Post: May 14th, 2005, 04:31 PM

Tags for this Thread

Posting Permissions

  • You may post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Recommended Sites: ResellerRatings Store Reviews