Skip to content
Snippets Groups Projects
Commit 9826086a authored by Gareth Tribello's avatar Gareth Tribello
Browse files

Finding highest/lowest now works with PAMM

parent ad8bf788
No related branches found
No related tags found
No related merge requests found
#! FIELDS time p.mean-1 p.between-1 p.between-2
0.000000 0.9911 10.2441 0.5412
1.000000 0.9980 10.0760 0.4862
2.000000 0.9981 10.0747 0.4856
3.000000 0.9959 10.1309 0.4965
4.000000 0.9981 10.0696 0.4849
5.000000 0.9954 10.1524 0.5005
#! FIELDS time p.mean-1 p.between-1 p.between-2 p.highest
0.000000 0.9911 10.2441 0.5412 0.0002
1.000000 0.9980 10.0760 0.4862 0.0002
2.000000 0.9981 10.0747 0.4856 0.0003
3.000000 0.9959 10.1309 0.4965 0.0003
4.000000 0.9981 10.0696 0.4849 0.0019
5.000000 0.9954 10.1524 0.5005 0.0001
This diff is collapsed.
......@@ -53,8 +53,8 @@ TORSIONS ...
DUMPMULTICOLVAR DATA=psi FILE=psi.xyz
DUMPMULTICOLVAR DATA=phi FILE=phi.xyz
PAMM DATA=phi,psi CLUSTERS=2D-testc-0.75.pammp MEAN1={COMPONENT=1} HISTOGRAM={GAUSSIAN NBINS=2 LOWER=0.0 UPPER=1.0 COMPONENT=2} LABEL=p
# PAMM DATA=phi,psi CLUSTERS=2D-testc-0.75.pammp MEAN1={COMPONENT=1} HISTOGRAM={GAUSSIAN NBINS=2 LOWER=0.0 UPPER=1.0 COMPONENT=2} NUMERICAL_DERIVATIVES LABEL=pn
PAMM DATA=phi,psi CLUSTERS=2D-testc-0.75.pammp MEAN1={COMPONENT=1} HISTOGRAM={GAUSSIAN NBINS=2 LOWER=0.0 UPPER=1.0 COMPONENT=2} HIGHEST={COMPONENT=4} LABEL=p
# PAMM DATA=phi,psi CLUSTERS=2D-testc-0.75.pammp MEAN1={COMPONENT=1} HISTOGRAM={GAUSSIAN NBINS=2 LOWER=0.0 UPPER=1.0 COMPONENT=2} HIGHEST={COMPONENT=4} NUMERICAL_DERIVATIVES LABEL=pn
PRINT ARG=p.* FILE=colvar FMT=%8.4f
DUMPDERIVATIVES ARG=p.* FILE=deriv FMT=%8.4f
......
......@@ -156,10 +156,8 @@ MultiColvarFunction(ao)
{
// Check for reasonable input
for(unsigned i=0;i<getNumberOfBaseMultiColvars();++i){
if( getBaseMultiColvar(i)->getNumberOfQuantities()!=2 ) error("cannot use PAMM with " + getBaseMultiColvar(i)->getName() );
if( getBaseMultiColvar(i)->getNumberOfQuantities()!=2 ) error("cannot use PAMM with " + getBaseMultiColvar(i)->getName() );
}
// This builds the lists
buildSets();
bool mixed=getBaseMultiColvar(0)->isPeriodic();
for(unsigned i=0;i<getNumberOfBaseMultiColvars();++i){
......@@ -184,22 +182,26 @@ MultiColvarFunction(ao)
while( ifile.scanField("weight",weight) ) {
for(unsigned i=0;i<center.size();++i){
ifile.scanField("center-"+getBaseMultiColvar(i)->getLabel(),center[i]);
}
}
for(unsigned i=0;i<center.size();++i){
for(unsigned j=0;j<center.size();++j){
ifile.scanField("width-"+getBaseMultiColvar(i)->getLabel()+"-" + getBaseMultiColvar(j)->getLabel(),covar(i,j) );
}
}
}
Invert( covar, icovar );
unsigned k=0;
for(unsigned i=0;i<ncolv;i++){
for(unsigned j=i;j<ncolv;j++){ sig[k]=icovar(i,j); k++; }
}
ifile.scanField();
// std::string ktype; ifile.scanField("kerneltype",ktype);
kernels.push_back( KernelFunctions( center, sig, "GAUSSIAN", "VON-MISES", weight ) );
kernels[kernels.size()-1].normalize( pos );
}
}
ifile.close();
// This builds the lists
buildSets();
// I think we can put this back for anything with not usespecies
// Now need to pass cutoff information to underlying distance multicolvars
......
......@@ -58,7 +58,7 @@ void OrderingVessel::finish( const std::vector<double>& buffer ){
mydata->retrieveDerivatives( mini, false, myvals ); Value* fval=getFinalValue();
for(unsigned i=0;i<myvals.getNumberActive();++i){
unsigned ider=myvals.getActiveIndex(i);
fval->setDerivative( ider, myvals.getDerivative(1,ider) );
fval->setDerivative( ider, myvals.getDerivative(mycomponent,ider) );
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment