// Using the function: 1/4 x^4 - 1/2 x^2 + 1/2 y^2
IEnergyModel pot = potNew.multivariateFromExpression(new String[]{"x","y"},
"1/4 x^4 - 1/2 x^2 + 1/2 y^2", // function expression
"x^3-x", "y"); // derivatives
// integrator
IDoubleArray masses = doublesNew.arrayFrom(1.0, 1.0);
double dt = 0.1, gamma = 1, kT = 0.2;
IIntegratorThermostatted langevin = dynNew.langevinLeapFrog(pot, masses, 0.1, gamma, kT);
// run
IDoubleArray x0 = doublesNew.arrayFrom(0,0);
int nsteps = 100000, nsave = 10;
IDataSequence seq = dyn.run(x0, langevin, nsteps, nsave);
// TICA
int lag = 1;
TICA tica = new TICA(lag);
tica.addData(seq);
tica.computeTransform();
System.out.println("mean: \t"+doubles.toString(tica.getMeanVector(), "\t"));
System.out.println("cov: \t"+doubles.toString(tica.getCovarianceMatrix(), "\t", "\n"));
System.out.println("covTau: \t"+doubles.toString(tica.getCovarianceMatrixLagged(), "\t", "\n"));
System.out.println();
System.out.println("eval: \t"+doubles.toString(tica.getEigenvalues(), "\t"));
System.out.println("evec1: \t"+doubles.toString(tica.getEigenvector(0), "\t"));
System.out.println("evec2: \t"+doubles.toString(tica.getEigenvector(1), "\t"));
tica.setDimension(1);
IDoubleArray y1 = tica.transform(doublesNew.arrayFrom(2,2));
System.out.println("y1 = \t"+doubles.toString(y1, "\t"));
IDoubleArray y2 = tica.transform(doublesNew.arrayFrom(4,4));
System.out.println("y2 = \t"+doubles.toString(y2, "\t"));
}