% NaN returns the IEEE arithmetic representation for Not-a-Number (NaN).
% These result from operations which have undefined numerical results.
% NaN('double') is the same as NaN with no inputs.
% NaN('single') is the single precision representation of NaN.
% NaN(n) is an n-by-n matrix of NaNs.
% NaN(m,n) or NaN([m,n]) is an m-by-n matrix of NaNs.
% NaN(m,n,p,...) or NaN([m,n,p,...]) is an m-by-n-by-p-by-... array of NaNs.
% æ¹æ³ä¸ å°éæ°ç½®æ¢ä¸ºç©ºï¼å é¤ï¼ï¼å¯¹ç»´æ°æå½±å
A = [1 2 nan 4 7 nan];A =
1 2 4 7
% æ¹æ³äº å°éæ°ç¨å¸¸éæ¿ä»£ï¼å¯¹ç»´æ°ä¸å½±å
B = [1 2 nan; 4 nan 5; 7 8 9]B =
1 2 NaN
4 NaN 5
7 8 9
B =
1 2 0
4 0 5
7 8 9