There still seems to be a problem with this example: - The line search breaks. - The plots are not informative. - There are a lot of errors in the structured array codes.