Tag Info

New answers tagged

2

You can use Mathematica's parallel tools, which already implement inter-kernel communication. What I show below is not the typical way to use parallelization. I try to follow your requirements more closely. I do strongly recommend you read through the parallelization docs and learn the basics before you use this though. When using the parallelization ...


0

The standard way is to use in the main notebook the DistributeDefinitions[{list of yoyr variables}]command. It will automatically share all mentioned mathematica names and it's content to all kernels. This in turn will make it available in all notebooks related to those kernels. But why do you use some notebooks for parallelization? Any tasks could be run ...


1

The random crashing of the kernel seems to arise due to your definition of evolve and fct. I'll keep h[x_, p_] := -x^2 + p^2 + x^4; and change the definition of evolve to evolve[xini_, pini_, time_] := Module[{x, p}, Hold[{x[time], p[time]} /. First@NDSolve[{x'[t] == p[t], p'[t] == -x[t], x[0] == xini, p[0] == pini}, {x, p}, ...


0

The easiest way to do this is to launch the kernel as a slave from Java. The standard way is to use these args java ... className -linkmode launch -linkname (* path to kernel *) And in your class: KernelLink ml = null; try { ml = MathLinkFactory.createKernelLink(argv); } catch (MathLinkException e) { ... }



Top 50 recent answers are included