template <int dim>
void FEM<dim>::add_point_source_to_rhs(){
deallog.depth_console (2);
unsigned int no_sources = (mesh->point_source_vector).size();
for(unsigned int s = 0; s < no_sources; ++s){
std::vector<double> load_point = mesh->point_source_vector[s].first;
std::vector<double> load = mesh->point_source_vector[s].second;
Assert (load_point.size() == dim,
ExcDimensionMismatch(load_point.size(), dim));
Assert (load.size() == dim,
ExcDimensionMismatch(load.size(), dim));
//defining the load and the load point
Point<dim> ldp, ld;
for(unsigned int i = 0; i < dim; ++i){
ldp(i) = load_point[i];
ld(i) = load[i];
}
std::cout<<"Checkpoint 1"<<std::endl;
VectorTools::create_point_source_vector(*dof_handler, ldp, ld, system_rhs);
std::cout<<"Checkpoint 2"<<std::endl;
}
}
Are you able to figure out any bug with this information?
Thanks!
Best
Deepak