Determine locations struct used in PDE solver
이전 댓글 표시
Hi,
I'm trying to solve a 2D PDE where the 'c' coefficient is a function of the (x,y) coordinate. In order to specify this coefficient, I'm trying to create a matrix that is of length N by M where N are the number of x points and M the number of y points used to solve the PDE. I can then pass this matrix to the PDE solver by calling a function that returns the value of the coefficient at (x,y).
Unfortunately I need to populate the matrix outside of the function call, since I am using the PDE solver to fit for some data so I need to be able to modify it in between function calls. Therefore, I need to know how many points I need to fit for.
I noticed I cannot access the locations struct before calling solvepde and that the number of (x,y) points is larger than the number of nodes in my mesh, so I can't form the matrix needed or find the value for the (x,y) pair for the C coefficient. Is it somehow possible to pre-compute the coordinates and number of points that will be used in the PDE solver?
Thanks in advance!
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Boundary Conditions에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!