Quantcast
Channel: MaplePrimes - Questions and Posts tagged with solve
Viewing all articles
Browse latest Browse all 1087

How to extract rhs (right hand side)

$
0
0

Hello all, 

When I tried to extract the RHS of the answer from 'solve()' command, the attempt failed. 


 

restart;

sys := U__s^2 = ((1+sigma)*U__T2N - u__rN * U__T2N/(1+sigma))^2+(u__xN * U__T2N/(1+sigma))^2;

U__s^2 = ((1+sigma)*U__T2N-u__rN*U__T2N/(1+sigma))^2+u__xN^2*U__T2N^2/(1+sigma)^2

(1)

answer := solve( sys, {U__T2N} );

{U__T2N = (1+sigma)*U__s/(sigma^4+4*sigma^3-2*sigma^2*u__rN+6*sigma^2-4*sigma*u__rN+u__rN^2+u__xN^2+4*sigma-2*u__rN+1)^(1/2)}, {U__T2N = -(1+sigma)*U__s/(sigma^4+4*sigma^3-2*sigma^2*u__rN+6*sigma^2-4*sigma*u__rN+u__rN^2+u__xN^2+4*sigma-2*u__rN+1)^(1/2)}

(2)

answer[1];

{U__T2N = (1+sigma)*U__s/(sigma^4+4*sigma^3-2*sigma^2*u__rN+6*sigma^2-4*sigma*u__rN+u__rN^2+u__xN^2+4*sigma-2*u__rN+1)^(1/2)}

(3)

rhs(answer[1]);

Error, invalid input: rhs received {U__T2N = (1+sigma)*U__s/(sigma^4+4*sigma^3-2*sigma^2*u__rN+6*sigma^2-4*sigma*u__rN+u__rN^2+u__xN^2+4*sigma-2*u__rN+1)^(1/2)}, which is not valid for its 1st argument, expr

 

 


Perhaps, the failure might be related to the fact that the equation is contained in curly brackets, but I could not come up with a solution. 

Please let me have a chance to learn the way to do the 'rhs()' operation in the correct way. 

Thank you, 

In Kwon Park 

Download Qprime_20200710.mw


Viewing all articles
Browse latest Browse all 1087

Trending Articles