NESSi  v1.0.2
The NonEquilibrium Systems Simulation Library

◆ Recv_timestep()

template<typename T >
void cntr::herm_matrix_timestep_view< T >::Recv_timestep ( int  tstp,
int  root,
int  tag 
)

Recevies the herm_matrix_timestep_view at a given time step from a specific task.

Purpose

Receives the herm_matrix_timestep_view at a given time step tstp from a specific task with rank root.

Parameters
tstp

Time step which should be received.

root

The task rank from which the herm_matrix should be received.

tag

The MPI error flag.

Definition at line 1805 of file cntr_herm_matrix_timestep_view_impl.hpp.

1805  {
1806  int taskid;
1807  MPI_Comm_rank(MPI_COMM_WORLD, &taskid);
1808  assert(tstp == tstp_);
1809  if (!(taskid == root)) {
1810  if (sizeof(T) == sizeof(double))
1811  if (tstp_ == -1){
1812  MPI_Recv(mat_, (ntau_ + 1) * element_size_, MPI_DOUBLE_COMPLEX, root, tag, MPI_COMM_WORLD);
1813  } else {
1814  MPI_Recv(les_, (tstp_ + 1) * element_size_, MPI_DOUBLE_COMPLEX, root, tag, MPI_COMM_WORLD);
1815  MPI_Recv(ret_, (tstp_ + 1) * element_size_, MPI_DOUBLE_COMPLEX, root, tag, MPI_COMM_WORLD);
1816  MPI_Recv(tv_, (ntau_ + 1) * element_size_, MPI_DOUBLE_COMPLEX, root, tag, MPI_COMM_WORLD);
1817  }
1818  else{
1819  if (tstp_ == -1){
1820  MPI_Recv(mat_, (ntau_ + 1) * element_size_, MPI_COMPLEX, root, tag, MPI_COMM_WORLD);
1821  } else {
1822  MPI_Recv(les_, (tstp_ + 1) * element_size_, MPI_COMPLEX, root, tag, MPI_COMM_WORLD);
1823  MPI_Recv(ret_, (tstp_ + 1) * element_size_, MPI_COMPLEX, root, tag, MPI_COMM_WORLD);
1824  MPI_Recv(tv_, (ntau_ + 1) * element_size_, MPI_COMPLEX, root, tag, MPI_COMM_WORLD);
1825  }
1826  }
1827  }
1828 }