Program Listing for File LandscapeMetricsCalculator.h

Return to documentation for file (LandscapeMetricsCalculator.h)

// This file is part of necsim project which is released under MIT license.
// See file **LICENSE.txt** or visit for full license details
#include <vector>
#include <numeric>
#include "necsim/Map.h"
#include "necsim/Cell.h"


using namespace std;
using namespace necsim;
class LandscapeMetricsCalculator : public Map<double>
    vector<Cell> all_cells;

    LandscapeMetricsCalculator() : all_cells(){};

    virtual ~LandscapeMetricsCalculator(){};

    double calculateMNN();

    void checkMinDistance(Cell &home_cell, const long &x, const long &y, double &min_distance);

    double findNearestNeighbourDistance(const long &row, const long &col);

    void createCellList();

    double calculateClumpiness();

    unsigned long calculateNoAdjacencies();

    double calculateMinPerimeter();