cancel
Showing results for
Did you mean:
cancel
Showing results for
Did you mean:

# pde solvers need more flexibility

## pde solvers need more flexibility

This is big for me. Both PDEsolve and numol are too restrictive. PDEsolve needs to handle vector variables (subscripted variables). Numol, which can handle vectors, can't have mixed boundary condtions at either end of the problem. These problems have been noted in the discussion groups, several years ago. I couldn't find this problem mentioned in this group.

If PDEsolve can be made to accept vector variables, that would be preferred because (1) it handles mixed boundary condition types and (2) it looks better (more like math notation).

Because of these restrictions, I've created a dynamic, 2D (space dimensions) pde solve program using a semi-implicit numerical approach. Works great, but it has to be hidden in a report.

An Update

I've thought of one way of changing the PDEsolve that would handle most problems. I understand that the subscripts are needed to show what independent variables are to be used for the differential. This currently prevents the use of a vector dependent variable. But suppose you make two changes. First, have Prime designate all vector and matrix variables with bold names. Second, have PDEsolve recognize when a scalar variable or a vector/matrix variable is involved. It then knows that it needs to solve the equation for all elements of the dependent variable.

This should work for most problems. If the entire equation can be written in vector/matrix form, then it should work. If the equations have to indicate individual elements in a vector or matrix, it won't work. The boundary conditions can be written in vector form also.

Message was edited by: Harvey Hensley

3-Visitor

The snip below shows an example of how pdesolve should work. Note that X is a vector, but the indexes are never used in the equations in the solve block so they don't interfere with the literal subscripts used for the derivatives. The indexes of X are used in the definition of Rxn and Qr functions however. Rxn is also a vector function with the same number of elements as X vector.

The dimensions of T and X are defined by the initial and boundary conditions, there shouldn't be a need for explicitly defining these dimensions (i.e. number of elements).

This method should be able to handle many problems. There still may be problems that need to explicitly refer to the elements of the dependent variables, but having the above capability would be a big help. This is not a huge change (it seems to me) from the current solver. It just requires the ability to recognize a vector equation with a vector dependent variable.

##### Another option:

Instead of the literal subscripts for the independent variables for the derivatives,

It seems to me if this form were used, we should also be able to use subscripted variables explicitly in the equation.

3-Visitor

For comparison: My hopscotch numerical method of a 2D reactor is 10 pages long. The above method would reduce that model to about a half page, and keep the model/report in terms of partial differential equations that are easy to read.

Community Manager
Status changed to: Archived

Hello,

We are archiving your idea as part of a general review. This action is based on the age of your idea and the total number of votes received, as per this announcement.

You can always post a new idea with all the details required in the form.