I have a process that consists of obtaining a data set by scanning 5 variables L
, w
, d
, k
, and l
using Table
. The script follows,
sa = Table[
If[k == l,
Sin[ w (((10^(-8 + L))^2 + (10^(-6 + L) k - 10^(-6 + L) l )^2)^(
1/2)) ]/((10^(-8 + L))^2 + (10^(-6 + L) k -
10^(-6 + L) l )^2)^2,
Cos[d] Sin[
w (((10^(-8 + L))^2 + (10^(-6 + L) k +
10^(-6 + L) l (Cos[d]))^2 + ((10^(-6 + L) l (Sin[
d])))^2 )^2)]/(((10^(-8 + L))^2 + (10^(-6 + L) k +
10^(-6 + L) l (Cos[d]))^2 + ((10^(-6 + L) l (Sin[
d])))^2 )^2)], {L, 0, 3}, {w, 10, 100, 0.1}, {d, 0,
2 \[Pi], \[Pi]/4}, {k, 1, 200}, {l, 1, 200}];
The time taken to complete this process was about 10 hours on an Intel® Core™ i7-6500U (2.50 GHz) processor, 8GB Single Channel DDR3L 1600MHz (1x8GB) memory, and NVIDIA GeForce 930M 4GB DDR3. I wonder if it is possible to reduce the calculation time using For
or Do
. Thanks in advance