Error using repmat Requested 96761x96761 (69.8GB) array exceeds maximum array size preference (15.8GB). This might cause MATLAB to become unresponsive.
9 views (last 30 days)
Show older comments
load 'X_Coordinates.txt'
load 'Y_Coordinates.txt'
load 'dsp_real.txt'
load 'dsp_imag.txt'
complex_z= complex(dsp_real, dsp_imag);
% disp(complex_z);
Z=complex_z(:,280);
X=meshgrid(X_Coordinates);
Y=meshgrid(Y_Coordinates);
Z=meshgrid(Z);
surf(X,Y,Z)
0 Comments
Answers (1)
Dinesh
on 22 Sep 2023
Hi Sashi Kumar,
I understand that you are attempting to create meshgrids for 'X_Coordinates', 'Y_Coordinates', and 'Z', and then use them to plot a surface plot. However, you are encountering an error stating 'Array exceeds the maximum array size preference.' This error occurs when the requested array is larger than what MATLAB can handle. In this case, the meshgrid operation is internally calling the repmat function, resulting in an array with dimensions of '96761 * 96761', which requires a significant amount of RAM to create.
To resolve this issue, you can divide the problem into smaller subproblems to avoid running into memory limitations. By breaking down the task into manageable chunks, you can overcome this problem.
For more detailed information on how to divide the problem into subproblems and explore alternative approaches to tackle this issue, I recommend referring to the following MATLAB Answers thread:
If you are still experiencing issues it would be helpful to have more details about the data you are working with
Hope this helps.
Best Regards,
Dinesh Reddy Gatla.
0 Comments
See Also
Categories
Find more on Matrix Indexing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!