MATLAB: How to use the boundary conditions of the “assembleFEMatrices” function in the own numerical integration using the Crank-Nicolson method

Partial Differential Equation Toolbox

How do I use the boundary conditions of the "assembleFEMatrices" function in my own numerical integration using the Crank-Nicolson method? I cannot used the PDE Toolbox's "solve" method.

Best Answer

There is no built-in function for you to accomplish this, and our "solve" method uses several numerical integration processes to solve the FEM problem.
In general, you will have to adjust the equations you are using to take into account the boundary conditions, which you current integration does not account for. Take a look at this link for an example solution that has both stiffness and boundary value matrices: