MATLAB Release Notes - The MathWorks - #401

/ 505


catalogue search
P. 401
P. 402
P. 403
P. 404
P. 405
P. 406
P. 407
P. 408
P. 409
P. 410
P. 411
P. 412
P. 413
P. 414
P. 415
P. 416
P. 417
P. 418
P. 419
P. 420
P. 421
P. 422
P. 423
P. 424
P. 425
P. 426
P. 427
P. 428
P. 429
P. 430
P. 431
P. 432
P. 433
P. 434
P. 435
P. 436
P. 437
P. 438
P. 439
P. 440
P. 441
P. 442
P. 443
P. 444
P. 445
P. 446
P. 447
P. 448
P. 449
P. 450


See other catalogues for The MathWorks

Text version of the page
Mathematics, MATLAB Version 7 (R14)
returns the same value as eps (single(1)) .The value of eps( 'single' ) is thesameas single(2A-23). The command eps(' double') returns the same result as eps.
See "Accuracy of Floating-Point Data" in the online MATLAB documentation for more information.
New Class Inputs for sum
The following new input arguments for sum control how the summation is performed on numeric inputs:
• s = sum(x,'native') and s = sum(x, dim,'native') accumulate in the native type of its input and the output s has the same data type as x.This is the default for single and double.
• s = sum(x,'double') and s = sum(x, dim, 'double') accumulate in double-precision. This is the default for integer data types.
In Version 7.0, sum applied to a vector of type single performs single accumulation and returns a result of type single.In other words, sum(x) is thesameas sum(x, 'native') if x has type single. This is a change in the behavior of sum from previous releases. To make sum accumulate in double, as in previous releases, use the input argument 'double '.
Compatibility Considerations
In Version 7.0, sum applied to a vector of type single performs single accumulation and returns a result oftype single. In previous releases, sum performed this operation in double accumulation.
To restore the previous behavior, call sum with the syntax sum(X, 'double')
or
sum(X, dim, 'double')
377

pageCatalog pdf di En 2012-06-22-01