Can I solve a system of nolinear parabolic PDE using PDE toolbox in MATLAB?
조회 수: 3 (최근 30일)
이전 댓글 표시
I have a system of two parabolic PDEs with c coefficient of second equation as a function of solution of both first and second equation. I defined c coefficient as a function handle, but getting error: Function handle specifying a coefficient must accept two input arguments and return one output argument.
My function handle is: function c = ccofficient(region,state)
Dref = 2.592e-5; % reference humidity diffucion coefficient in m^2/day alpha = 0.05; % represents Dh,min/Dh,max n = 10; % characterises spread of the drop in Dh U = 25; % activation energy of moisture diffusion process in kJ/mol Tref = 23; % Reference temperature at which Dh,ref measured te = 28; % hydration period of concrete in days hc = 0.75; % value of pore relative humidity at which Dh drops halfway between Dh,max and Dh,min. R = -0.03056; % gas constant in Joule/(mol^oC) t = state.time; n1 = 2; nr = numel(region.x); c = zeros(n1,nr); c(1,:) = k*ones(1,n1); c(2,:) = Dref*(alpha+(1-alpha)+(1+((1-state.u(:,2,t))/(1-hc)).^n))*exp(U/R*(1/Tref-1/(state.u(:,1,t))))... *0.3+(13/te).^0.5;
Kindly suggest me how to write function handle for this type of nonlinear parabolic system of PDE.
댓글 수: 3
채택된 답변
Ravi Kumar
2017년 4월 14일
Hi Aditi,
This error generally indicates that the function for c, ccoefficient, did not return a output value. This could be due to a syntax error in the function. You can insert a breakpoint in the function and step through the code to identify the line containing error.
Regards,
Ravi
댓글 수: 4
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Eigenvalue Problems에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!