NESSi  v1.0.2
The NonEquilibrium Systems Simulation Library

◆ right_multiply() [1/2]

template<typename T >
void cntr::function< T >::right_multiply ( cplx f,
weight = 1.0 
)

Multiply the function with another matrix-valued function from the right

Purpose

Multiply the function with another matrix-valued function from the right time-pointwisely. The shape of the other matrix-valued function is assumed to be the same as the original function.

Parameters
f

the array storing the matrix-valued function.

weight

the factor that function values are multiplied with in addition to the matrix.

Definition at line 498 of file cntr_function_impl.hpp.

499 {
500  cplx *mytemp, *xtemp, *ftemp;
501  xtemp = new cplx[element_size_];
502  for (int tstp = -1; tstp <= nt_; tstp++) {
503  ftemp = f + (tstp + 1) * element_size_;
504  mytemp = ptr(tstp);
505  element_mult<T, LARGESIZE>(size1_, xtemp,
506  mytemp, ftemp);
507  element_smul<T, LARGESIZE>(size1_, xtemp, weight);
508  element_set<T, LARGESIZE>(size1_, mytemp, xtemp);
509  }
510  delete[] xtemp;
511 }
int size1_
Number of the colums in the Matrix form.
std::complex< T > cplx
int nt_
Maximum number of the time steps.