5
$\begingroup$

I just got a raspberry pi 3 and want to get a rough idea of the max temp I might reach while doing intensive calculations. What would you suggest I calculate in mathematica to get the pi hot?

Criteria are:

  1. Something in mathematica
  2. Low Ram usage
  3. Low time (5-15 minutes)
  4. High cpu usage (I want my pi to get the hottest it's ever going to get while running mathematica specifically)

Thanks!

$\endgroup$
8
  • $\begingroup$ None. Use this (or something similar) instead. $\endgroup$ May 3, 2016 at 3:35
  • $\begingroup$ Thanks, but I'm looking for an actual temp rather than a synthetic. I've already run sysbench, I think it was. Primes up to 20000, 5x consecutively with temp readings in between. Got up only to 60C with the small fan and case I have. Want to compare this with actual temps while running mathematica. $\endgroup$ May 3, 2016 at 3:42
  • $\begingroup$ Really? Vote me down just because I want a real temp rather than a synthetic? $\endgroup$ May 3, 2016 at 3:46
  • $\begingroup$ @user21 Honestly, hardly anything. I'm new to mathematica in general. Wasn't sure what wouldn't max out the memory or take more than ten or so minutes, but still tax the cpu heavily. $\endgroup$ May 3, 2016 at 3:58
  • $\begingroup$ You probably got downvoted because of your imprecise specifications. Mathematica can be used to do any sort of computation you can imagine, and they all have different performance parameters. That's why I suggested you use a synthetic loop to examine the worst case, which is all that really matters, isn't it? Anyway, what sort of application do you have in mind, in order to be able to get some suggestions? $\endgroup$ May 3, 2016 at 4:02

2 Answers 2

3
$\begingroup$

You can try the built-in Benchmark[] function (requires importing the Benchmarking package).

Needs["Benchmarking`"]
Benchmark[]

Be aware that it will take a long time: https://mathematica.stackexchange.com/a/74184/6849

$\endgroup$
3
  • 3
    $\begingroup$ ParallelEvaluate[Benchmark[]] to have it running on all cores. But this probably doesn't satisfy the "Low Ram usage" criterion. $\endgroup$
    – Karsten7
    May 3, 2016 at 13:48
  • $\begingroup$ This is currently the best solution I've found and really seems to let me know max temps while running just about any calculation Mathematica is capable of. The Parallel Evaluate tip is absolutely necessary, so thanks Karsten. I haven't checked what this does RAM wise, but if RAM usage is high, it's not hindering the CPU from being taxed for all it's worth. Time is my biggest complaint. Something quicker would be nice. $\endgroup$ May 4, 2016 at 4:20
  • $\begingroup$ Also, just for comparison sake, running "ParallelEvaluate[Benchmark[]]" with this fan solution: amazon.com/gp/product/B019SIAGTO/… temperatures never got above 64C. I'd love to hear similar stats from others. $\endgroup$ May 4, 2016 at 4:25
1
$\begingroup$

Here's a self-answer just for example:

AbsoluteTiming[
ParallelTable[
 FactorInteger[Prime[i]], {i, 300000000001, 300000000004}]]

This I suppose does the job, but I'd love to have someone else suggest something that might better fulfill my criteria.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.