Processor usage decreases unexpectedly for ode45 in MATLAB R2013a

1 visualizzazione (ultimi 30 giorni)
I have a program were I solve a set of differential equations with different initial conditions, looping over the initial conditions, so I run ode45 inside of a for loop. I've noticed that ode45 seems to have some sort of built in parallelization, as it uses 4 (of 8) available cores on my machine.
However, I've recently had the issue that usually about halfway through the instances in the for loop, ode45 stops using 4 cores and only uses 2. I'm not running anything else on the machine simultaneously, so I'm not sure what could be causing this, and it significantly slows down my calculations.
Does anyone have an idea what could be happening, and how to fix it?
  1 Commento
John D'Errico
John D'Errico il 4 Lug 2014
The multiple cores comes from MATLAB, not explicitly ode45. MATLAB uses multiple cores essentially when it perceives there will be a gain from doing so. (Not an exactly true statement, but you should get the idea.) If other process are happening in the middle, then your CPU may use them instead.

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Programming in Help Center e File Exchange

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by