How does the CONSTPOUT block work?
The CONSTPOUT block uses optimization to servo the input power (starting with the the input power level specified in the schematic) to find the specified output power
That CONSTPOUT stuff sounds simple, so why am I having problems?
There are three common issues that users find with the CONSTPOUT block
- It is important to not sweep input power when using the CONSTPOUT block. The CONSTPOUT block will automatically servo the input power to find the specified output power. Thus, the extra sweep points all have the same answers but cause the simulation to take extra time.
- During the optimization, the input power is limited by the CONSTPOUT block MAX parameter which specifies that the maximum input source scale factor (in W or V depending on the specified source).
- For example, if the input power level specified on the schematic is 0 dBm and MAX=100 then the input power level is limited to 20 dBm when searching for the specified output power (0 dBm → 1 mW, 1 mW * 100 = 100 mW, 100 mW → 20 dBm).
- The second is that the optimization does not find the desired output power before hitting the XDB block MAX_ITER number of iterations
- This can be caused by the optimization getting limited by MAX as discussed above, or, like any optimization, simply not having enough iterations to converge on the specified answer, or, because the specified output power is not achievable.
The good news is that all of these are easy to diagnose by inspecting the simulation output file link in the Status Window
How do I read the CONSTPOUT simulation output file?
First, find the link to the output file in the Status Window (the Output - file link below) and click on it which will open the output file in AWRDE.
Simulation - NLN:CONSTPOUT.AP_HB.$FDOC
1:49:10 PM Begin Simulate
1:49:10 PM Freq - 3 points
1:49:10 PM Netlist - file://C:\My Dropbox\awr\appdata\jomoore\13.0\temp\Curtice_model_gain_expansion\NLN_CONSTPOUT.AP_HB.$FDOC\mwo_aplac_netlist.i
1:49:10 PM Output - file://C:\My Dropbox\awr\appdata\jomoore\13.0\temp\Curtice_model_gain_expansion\NLN_CONSTPOUT.AP_HB.$FDOC\mwo_aplac_output.txt
1:49:11 PM End Simulate (0.50s)
The file shows the specified output power optimization results for each sweep point. The final output power and input power scaling are shown on the last ITER line of each sweep point.
SWPVAL 1, INITIAL SCALE = 1.000
ITER = 1, POUT = 10-18.734648 dBm, SCALE = 8261.446m210
ITER = 2, POUT = 8-17.369181 dBm, SCALE = 6021.469m688 ITER
= 3, POUT = 8.036 dBm, SCALE = 575.930m.
ITER = 410, POUT = 87.001998 dBm, SCALE = 573181.128m185
SWPVAL 2, INITIAL SCALE = 573181.128m185
ITER = 1, POUT = 7.951953 dBm, SCALE = 538170.217m233
ITER = 2, POUT = 7.891895 dBm, SCALE = 533168.780m880
ITER = 3, POUT = 8.000 dBm, SCALE = 541171.831m342
SWPVAL 3, INITIAL SCALE = 541171.831m342
ITER = 1, POUT = 8.259 dBm, SCALE = 528167.107m006
ITER = 2, POUT = 8.005 dBm, SCALE = 509.919m161.251
How do I spot problems in the CONSTPOUT simulation output file?
If the CONSTPOUT block fails to converge one of the likely causes is that the input power scaling is limited. This is easy to see in the simulation output file as the optimizer will get "stuck" trying to raise the scale value higher than allowed by the XDB block MAX parameter value. In the example below MAX=500 and, as can be seen in the data the max gain search "gives up" because of the limit.
FIND MAX GAIN
ITER =1, MAX GAIN = 728.268mdB, DELTA = 256.258mdB, POWER IN =-12.277 dBm, SCALE = 5.919
ITER =2, MAX GAIN = 933.092mdB, DELTA = 461.082mdB, POWER IN =-9.667 dBm, SCALE = 10.798
ITER =47, MAX GAIN = 8.867 dB, DELTA = 8.395 dB, POWER IN = 6.990 dBm, SCALE = 499.999
ITER =48, MAX GAIN = 8.867 dB, DELTA = 8.395 dB, POWER IN = 6.990 dBm, SCALE = 499.999
ITER =49, MAX GAIN = 8.867 dB, DELTA = 8.395 dB, POWER IN = 6.990 dBm, SCALE = 499.999
If the XDB simulation gives warnings about optimization terminated due to maximum number of cycles then it is important to look at the gain compression optimization section of the output file and see if the maximum number of cycles have been reached because the XDB block MAX parameter is limiting the input power scaling or if the optimizer simply needs more iterations to converge (as shown below). The maximum number of iterations is controlled with the XDB block MAX_ITER parameter.
SWPVAL 1, MAX GAIN = 9.031 dB, MINIMUM SCALE = 532.436 , INITIAL SCALE = 1.198k
ITER = 1, GAIN = 6.496 dB, DELTA = 2.535 dB, POWER IN = 10.145 dBm, SCALE = 1.034k
ITER = 2, GAIN = 7.146 dB, DELTA = 1.886 dB, POWER IN = 9.634 dBm, SCALE = 919.261
ITER = 3, GAIN = 8.091 dB, DELTA = 940.462mdB, POWER IN = 8.983 dBm, SCALE = 791.280
ITER = 4, GAIN = 8.158 dB, DELTA = 873.301mdB, POWER IN = 8.938 dBm, SCALE = 783.109
APLAC 9.10 WARNING: MinMax optimization terminated due to
maximum number of cycles (OPT_CYCLES) at sweep point 1 (Freq=2.2 GHz)