MATLAB Answers

Represent the result of matrices manipulation as rational numbers

4 views (last 30 days)
Hi everyone
I need to represent my resultant matrix with rational number rather than decimal point.
for example I have matrix A = [ 1/2 1/3 ; 4 5/6]
B = [ 2 1/4 ; 4 1 ]
C = A+B
how to get C as [ 5/2 7/12 ; 8 11/6]

  0 Comments

Sign in to comment.

Accepted Answer

JESUS DAVID ARIZA ROYETH
JESUS DAVID ARIZA ROYETH on 6 Dec 2019
format rat
A = [ 1/2 1/3 ; 4 5/6]
B = [ 2 1/4 ; 4 1 ]
C = A+B

  0 Comments

Sign in to comment.

More Answers (0)

Sign in to answer this question.

Tags