필터 지우기
필터 지우기

Solving system of 2 equations

조회 수: 1 (최근 30일)
NMK
NMK 2017년 2월 8일
편집: John D'Errico 2017년 2월 8일
Hi,
I am trying to solve a system of two equations which looks like this:
R1 = Gy*(r+lam)*(rU1)+lam*((integral((1-Gx),R1,yl))-(1-Gy)*yl);
yl = rU1-(lam/((r+lam)*Gy))*(integral((Gy-Gx),R1,yl));
where rU1, lam, r are parameter values.
Gy and Gx are uniform distributions over [0,1]
I try to solve them like this:
syms R1 yl
eqn1 = R1 == Gy*(r+lam)*(rU1)+lam*((integral((1-Gx),R1,yl))-(1-Gy)*yl);
eqn2 = yl == rU1-(lam/((r+lam)*Gy))*(integral((Gy-Gx),R1,yl));
sol = solve([eqn1, eqn2], [R1, yl]); R1Sol = sol.R1; ylSol = sol.yl;
But I get an error: Undefined function 'mtimes' for input arguments of type 'prob.UniformDistribution'.
Can someone help solving the error?
Thanks,

답변 (1개)

John D'Errico
John D'Errico 2017년 2월 8일
편집: John D'Errico 2017년 2월 8일
Gy and Gx are distributions. What does it mean to take the product of Gy with some expression, and then try to equate that to a number? (In terms of mathematics: Nothing.) There are other points of confusion in what you have written.
So this is not an error that can be simply solved by us, only by you, in deciding what you meant by those equations. Once you are able to write down a valid expression in terms of mathematics, only then can you formulate a solution in MATLAB.

카테고리

Help CenterFile Exchange에서 Calculus에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by