Running a matrix of integrals in parallel

  • Mathematica
  • Thread starter joshmccraney
  • Start date
  • #1
joshmccraney
Gold Member
1,918
92

Main Question or Discussion Point

Hi PF!

I am trying to computer a matrix of integrals. Think of it something like this:

Code:
Table[Integrate[x^(i*j), {x, 0, 1}], {i, 0, 5}, {j, 0, 5}]
I have 16 cores, and would like to have each core handle a specified amount of integrals. Anyone know how to do this?

Thanks so much!
 

Answers and Replies

  • #3
joshmccraney
Gold Member
1,918
92
  • #4
DrClaude
Mentor
7,259
3,413
I don't program much in Mathematica, but I have used other people's programs. Using ParallelTable in your case should be the fastest option, but it is possible that Parallelize[Table[]] would result in the same (I have stopped trying to figure out how Mathematica deals with things internally; it is quite opaque).
 
  • #5
joshmccraney
Gold Member
1,918
92
I don't program much in Mathematica, but I have used other people's programs. Using ParallelTable in your case should be the fastest option, but it is possible that Parallelize[Table[]] would result in the same (I have stopped trying to figure out how Mathematica deals with things internally; it is quite opaque).
This actually didn't work, shockingly. Agreed, I don't know what is going on under the Mathematica hood.
 

Related Threads on Running a matrix of integrals in parallel

Replies
2
Views
2K
  • Last Post
Replies
1
Views
5K
Replies
1
Views
3K
Replies
5
Views
3K
  • Last Post
Replies
3
Views
5K
  • Last Post
Replies
0
Views
2K
  • Last Post
Replies
2
Views
2K
Replies
5
Views
19K
Replies
1
Views
3K
Replies
3
Views
22K
Top