Nemo  2.3.56
Simulate forward-in-time genetic evolution in a spatially explicit, individual-based stochastic simulator
main.cc File Reference
#include "simulation.h"
#include "simenv.h"
#include "metapop.h"
#include "Uniform.h"

Functions

int main (int argc, char **argv)
 

Detailed Description

Id
main.cc,v 1.4 2015-07-13 08:52:57 fred Exp

Nemo2

Copyright (C) 2006-2015 Frederic Guillaume frede.nosp@m.ric..nosp@m.guill.nosp@m.aume.nosp@m.@ieu..nosp@m.uzh..nosp@m.ch

This file is part of Nemo

Nemo is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

Nemo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

created on

Date
19.07.2004
Author
fred

Function Documentation

◆ main()

int main ( int  argc,
char **  argv 
)
40{
41 //--------------------------------------------------------------------
42
43 Metapop *thePop = new Metapop;
44 SimRunner *theSim = SIMenv::setMainSim( thePop );
45
46 // initialize the random number generator with default seed
47 // it will be reinitialized later with user-provided seed, if any
48 RAND::init(time(0));
49
50 if( !theSim->run(argc, argv) ) fatal(" could not run the simulation!\n");
51
52 delete theSim;
53 delete thePop;
54
55 return 0;
56}
Top class of the metapopulation structure, contains the patches.
Definition: metapop.h:80
static void init(unsigned long seed)
Initialize the random generator's seed.
Definition: Uniform.h:83
static SimRunner * setMainSim(Metapop *pop)
Definition: simenv.h:46
Performs the setup of the Metapop and SimComponents and runs the simulation.
Definition: simulation.h:53
bool run(int ARGC, char **ARGV)
First loop of the simulation, performs the simulations stored in the ParamManager base class.
Definition: simulation.cc:345
void fatal(const char *str,...)
Definition: output.cc:96

References fatal(), RAND::init(), SimRunner::run(), and SIMenv::setMainSim().


Generated for Nemo v2.3.56 by  doxygen 1.9.0 -- Nemo is hosted on  Download Nemo

Locations of visitors to this page
Catalogued on GSR