Click here to Skip to main content
Licence 
First Posted 1 Jul 2007
Views 10,170
Bookmarked 7 times

BacteriaGrowth

By | 1 Jul 2007 | Article
Calculate reproduction of bacteria from primary bacteria

Download Bacteria_Source.zip - 35.3 KB

Screenshot - Bacteria.jpg

Introduction

Bacteria growth is a very important subject in microbiology and medical science. There is formula for determining reproduced bacteria from primary bacteria. In this formula we use log function, regeneration time and period time.

Formula is:

Logb= t*log2+(g*loga)/g

That t is period time,

Logb is reproduced bacteria,

Loga is primary bacteria

And g is regeneration time.

If t*log2+loga/g equals to Re, For calculate b you must follow it. b= 10^Re.

I wrote a program in VC++6 that calculate reproduced bacteria from primary bacteria. BacteriaGrowth method calculates it. This method defined in BacteriaGrowth.h file inside _BACTERIA structure. In this method nPrimary parameter is primary bacteria, reGenerationTime is Regeneration time for reproducing one bacterium to two bacteria and PeriodTime is total time for result.


Using the code

Source code is:
//
#include <windows.h>
#include <math.h>

typedef struct _BACTERIA
{
    double BacteriaGrowth(ULONG nPrime, 
        ULONG reGenerationTime, ULONG Period);
    
}BACTERIA;

//Retrurn Number of reproduced bacteria after periodtime 
//and with regenerationtime
double BACTERIA::BacteriaGrowth(ULONG nPrimary, 
            ULONG reGenerationTime,ULONG PeriodTime) 
{
    double Num=0;
    Num=(PeriodTime*log10(2)+(reGenerationTime*log10(nPrimary)))
        /reGenerationTime;
    return (double)powl(10,Num);
}
//

Points of Interest

BacteriaGrowth method is very useful for microbiology, medical and nutrition laboratory. for example: 3 bacteria while 4 hours(240 minutes) and after 15 minutes reproduce 196608 bacteria.

History

Not update.

Copyright

This is my own code and No Copyright. So you can change or distribute it freely.

Special Thanks

My mother and father.

Reference

Formula for determining reproduced bacteria is obtained from "Food Microbiology, author: Abolfath shojai arani (Ph.D.). Tehran- Iran 1376. ISBN 964-4555-00-4".

Please visit my web blogs:

http://www.sci11.blogspot.com (Visual C++& Mathematic)

http://www.sci12.blogspot.com (Visual C++&Chemistry)

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

About the Author

Sayyeid Mostafa Hashemi

Software Developer (Senior)

Iran (Islamic Republic Of) Iran (Islamic Republic Of)

Member

I am Mostafa Hashemi.I was born in Tehran. I graduated from IUMS university in 2002 (1381). Although my university field different from programming, but I like it. Since I acquainted with computer, I have been interested in Visual C++. I have been beginning to program in Visual C++ in 2003.
Thanks,
http://www.afzarhesabacc.com

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
You must Sign In to use this message board. (secure sign-in)
 
Search this forum  
 FAQ
    Noise  Layout  Per page   
  Refresh
GeneralYou might have gathered that the votes on your article so far are not the very best Pinmemberx-b0:58 3 Jul '07  

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Mobile
Web02 | 2.5.120517.1 | Last Updated 2 Jul 2007
Article Copyright 2007 by Sayyeid Mostafa Hashemi
Everything else Copyright © CodeProject, 1999-2012
Terms of Use
Layout: fixed | fluid