need help on equation a*b-c*d(t-1)=1....

6 Ansichten (letzte 30 Tage)
rjnt Kaur
rjnt Kaur am 12 Apr. 2013
hello professionals....i need help on equation a*b-c*d(t-1)=1....where a and c are selected randomly and b , d and t are previously calculated.there shoulb be a loop until the equation become equal to one.thank u
  1 Kommentar
Walter Roberson
Walter Roberson am 12 Apr. 2013
If you are looping, what is going to change in the loop? You would be choosing new random values "a" and "c" ? If so then you could end up with a very long wait indeed.

Melden Sie sich an, um zu kommentieren.

Akzeptierte Antwort

Walter Roberson
Walter Roberson am 12 Apr. 2013
For any given "a", there is exactly one "c" that works:
c = (1 - a*b)/(d*(1-t))
If when you say "selected randomly" you mean that they are to be in the range [0,1] then the condition could only be satisfied when c is between 1/(d*(1-t)) and (1-b)/(d*(1-t)) . Exception: if d = 0, then c can be anything and a = 1/b

Weitere Antworten (0)

Kategorien

Mehr zu Loops and Conditional Statements finden Sie in Help Center und File Exchange

Tags

Noch keine Tags eingegeben.

Community Treasure Hunt

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

Start Hunting!

Translated by