See for instance: Custom Newton Solver problem with Dirichlet conditions - #5 by javijv4
You can then easily adapt the code to include an if statement
See for instance: Custom Newton Solver problem with Dirichlet conditions - #5 by javijv4
You can then easily adapt the code to include an if statement