Closed cguzman95 closed 4 years ago
sounds like a good idea to me. we should probably do the same for the aero_rep
and sub_model
pointers too, just to be consistent.
Ok I will do the three cases
Another related question, can I move n_rxn away from condensed structure? (to model_data->n_rxn). Actually, it difficulties dealing with RXN and I think away from it will be more clear and easier to identify
That's fine with me. Can you do the same for n_aero_rep
, n_aero_phase
, and n_sub_model
too? Just so everything works the same.
Yep
Done on issue 99
I'm working on GPU implementation, and I need to copy the contents of RXN structure to another structure to improve the memory access on GPU. The case is that using the rxn_pointers, I don't know how much has to copy for the last value.
Thus, I propose to save an array of rxn_offsets. The first value will be always zero (since to access the first value we don't need to move the pointer), the second will be the length of the first rxn, and go on. This is very similar to the implementation of SPARSE matrix
What do you think @mattldawson ?