| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Symbolic Math Toolbox |
| Contents | Index |
| Learn more about Symbolic Math Toolbox |
r = double(S)
r = double(S) converts the symbolic object S to a numeric object. If S is a symbolic constant or constant expression, double returns a double-precision floating-point number representing the value of S. If S is a symbolic matrix whose entries are constants or constant expressions, double returns a matrix of double precision floating-point numbers representing the values of S's entries.
Find the numeric value for the expression
:
double(sym('(1+sqrt(5))/2')))The result is:
1.6180
The following statements
a = sym(2*sqrt(2)); b = sym((1-sqrt(3))^2); T = [a, b]; double(T)
return
ans =
2.8284 0.5359![]() | doc (mupadengine) | dsolve (sym) | ![]() |

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |