Refactoring field collections, FFT engines and solvers
Changes were made to:
- FFT engines: they are no longer templated by material dimension, but rather by the number of components. This makes it now possible to exploit strain symmetry to reduce cost of fft (not yet implemented)
- Projections: to handle the new FFT engine API
- Fields: TypedFields (i.e., fields for which the number of components is dynamic, *not* a template parameter) are no longer abstract. They can now be constructed and statically sized FieldMaps can be created from them.
- Raw field iterators: arbitrary chunks of memory can now be iterated over as if they were a field map.
- FieldProxies: TypeFields can now be in either normal or proxy mode. In proxy mode, they wrap themselves on existing memory. This convenient feature makes it possible for input arrays (e.g., from numpy arrays) to be used as Fields and used as input for methods of the Cell classes for evaluating stresses, stiffnesses etc.
- Cell: A non-templated root class from which all CellBase classes inherit has been created. This class has an entirely virtual interface, and can therefore be used by non-templated solvers (such as the new solvers and SolverBase descendants, or scipy solvers)
- solvers and descendants of SolverBase: The solution algorithms (newton_cg and de_geus) are no longer templated, greatly simplifying their writing. Also, the iterative solvers for the linear system are no longer templated neither.
This closes T1851.
Warning: this introduced many changes. Reviewers, please make sure none of functionalities you rely upn is broken by this. (And if so, please add tests to make this evident).
Test Plan: tests pass on the CI
Reviewers: pastewka, afalsafi
Reviewed By: pastewka
Subscribers: rrezakha, gallyamov, maresca, RLeute
Maniphest Tasks: T1851
Differential Revision: https://c4science.ch/D186