필터 지우기
필터 지우기

Solving equation with one variable but it is present in the equation twice

조회 수: 3 (최근 30일)
Hello,
I can solve equation using pen and paper but I have set of data where i have to apply that equation but the probblem is that the unknow vairable in the equation is presnet twice and i dont know how to do it in matlab, here is the equation in picture,
Now Vout is known and it is the set of data which needs to be converted in to resistance, as you can see this is a wheatstone bridge equation. I would like to find x, i can do it manually on paper but don't know how to do it on matlab.
Thank you fo the help in advance

채택된 답변

Torsten
Torsten 2022년 11월 17일
syms x Vout
eqn = Vout == (0.5 - x/(x+1000))*3.3*128;
x = solve(eqn,x)
x = 
x = matlabFunction(x)
x = function_handle with value:
@(Vout)-(Vout.*5.0e+3-1.056e+6)./(Vout.*5.0+1.056e+3)
x(100)
ans = 357.3265

추가 답변 (1개)

David Hill
David Hill 2022년 11월 17일
It is easy to just solve for x in your equation and have an equation in Vout.
f=@(Vout)(211200-1000*Vout)./(Vout+211.2);
f(100)
ans = 357.3265
  댓글 수: 3
Hiril Patel
Hiril Patel 2022년 11월 17일
Got the value that i needed, but still cannot understand how did you got this:
f=@(Vout)(211200-1000*Vout)./(Vout+211.2);
looking for information to understand
Thank you you solved my problem
Torsten
Torsten 2022년 11월 17일
You wrote you could solve the equation for x using pencil and paper. Then do it - this is the result you will get:
x = (211200-1000*Vout)./(Vout+211.2)

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by