W dniu wtorek, 25 września 2018 15:30:06 UTC+2 użytkownik Wolfgang Bangerth napisał: > > On 09/25/2018 05:56 AM, Michał Wichrowski wrote: > > > > Yep, I am trying to copy Multigrid object on purpose, I found the line > > corresponding to the problem: > > Line 762: > > std::vector<Multigrid<LevelVectorType > > > > multigrids_sc(triangulation.n_global_levels(), > > mg_sc); > > > > I need a vector of objects of type Multigrid, how can I fix this? > > Do you actually need to copy the Multigrid objects, or do you just want to > store them in a vector? (std::vector of course requires its objects to be > copiable.) > > If you don't actually need copies, then just use a > std::vector<std::unique_ptr<Multigrid>>. > > Best > W. >
Yes, I need triangulation.n_global_levels() copies of multigrid. I modify each of them in next line: std::vector<Multigrid<LevelVectorType > > multigrids_sc(triangulation.n_global_levels(), mg_sc); for (unsigned int level = 0; level<triangulation.n_global_levels(); ++level) multigrids_sc[level].reinit(0, level); -- The deal.II project is located at http://www.dealii.org/ For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en --- You received this message because you are subscribed to the Google Groups "deal.II User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
