MathGroup Archive 2006

[Date Index] [Thread Index] [Author Index]

Search the Archive

RE: Re: Performance--Dual Core

  • To: mathgroup at
  • Subject: [mg70150] RE: [mg70102] Re: Performance--Dual Core
  • From: "Coleman, Mark" <Mark.Coleman at>
  • Date: Thu, 5 Oct 2006 03:33:19 -0400 (EDT)

Thanks for posting this. I'm curious, Does the same default to one core apply to the Intel-based Mac's as well?



-----Original Message-----
From: Antti Penttilä [mailto:Antti.I.Penttila at] 
To: mathgroup at
Subject: [mg70150] [mg70102] Re: Performance--Dual Core

oparadis at wrote:
> I am puzzled by the fact mathematica seems to be using the CPU resources from a single core at the time even though the problem it tries to solve is very complicated (takes 1 day approx.). While computing, windows' task manager shows "MathKernel" using 50% of CPU and "System Idle Process" using the remaining 50%.


I had the same problem, and this trick from Pratik Desai from Wolfram solved the problem:

"Mathematica 5.2 defaults to using only one thread for linear algebra on Windows. To use multiple threads and take advantage of multiple processors or cores, you will need to set OMP_NUM_THREADS to a value of % NUMBER_OF_PROCESSORS% in your environment. You can do this by going to My Computer and get to the properties template by right clicking and clicking Properties, click the Advanced Tab and then click on Environment Variables. Click on New right below the System Variables list. In the the variable name type in OMP_NUM_THREADS and variable value type in % NUMBER_OF_PROCESSORS%

Variable Name : OMP_NUM_THREADS

Now you can try your linear algebra operations. Dot on two matrices is the best indicator of your multiprocessing capabilities.


After this fix the dual-core should work with Mathematica. However, only some operations, typically linear algebra, are threaded to parallel use.


  • Prev by Date: Re: distance function
  • Next by Date: Re: Faster ways to unionize intersecting sets?
  • Previous by thread: Re: Performance--Dual Core
  • Next by thread: xvnc Mathematica menu fonts