mailr25265 - /trunk/target_functions/exponential.c


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

Header


Content

Posted by edward on August 26, 2014 - 09:31:
Author: bugman
Date: Tue Aug 26 09:31:44 2014
New Revision: 25265

URL: http://svn.gna.org/viewcvs/relax?rev=25265&view=rev
Log:
Fixes for all of the exponential functions in target_functions/exponential.c.

The condition whereby Rx is zero is now setting the value correctly - the 
exponential will be 1, not
zero, hence the intensity and gradient values should not be zero.


Modified:
    trunk/target_functions/exponential.c

Modified: trunk/target_functions/exponential.c
URL: 
http://svn.gna.org/viewcvs/relax/trunk/target_functions/exponential.c?rev=25265&r1=25264&r2=25265&view=diff
==============================================================================
--- trunk/target_functions/exponential.c        (original)
+++ trunk/target_functions/exponential.c        Tue Aug 26 09:31:44 2014
@@ -38,7 +38,7 @@
     for (i = 0; i < num_times; i++) {
         /* Zero Rx value */
         if (params[0] == 0.0)
-            back_calc[i] = 0.0;
+            back_calc[i] = params[1];
 
         /* Back calculate */
         else
@@ -60,7 +60,7 @@
     for (i = 0; i < num_times; i++) {
         /* Zero Rx value */
         if (params[0] == 0.0)
-            back_calc_grad[1][i] = 0.0;
+            back_calc_grad[1][i] = 1.0;
 
         /* The partial derivate */
         else
@@ -82,7 +82,7 @@
     for (i = 0; i < num_times; i++) {
         /* Zero Rx value */
         if (params[0] == 0.0)
-            back_calc_grad[0][i] = 0.0;
+            back_calc_grad[0][i] = -params[1] * relax_times[i];
 
         /* The partial derivate */
         else




Related Messages


Powered by MHonArc, Updated Tue Aug 26 10:40:02 2014