BrainDynamicsUSYD / nftsim

C++ library for simulation of multiscale neural field dynamics
Apache License 2.0
30 stars 24 forks source link

Review Configf::find() and its use. #160

Open stuart-knock opened 6 years ago

stuart-knock commented 6 years ago

The member function Configf::find() can match a key that does not belong to the specified <unique> component of the Check string. Note, this issue contributed to the difficulty in resolving issue #101.

Based on the description in the member function, Configf::find() should probably be modified to not search past the end of the line containing <unique>, but this needs to be reviewed.


NOTE: The fix in #163 obscures one issue related to Configf::find(). In the minimal example given in #101, with one single population and one single coupling. When using Couple::Ramp, that had the key nus before #163, and Config::find() was searching for key nu, the simulation still ran without segmentation errors or any other errors. There were obvious differences in the resulting timeseries of the Propagator.phi.1, but no differences in the timeseries of Coupling.nu.1.

What this implies is that the member function Coupling::nuinit(), which uses Configf::find(), was initializing nu to some value. Whatever this value was, it was passed and used in Dendrite. Again, #163 gets rids of the numerical differences observed in the output data, but it does not get rid of variable initialization issues. See #164.