mailr19991 - /branches/relax_disp/specific_analyses/relax_disp/parameters.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on June 09, 2013 - 15:32:
Author: bugman
Date: Sun Jun  9 15:32:51 2013
New Revision: 19991

URL: http://svn.gna.org/viewcvs/relax?rev=19991&view=rev
Log:
Updates for the pA dispersion parameter optimisation constraints.

The parameter is now limited to be between pB and 1.  In the case of the 
limit pA >> pB, then
instead the constraint is between 0.85 and 1.


Modified:
    branches/relax_disp/specific_analyses/relax_disp/parameters.py

Modified: branches/relax_disp/specific_analyses/relax_disp/parameters.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/specific_analyses/relax_disp/parameters.py?rev=19991&r1=19990&r2=19991&view=diff
==============================================================================
--- branches/relax_disp/specific_analyses/relax_disp/parameters.py (original)
+++ branches/relax_disp/specific_analyses/relax_disp/parameters.py Sun Jun  9 
15:32:51 2013
@@ -251,8 +251,7 @@
         R2 >= 0
         R2 <= -200
         R2A >= 0
-        pA >= 0
-        pA >= pB
+        pB <= pA <= 1
         pA >= 0.85 (the skewed condition, pA >> pB)
         phi_ex >= 0
         dw >= 0
@@ -271,10 +270,10 @@
         |         |     |        |      |         |
         | 1  0  0 |     |  R2A   |      |    0    |
         |         |     |        |      |         |
-        | 1  0  0 |     |   pA   |      |    0    |
-        |         |     |        |      |         |
-        | 1  0  0 |  .  |   pA   |  >=  |   0.5   |
-        |         |     |        |      |         |
+        | 1  0  0 |     |   pA   |      |   0.5   |
+        |         |     |        |      |         |
+        |-1  0  0 |     |   pA   |      |   -1    |
+        |         |  .  |        |  >=  |         |
         | 1  0  0 |     |   pA   |      |   0.85  |
         |         |     |        |      |         |
         | 1  0  0 |     | phi_ex |      |    0    |
@@ -352,21 +351,26 @@
             b.append(-200.0 / scaling_matrix[param_index, param_index])
             j += 2
 
-        # The population of state A (pA >= 0 and pA >= pB).
+        # The population of state A.
         elif param_name == 'pA':
-            A.append(zero_array * 0.0)
-            A.append(zero_array * 0.0)
-            A[j][param_index] = 1.0
-            A[j+1][param_index] = 1.0
-            b.append(0.0)
-            b.append(0.5 / scaling_matrix[param_index, param_index])
-            j += 2
+            # First the pA <= 1 constraint
+            A.append(zero_array * 0.0)
+            A[j][param_index] = -1.0
+            b.append(-1.0 / scaling_matrix[param_index, param_index])
+            j += 1
 
             # The skewed condition (pA >> pB).
             if spins[0].model == MODEL_M61B:
                 A.append(zero_array * 0.0)
                 A[j][param_index] = 1.0
                 b.append(0.85 / scaling_matrix[param_index, param_index])
+                j += 1
+
+            # Otherwise use the pA >= pB constraint.
+            else:
+                A.append(zero_array * 0.0)
+                A[j][param_index] = 1.0
+                b.append(0.5 / scaling_matrix[param_index, param_index])
                 j += 1
 
         # Exchange rates (k >= 0).




Related Messages


Powered by MHonArc, Updated Sun Jun 09 15:40:02 2013