NESSi  v1.0.2
The NonEquilibrium Systems Simulation Library

◆ set_value() [1/2]

template<typename T >
template<class EigenMatrix >
void cntr::function< T >::set_value ( int  tstp,
EigenMatrix &  M 
)

Set matrix value at a specific time point

Purpose

Set matrix value at a specific time point

Parameters
tstp

the time step to be set

M

the new matrix value of function at time step tstp as an EigenMatrix.

Definition at line 383 of file cntr_function_impl.hpp.

Referenced by cntr::propagator_exp(), cntr::vie2_timestep_sin(), and cntr::vie2_timestep_sin_omp().

383  {
384  int i1, i2;
385  cplx *ft;
386  assert(M.rows() == size1_);
387  assert(M.cols() == size2_);
388 
389  ft = ptr(tstp);
390  for (i1 = 0; i1 < size1_; i1++)
391  for (i2 = 0; i2 < size2_; i2++)
392  ft[i1 * size2_ + i2] = M(i1, i2);
393 }
int size2_
Number of the rows in the Matrix form.
int size1_
Number of the colums in the Matrix form.
std::complex< T > cplx
+ Here is the caller graph for this function: