Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: MATLAB vpa() doesn't compute variable-point number for expression with exponent?
Replies: 2   Last Post: Jul 1, 2013 10:34 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
Anon.

Posts: 6
Registered: 12/6/04
MATLAB vpa() doesn't compute variable-point number for expression with exponent?
Posted: Jan 15, 2013 5:38 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Trying to use vpa() to compute a variable point number for a rational expression in an exponent:

syms x;
ans1 = x^(12345/67890)
ans2 = vpa(x^(12345/67890),3)
ans2_5 = vpa((12345/67890),3)
ans3 = vpa(x*(12345/67890),3)

The above shows the issue. ans1 shows the default output of the expression. ans2 shows that vpa() is not computing the variable point number for the expression. ans 2_5 shows what it should be computing to. The result I'm looking for is x^0.182.

ans3 just shows that vpa() produces the expected result when the function is multiplication--it's something in the exponent that's tripping it up.

How can I request that the exponent be evaluated by vpa?



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.