@francesco-ballarin Thank you for your reply. The problem got fixed when I removed the creation of the dolfinx.fem.form object outside of my loop. Though for me this was not obvious, because I used my code to solve an optimal control problem which had a RHS depending on the time. What solved my issue was declaring the time dependent variable as fem.Constant as they did here
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| Error occuring in fem.form | 9 | 1080 | October 2, 2023 | |
| Major problem ImportError FFCX | 3 | 35 | May 5, 2025 | |
| Error in JIT compilation of dolfinx fem forms after updating to MacOS 15.4 | 2 | 93 | May 30, 2025 | |
| Unable to found JIT module | 18 | 1061 | February 14, 2024 | |
| Error importing dolfinx | 2 | 1067 | May 12, 2022 |