NeuroDiffGym / neurodiffeq

A library for solving differential equations using neural networks based on PyTorch, used by multiple research groups around the world, including at Harvard IACS.
http://pypi.org/project/neurodiffeq/
MIT License
664 stars 87 forks source link

BundleSolver setup too restrictive #192

Closed shuheng-liu closed 1 year ago

shuheng-liu commented 1 year ago

The following code block assumes each bundle parameter must fall into one of the following categories.

  1. a parameter that only appears in the boundary/initial condition (NOT in the equation); or
  2. a parameter that only appears in the equation (NOT in the boundary/initial condition) https://github.com/NeuroDiffGym/neurodiffeq/blob/a3df9fd221223a85ebc973002b8e3d2b280cbc19/neurodiffeq/solvers.py#L1318-L1332

However, in theory, there should be a case where the parameter appears both in the equation and in the initial/boundary condition. The var here probably implies a parameter that appears only in the equation. A fix is needed.

shuheng-liu commented 1 year ago

Plus, here's my interpretation of line 1331. It might be helpful to anyone else trying to understand what the non_var_filter is doing.