Help to identify the problem with the code

  1. See
  1. Similarly,

Use model-local variables, i.e. the ones with the pound operator.