gpt4 book ai didi

wolfram-mathematica - 在 Mathematica 中处理大数据

转载 作者:行者123 更新时间:2023-12-04 08:06:22 24 4
gpt4 key购买 nike

我正在使用 Mathematica 处理大型输入数组,看起来我无法处理任何大于(或等于)1024*1024 和 81*81*81 的数组。那是正常的吗?我应该能够对此类输入数据进行计算吗?如果是,怎么办?

最佳答案

我认为这取决于您进行的计算

例如,在一台非常普通的笔记本电脑中:

Clear["Global`*"];
k = 2000;
Timing[a = Table[i j + i - j, {i, k}, {j, k}];
MatrixPlot@a]

需要 20 秒。

矩阵相乘到 1000x1000:

f[n_] := Table[RandomInteger[{1, n}], {n}, {n}];
ListLinePlot[
Table[{n, First@AbsoluteTiming@(#.#) &@f[n]}, {n, 100, 1000, 100}]]

enter image description here

因此,这在很大程度上取决于您要计算的内容。

关于wolfram-mathematica - 在 Mathematica 中处理大数据,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5124375/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com