필터 지우기
필터 지우기

how to solve system of two non linear equations? (power law)

조회 수: 2 (최근 30일)
Faisal
Faisal 2023년 5월 30일
댓글: Faisal 2023년 5월 30일
I have two equation related to power law equation solution.
  1. I have two points, and I want to find the power "b" in power law equation Y = ax^b. the points are x,y = (0.0226336, 24.988) & (0.0180306, 0.179498)
  2. I have one point and the power b. point x,y = (0.0226336, 24.988) and power b = 2. Now I want to plot the equation using point and power b.

채택된 답변

Shaik mohammed ghouse basha
Shaik mohammed ghouse basha 2023년 5월 30일
편집: Shaik mohammed ghouse basha 2023년 5월 30일
Hello,
As per my understanding of your question, you have an equation of form . In first part with given two points on curve you want to find the variable b. In second part with a point and value of b you want to plot the curve.
Part I:
Given two points on curve as (0.0226336, 24.988) & (0.0180306, 0.179498).
Let points be
As both points satisfy the power law equation we can write:
dividing both these quations you get:
Take log on both sides of this equation you get:
y1 = 24.988;
y2 = 0.179498;
x1 = 0.0226336;
x2 = 0.0180306;
b = log(y1/y2) / log(x1/x2);
disp(b);
21.7095
Part II:
To plot the equation we need to find the value of a.
As given point satisfy the equation we can use this to find a.
y1 = 24.988;
x1 = 0.0226336;
b = 2;
a = y1/x1.^b;
x = -10:0.01:10;
%x goes from -10 to 10 with an increment of 0.01
y = a*x.^b;
plot(x, y)

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Fuzzy Logic Toolbox에 대해 자세히 알아보기

제품


릴리스

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by