use of cbit.vcell.solver.server.Solver in project vcell by virtualcell.
the class ClientSimManager method createQuickRunSolver.
public static Solver createQuickRunSolver(File directory, SimulationTask simTask) throws SolverException, IOException {
SolverDescription solverDescription = simTask.getSimulation().getSolverTaskDescription().getSolverDescription();
if (solverDescription == null) {
throw new IllegalArgumentException("SolverDescription cannot be null");
}
// ----- 'FiniteVolume, Regular Grid' solver (semi-implicit) solver is not supported for quick run; throw exception.
if (solverDescription.equals(SolverDescription.FiniteVolume)) {
throw new IllegalArgumentException("Semi-Implicit Finite Volume Compiled, Regular Grid (Fixed Time Step) solver not allowed for quick run of simulations.");
}
SolverUtilities.prepareSolverExecutable(solverDescription);
// create solver from SolverFactory
Solver solver = SolverFactory.createSolver(directory, simTask, false);
return solver;
}
Aggregations