I would need to use random function in my equation. How could you make it in ADS? In Excel it's easy for example RANDBETWEEN(1;10). Does anybody know how to make the random generator?
I would need to have 10 different random numbers to be used in my frequency equations. So I need to generate 10 different frequencies, same frequency cannot be used more than once. What would be the way to make that?
One way would be to write boolean equations which could check if a value was equal to one of the other frequencies and then change it slightly.
Something like this:
First randomize 10 frequencies:
F1 = 100 MHz stat { uniform 80 MHz to 120 MHz } F2 = 87 MHz stat { uniform 80 MHz to 120 MHz } . .
Then make sure that all frequencies are unique:
MyFreq1 = if ( (F1 == F2 || F1 == F3 || F1 == F4 || F1 == F5 || F1 == F6 || F1 == F7 || F1 == F8 || F1 == F9 || F1 == F10 ) then F1 + offset1 else F1 endif
Another way to do this is to use a file based method. First you would have to come up with a file with a bunch of random frequency combinations. You can do that using Excel or some other tool. You can write the frequencies into a Discrete MDIF file. First column is the row index 0-N. Then you can add as many columns of data(freqs) as you like. This is a sample file with 10 freqs:
The variable MyIndex controls which row that is read from the file, 0-N. You can randomize that single variable:
VAR MyIndex = 0 stat { discrete 0 to 1000 by 1 }
When you run a Yield or Monte Carlo simulation then the value of MyIndex is randomized. The value of MyIndex is used to control the DataAccessComponent which picks the corresponding row in the file.
You can use the values from the file in parameters/variables like this:
I tried following your example and found a couple problems that other forum readers may also encounter.
First, the Discrete data file must be ended with "end dscrdata". iVar1=1 or "index" to point to the first independent variable. This application note titled "unleashing the DAC" is very helpful for the process https://edasupportweb.soco.agilent.com/ ... Slides.pdf
Thank you Mats for pointing me in the right direction.
Here's a couple of Support Documents which describes two methods of doing this. With and without using Yield analysis:
-Mats