From: David K. <dkn...@se...> - 2012-02-07 13:53:31
|
In the reduced_basis code, we read in vectors from file using read_serialized_data, in RBEvaluation::read_in_basis_functions. To make this work, at the moment we call read_header in RBEvaluation::read_in_basis_functions, but the way this read_header call is made seems to be wrong, e.g. it breaks when n_vars > 1. It seems to me that read_header is a pretty low-level function, and its purpose is to initialize a new system, rather than to be called on a system that is already initialized? With this in mind, a more robust approach is to remove the call to read_header in RBEvaluation::read_in_basis_functions, and call EquationSystems::read to initialize the equation_systems object prior to calling read_serialized_data. The call to read_serialized_data (on one of the systems in the EquationSystems object) then works fine. But I was wondering if it's possible to call read_serialized_data *without* first calling EquationSystems::read, e.g. calling read_serialized_data on a System that was initialized "manually" in the main function? What is it in EquationSystems::read that preps the System for a call to read_serialized_data? Thanks, David |