How to find double output?
이전 댓글 표시
import java.math.*;
>> p=BigInteger('11');
>> m=BigInteger('2');
>> [A,B]=m.gcd(p);
Error using java.math.BigInteger/gcd
Java methods cannot be called with multiple output arguments
How to resolve this issue? I need both A and B.
Thanking in anticipation
댓글 수: 7
Rik
2022년 3월 2일
What is the second output? There might be a way to compute it separately.
Ammy
2022년 3월 2일
Rik
2022년 3월 2일
Ok, I admit I wasn't clear enough with my question: what is the second output supposed to be in a more general sense? There is only 1 greatest common denominator, so what second value could you extract from it?
I have no experience interfacing with Java (except for copy-paste examples), so I can only help you to try to find a method to calculate the second output another way.
Ammy
2022년 3월 2일
Ammy
2022년 3월 2일
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Logical에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!