18 #ifndef _TORSIONPOTENTIAL_H_
19 #define _TORSIONPOTENTIAL_H_
23 #include <AminoAcidCode.h>
24 #include <Potential.h>
28 using namespace Victor::Energy;
30 using namespace Victor::Biopool;
32 using namespace Victor;
33 namespace Victor {
namespace Energy {
52 virtual long double calculateEnergy(
Spacer& sp) = 0;
53 virtual long double calculateEnergy(
Spacer& sp,
unsigned int index1,
54 unsigned int index2) = 0;
55 virtual long double calculateEnergy(
AminoAcid& aa) = 0;
57 virtual long double calculateEnergy(
AminoAcid& diheds, AminoAcidCode code) = 0;
60 virtual double calculateMaxEnergy(
Spacer& sp);
61 virtual double calculateMinEnergy(
Spacer& sp);
62 virtual double calculateMaxEnergy(
unsigned int amino);
63 virtual double calculateMinEnergy(
unsigned int amino);
64 virtual double pReturnMaxPropensities(
int amino) = 0;
66 virtual double pReturnMinPropensities(
int amino) {
67 ERROR(
"ERROR. NOT IMPLEMENTED FOR THIS CLASS.", exception)
72 virtual double pReturnMaxPropensitiesPreAngle(
int amino,
int prephi,
int prepsi) {
73 ERROR(
"ERROR. NOT IMPLEMENTED FOR THIS CLASS.", exception)
76 virtual double pReturnMinPropensitiesPreAngle(
int amino,
int prephi,
int prepsi) {
77 ERROR(
"ERROR. NOT IMPLEMENTED FOR THIS CLASS.", exception)
81 virtual int sGetPropBin2(
double p) {
82 ERROR(
"ERROR. NOT IMPLEMENTED FOR THIS CLASS.", exception)
85 virtual vector< vector<ANGLES> >* orderedEnergy() {
86 ERROR(
"ERROR. NOT IMPLEMENTED FOR THIS CLASS.", exception);
89 virtual string getLabel() {
90 return "torsion potential";
100 virtual void pConstructData() = 0;
101 virtual void pResetData() = 0;
103 virtual double getOmegaAngle(
int prop,
long RANGE_OMEGA) {
104 ERROR(
"ERROR. NOT IMPLEMENTED FOR THIS CLASS.", exception)
107 virtual double getPhiPsiAngle(
int prop,
long SIZE_TABLE,
int ARC_STEP) {
108 ERROR(
"ERROR. NOT IMPLEMENTED FOR THIS CLASS.", exception)
127 return -log(pReturnMaxPropensities(static_cast<int> (amino)));
136 return -log(pReturnMinPropensities(static_cast<int> (amino)));
145 long double tmp = 0.0;
146 for (
unsigned int i = 1; i < sp.
sizeAmino() - 1; i++)
147 tmp += calculateMaxEnergy(sp.
getAmino(i).getCode());
157 long double tmp = 0.0;
158 for (
unsigned int i = 1; i < sp.
sizeAmino() - 1; i++)
159 tmp += calculateMinEnergy(sp.
getAmino(i).getCode());
165 #endif// _TORSIONPOTENTIAL_H_
AminoAcid & getAmino(unsigned int n)
Definition: Spacer.cc:962
const unsigned int sizeAmino() const
Definition: Spacer.cc:197
Abstract class for the energy potential.
Definition: Potential.h:37
virtual double calculateMaxEnergy(Spacer &sp)
Definition: TorsionPotential.h:144
It mplements a simple amino acid.
Definition: AminoAcid.h:43
This class implements a simple torsion potential based on the statistical preference of aminoacid typ...
Definition: TorsionPotential.h:40
Implements a "Spacer" for a protein chain. Includes methods to obtain values from the atoms and its p...
Definition: Spacer.h:42
virtual double calculateMinEnergy(Spacer &sp)
Definition: TorsionPotential.h:156