numerical gradient with extra-large data size
古いコメントを表示
Hi:
I have a 3D coordinate with significantly large size: 1e9*3.
and I have value of parameter at each of these points such as T: 1e9*1.
now I need the gradient of T at each direction, such as dT/dx, dT/dy, dT/dz.
is there anyway to do this?
Thanks!
Li
回答 (1 件)
Walter Roberson
2018 年 1 月 16 日
0 投票
You might be able to take advantage of "tall arrays" https://www.mathworks.com/help/matlab/tall-arrays.html
9 件のコメント
Yu Li
2018 年 1 月 16 日
Walter Roberson
2018 年 1 月 16 日
If you have enough memory for the temporary arrays, then you can just calculate the same way as you would if the data were smaller, by calling gradient() with three outputs. https://www.mathworks.com/help/matlab/ref/gradient.html
Yu Li
2018 年 1 月 16 日
編集済み: Walter Roberson
2018 年 1 月 17 日
Image Analyst
2018 年 1 月 16 日
If you turn the array into a 3-D image you could use convn().
Yu Li
2018 年 1 月 16 日
編集済み: Walter Roberson
2018 年 1 月 17 日
Walter Roberson
2018 年 1 月 17 日
Is it correct that you have a set of scattered points that are not at regular intervals in the coordinates, and you want to calculate the gradient? If so then do you want to calculate the gradient over a grid or only at the existing points?
With scattered points it will be necessary to use an interpolation method. Is (bi-)linear interpolation acceptable or do you need something like spline ?
Yu Li
2018 年 1 月 17 日
編集済み: Walter Roberson
2018 年 1 月 17 日
Walter Roberson
2018 年 1 月 17 日
See https://projecteuclid.org/download/pdf_1/euclid.rmjm/1250127676 for a discussion of algorithms, and http://www.tandfonline.com/doi/pdf/10.1080/02626667409493918 for more information on the one they recommend.
But I wonder what you are headed for?
http://journals.ametsoc.org/doi/abs/10.1175/1520-0493%281994%29122%3C1611%3AUOMIFM%3E2.0.CO%3B2 "Use of Multiquadric Interpolation for Meteorological Objective Analysis "
http://www.worldscientific.com/worldscibooks/10.1142/6437 "Meshfree Approximations in MATLAB"
Yu Li
2018 年 1 月 17 日
編集済み: Walter Roberson
2018 年 1 月 17 日
カテゴリ
ヘルプ センター および File Exchange で Computational Fluid Dynamics (CFD) についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!