Package maths_fns :: Module jw_mf_comps
[hide private]
[frames] | no frames]

Module jw_mf_comps

source code

Functions [hide private]
 
calc_S2_te_jw_comps(data, params)
Spectral density component function.
source code
 
calc_S2f_S2_ts_jw_comps(data, params)
Spectral density component function.
source code
 
calc_S2f_S2s_ts_jw_comps(data, params)
Spectral density component function.
source code
 
calc_S2f_tf_S2_ts_jw_comps(data, params)
Spectral density component function.
source code
 
calc_S2f_tf_S2s_ts_jw_comps(data, params)
Spectral density component function.
source code
 
calc_diff_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_S2_te_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_diff_S2_te_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_S2f_S2_ts_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_diff_S2f_S2_ts_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_S2f_tf_S2_ts_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_diff_S2f_tf_S2_ts_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_S2f_S2s_ts_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_diff_S2f_S2s_ts_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_S2f_tf_S2s_ts_djw_comps(data, params)
Spectral density gradient component function.
source code
 
calc_diff_S2f_tf_S2s_ts_djw_comps(data, params)
Spectral density gradient component function.
source code
Variables [hide private]
  __package__ = None
hash(x)
Function Details [hide private]

calc_S2_te_jw_comps(data, params)

source code 

Spectral density component function.

Calculate the components of the spectral density value for the original model-free formula with the parameters {S2, te}.

The model-free formula is:

               _n_
            2  \           /      S2             (1 - S2)(te + ti)te    \ 
   J(w)  =  -   >  ci . ti | ------------  +  ------------------------- |.
            5  /__         \ 1 + (w.ti)^2     (te + ti)^2 + (w.te.ti)^2 /
               i=m

Replicated calculations are:

   w_ti_sqrd = (w.ti)^2        (pre-calculated during initialisation),

   te_ti = te + ti,
   te_ti_te = (te + ti).te.

Calculations which are replicated in the gradient equations are:

   fact_ti = 1 / (1 + (w.ti)^2)    (pre-calculated during initialisation),

   one_s2 = 1 - S2,

   te_ti_sqrd = (te + ti)^2,
   w_te_ti_sqrd = (w.te.ti)^2,

                      (te + ti)te
   fact_te  =  -------------------------.
               (te + ti)^2 + (w.te.ti)^2

calc_S2f_S2_ts_jw_comps(data, params)

source code 

Spectral density component function.

Calculate the components of the spectral density value for the extended model-free formula with the parameters {S2f, S2, ts}.

The model-free formula is:

               _n_
            2  \           /      S2            (S2f - S2)(ts + ti)ts   \ 
   J(w)  =  -   >  ci . ti | ------------  +  ------------------------- |.
            5  /__         \ 1 + (w.ti)^2     (ts + ti)^2 + (w.ts.ti)^2 /
               i=m

Replicated calculations are:

   w_ti_sqrd = (w.ti)^2        (pre-calculated during initialisation),

   ts_ti = ts + ti,
   ts_ti_ts = (ts + ti).ts.

Calculations which are replicated in the gradient equations are:

   fact_ti = 1 / (1 + (w.ti)^2)    (pre-calculated during initialisation),

   s2f_s2 = S2f - S2,

   ts_ti_sqrd = (ts + ti)^2,
   w_ts_ti_sqrd = (w.ts.ti)^2,
   inv_ts_denom = 1 / ((ts + ti)^2 + (w.ts.ti)^2),

                      (ts + ti)ts
   fact_ts  =  -------------------------.
               (ts + ti)^2 + (w.ts.ti)^2

calc_S2f_S2s_ts_jw_comps(data, params)

source code 

Spectral density component function.

Calculate the components of the spectral density value for the extended model-free formula with the parameters {S2f, S2s, ts}.

The model-free formula is:

                  _n_
            2     \           /      S2s           (1 - S2s)(ts + ti)ts    \ 
   J(w)  =  - S2f  >  ci . ti | ------------  +  ------------------------- |.
            5     /__         \ 1 + (w.ti)^2     (ts + ti)^2 + (w.ts.ti)^2 /
                  i=m

Replicated calculations are:

   w_ti_sqrd = (w.ti)^2        (pre-calculated during initialisation),

   ts_ti = ts + ti,
   ts_ti_ts = (ts + ti).ts.

Calculations which are replicated in the gradient equations are:

   fact_ti = 1 / (1 + (w.ti)^2)    (pre-calculated during initialisation),

   one_s2s = 1 - S2s,

   ts_ti_sqrd = (ts + ti)^2,
   w_ts_ti_sqrd = (w.ts.ti)^2,
   inv_ts_denom = 1 / ((ts + ti)^2 + (w.ts.ti)^2),

                      (ts + ti)ts
   fact_ts  =  -------------------------.
               (ts + ti)^2 + (w.ts.ti)^2

calc_S2f_tf_S2_ts_jw_comps(data, params)

source code 

Spectral density component function.

Calculate the components of the spectral density value for the extended model-free formula with the parameters {S2f, tf, S2, ts}.

The model-free formula is:

               _n_
            2  \           /      S2            (1 - S2f)(tf + ti)tf
   J(w)  =  -   >  ci . ti | ------------  +  -------------------------
            5  /__         \ 1 + (w.ti)^2     (tf + ti)^2 + (w.tf.ti)^2
               i=m

                                                (S2f - S2)(ts + ti)ts   \ 
                                           +  ------------------------- |.
                                              (ts + ti)^2 + (w.ts.ti)^2 /

Replicated calculations are:

   w_ti_sqrd = (w.ti)^2        (pre-calculated during initialisation),

   tf_ti = tf + ti,
   ts_ti = ts + ti,
   tf_ti_tf = (tf + ti).tf,
   ts_ti_ts = (ts + ti).ts.

Calculations which are replicated in the gradient equations are:

   fact_ti = 1 / (1 + (w.ti)^2)    (pre-calculated during initialisation),

   one_s2f = 1 - S2f,
   s2f_s2 = S2f - S2,

   tf_ti_sqrd = (tf + ti)^2,
   ts_ti_sqrd = (ts + ti)^2,
   w_tf_ti_sqrd = (w.tf.ti)^2,
   w_ts_ti_sqrd = (w.ts.ti)^2,
   inv_tf_denom = 1 / ((tf + ti)^2 + (w.tf.ti)^2),
   inv_ts_denom = 1 / ((ts + ti)^2 + (w.ts.ti)^2),

                      (tf + ti)tf
   fact_tf  =  -------------------------,
               (tf + ti)^2 + (w.tf.ti)^2


                      (ts + ti)ts
   fact_ts  =  -------------------------.
               (ts + ti)^2 + (w.ts.ti)^2

calc_S2f_tf_S2s_ts_jw_comps(data, params)

source code 

Spectral density component function.

Calculate the components of the spectral density value for the extended model-free formula with the parameters {S2f, tf, S2s, ts}.

The model-free formula is:

               _n_
            2  \           /   S2f . S2s        (1 - S2f)(tf + ti)tf
   J(w)  =  -   >  ci . ti | ------------  +  -------------------------
            5  /__         \ 1 + (w.ti)^2     (tf + ti)^2 + (w.tf.ti)^2
               i=m

                                               S2f(1 - S2s)(ts + ti)ts  \ 
                                           +  ------------------------- |.
                                              (ts + ti)^2 + (w.ts.ti)^2 /

Replicated calculations are:

   w_ti_sqrd = (w.ti)^2        (pre-calculated during initialisation),

   tf_ti = tf + ti,
   ts_ti = ts + ti,
   tf_ti_tf = (tf + ti).tf,
   ts_ti_ts = (ts + ti).ts.

Calculations which are replicated in the gradient equations are:

   fact_ti = 1 / (1 + (w.ti)^2)    (pre-calculated during initialisation),

   one_s2s = 1 - S2s,
   one_s2f = 1 - S2f,
   s2f_s2 = S2f(1 - S2s) = S2f - S2,

   tf_ti_sqrd = (tf + ti)^2,
   ts_ti_sqrd = (ts + ti)^2,
   w_tf_ti_sqrd = (w.tf.ti)^2,
   w_ts_ti_sqrd = (w.ts.ti)^2,
   inv_tf_denom = 1 / ((tf + ti)^2 + (w.tf.ti)^2),
   inv_ts_denom = 1 / ((ts + ti)^2 + (w.ts.ti)^2),

                      (tf + ti)tf
   fact_tf  =  -------------------------,
               (tf + ti)^2 + (w.tf.ti)^2


                      (ts + ti)ts
   fact_ts  =  -------------------------.
               (ts + ti)^2 + (w.ts.ti)^2

calc_diff_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the original model-free formula with no parameters {} or the parameter {S2} together with diffusion tensor parameters.

Replicated calculations are:

                         1 - (w.ti)^2
   fact_ti_djw_dti  =  ----------------.
                       (1 + (w.ti)^2)^2

calc_S2_te_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the original model-free formula with the parameters {S2, te}.

Replicated calculations are:

                           (te + ti)^2 - (w.te.ti)^2
   fact_djw_dte  =  ti^2 -----------------------------.
                         ((te + ti)^2 + (w.te.ti)^2)^2

calc_diff_S2_te_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the original model-free formula with the parameters {S2, te} together with diffusion tensor parameters.

Replicated calculations are:

                         1 - (w.ti)^2
   fact_ti_djw_dti  =  ----------------,
                       (1 + (w.ti)^2)^2


                  (te + ti)^2 - (w.te.ti)^2
   fact_djw  =  -----------------------------,
                ((te + ti)^2 + (w.te.ti)^2)^2


                              (te + ti)^2 - (w.te.ti)^2
   fact_te_djw_dti  =  te^2 -----------------------------,
                            ((te + ti)^2 + (w.te.ti)^2)^2


                           (te + ti)^2 - (w.te.ti)^2
   fact_djw_dte  =  ti^2 -----------------------------.
                         ((te + ti)^2 + (w.te.ti)^2)^2

calc_S2f_S2_ts_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the extended model-free formula with the parameters {S2f, S2, ts}.

Replicated calculations are:

                           (ts + ti)^2 - (w.ts.ti)^2
   fact_djw_dts  =  ti^2 -----------------------------.
                         ((ts + ti)^2 + (w.ts.ti)^2)^2

calc_diff_S2f_S2_ts_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the extended model-free formula with the parameters {S2f, S2, ts} together with diffusion tensor parameters.

Replicated calculations are:

                         1 - (w.ti)^2
   fact_ti_djw_dti  =  ----------------,
                       (1 + (w.ti)^2)^2


                  (ts + ti)^2 - (w.ts.ti)^2
   fact_djw  =  -----------------------------,
                ((ts + ti)^2 + (w.ts.ti)^2)^2


                              (ts + ti)^2 - (w.ts.ti)^2
   fact_ts_djw_dti  =  ts^2 -----------------------------,
                            ((ts + ti)^2 + (w.ts.ti)^2)^2


                           (ts + ti)^2 - (w.ts.ti)^2
   fact_djw_dts  =  ti^2 -----------------------------.
                         ((ts + ti)^2 + (w.ts.ti)^2)^2

calc_S2f_tf_S2_ts_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the extended model-free formula with the parameters {S2f, tf, S2, ts}.

Replicated calculations are:

                           (tf + ti)^2 - (w.tf.ti)^2
   fact_djw_dtf  =  ti^2 -----------------------------,
                         ((tf + ti)^2 + (w.tf.ti)^2)^2


                           (ts + ti)^2 - (w.ts.ti)^2
   fact_djw_dts  =  ti^2 -----------------------------.
                         ((ts + ti)^2 + (w.ts.ti)^2)^2

calc_diff_S2f_tf_S2_ts_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the extended model-free formula with the parameters {S2f, tf, S2, ts} together with diffusion tensor parameters.

Replicated calculations are:

                         1 - (w.ti)^2
   fact_ti_djw_dti  =  ----------------,
                       (1 + (w.ti)^2)^2


                     (tf + ti)^2 - (w.tf.ti)^2
   fact_tf_djw  =  -----------------------------,
                   ((tf + ti)^2 + (w.tf.ti)^2)^2


                     (ts + ti)^2 - (w.ts.ti)^2
   fact_ts_djw  =  -----------------------------,
                   ((ts + ti)^2 + (w.ts.ti)^2)^2


                              (tf + ti)^2 - (w.tf.ti)^2
   fact_tf_djw_dti  =  tf^2 -----------------------------,
                            ((tf + ti)^2 + (w.tf.ti)^2)^2


                              (ts + ti)^2 - (w.ts.ti)^2
   fact_ts_djw_dti  =  ts^2 -----------------------------,
                            ((ts + ti)^2 + (w.ts.ti)^2)^2


                           (tf + ti)^2 - (w.tf.ti)^2
   fact_djw_dtf  =  ti^2 -----------------------------,
                         ((tf + ti)^2 + (w.tf.ti)^2)^2


                           (ts + ti)^2 - (w.ts.ti)^2
   fact_djw_dts  =  ti^2 -----------------------------.
                         ((ts + ti)^2 + (w.ts.ti)^2)^2

calc_S2f_S2s_ts_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the extended model-free formula with the parameters {S2f, S2s, ts}.

Replicated calculations are:

                           (ts + ti)^2 - (w.ts.ti)^2
   fact_djw_dts  =  ti^2 -----------------------------.
                         ((ts + ti)^2 + (w.ts.ti)^2)^2

calc_diff_S2f_S2s_ts_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the extended model-free formula with the parameters {S2f, S2s, ts} together with diffusion tensor parameters.

Replicated calculations are:

                         1 - (w.ti)^2
   fact_ti_djw_dti  =  ----------------,
                       (1 + (w.ti)^2)^2


                  (ts + ti)^2 - (w.ts.ti)^2
   fact_djw  =  -----------------------------,
                ((ts + ti)^2 + (w.ts.ti)^2)^2


                              (ts + ti)^2 - (w.ts.ti)^2
   fact_ts_djw_dti  =  ts^2 -----------------------------,
                            ((ts + ti)^2 + (w.ts.ti)^2)^2


                           (ts + ti)^2 - (w.ts.ti)^2
   fact_djw_dts  =  ti^2 -----------------------------.
                         ((ts + ti)^2 + (w.ts.ti)^2)^2

calc_S2f_tf_S2s_ts_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the extended model-free formula with the parameters {S2f, tf, S2s, ts}.

Replicated calculations are:

                           (tf + ti)^2 - (w.tf.ti)^2
   fact_djw_dtf  =  ti^2 -----------------------------,
                         ((tf + ti)^2 + (w.tf.ti)^2)^2


                           (ts + ti)^2 - (w.ts.ti)^2
   fact_djw_dts  =  ti^2 -----------------------------.
                         ((ts + ti)^2 + (w.ts.ti)^2)^2

calc_diff_S2f_tf_S2s_ts_djw_comps(data, params)

source code 

Spectral density gradient component function.

Calculate the components of the spectral density gradient for the extended model-free formula with the parameters {S2f, tf, S2, ts} together with diffusion tensor parameters.

Replicated calculations are:

                         1 - (w.ti)^2
   fact_ti_djw_dti  =  ----------------,
                       (1 + (w.ti)^2)^2


                     (tf + ti)^2 - (w.tf.ti)^2
   fact_tf_djw  =  -----------------------------,
                   ((tf + ti)^2 + (w.tf.ti)^2)^2


                     (ts + ti)^2 - (w.ts.ti)^2
   fact_ts_djw  =  -----------------------------,
                   ((ts + ti)^2 + (w.ts.ti)^2)^2


                              (tf + ti)^2 - (w.tf.ti)^2
   fact_tf_djw_dti  =  tf^2 -----------------------------,
                            ((tf + ti)^2 + (w.tf.ti)^2)^2


                              (ts + ti)^2 - (w.ts.ti)^2
   fact_ts_djw_dti  =  ts^2 -----------------------------,
                            ((ts + ti)^2 + (w.ts.ti)^2)^2


                           (tf + ti)^2 - (w.tf.ti)^2
   fact_djw_dtf  =  ti^2 -----------------------------,
                         ((tf + ti)^2 + (w.tf.ti)^2)^2


                           (ts + ti)^2 - (w.ts.ti)^2
   fact_djw_dts  =  ti^2 -----------------------------.
                         ((ts + ti)^2 + (w.ts.ti)^2)^2