class rgpot::PotentialBase

Overview

Abstract base class for all potential energy surfaces. More…

#include 

class PotentialBase {
public:
    // construction

    PotentialBase(PotType inp_type);
    virtual ~PotentialBase();

    // methods

    virtual std::pairAtomMatrix> operator()(const AtomMatrix& positions, const std::vector& atmtypes, const std::array, 3>& box) = 0;
    PotType get_type() const;
};

Detailed Documentation

Abstract base class for all potential energy surfaces.

Construction

PotentialBase(PotType inp_type)

Constructor for PotentialBase.

Parameters:

inp_type

The type of the potential.

virtual ~PotentialBase()

Virtual destructor.

Methods

virtual std::pairAtomMatrix> operator()(const AtomMatrix& positions, const std::vector& atmtypes, const std::array, 3>& box) = 0

Main interface for potential and force calculation.

Parameters:

positions

The atomic coordinates.

atmtypes

The atomic numbers.

box

The simulation cell vectors.

Returns:

A pair containing the energy and the force matrix.

PotType get_type() const

Fetches the potential type.

Returns:

The potential type.