How to give initial guess and initial condition for a nonlinear - time dependent PDE problem (transient non-linear heat equation) in pde tool box?
3 ビュー (過去 30 日間)
古いコメントを表示
I have (transient non-linear heat equation) i.e , k = 0.7 + 0.003*T, tlist = linespace(0,0.5,20); therefore my pde coefficients wills be d = 1, m = a = 0, c = k, f = 1; since c coefficent is non linear (dependent on T, temperature), My Intial Boundary condition is 3 and initial guess is 5. But i see command IC and initial guess is same. i.e setInitialConditions(model,u0); So how do i differentiate them?
This is how my code goes
clear,clc,close all;
model = createpde();
%% Geometry
R1 = [3;4;-1;1;1;-1;-1;-1;1;1];
g = decsg(R1);
heatmodel_geom = geometryFromEdges(model,g);
%% Mesh
msh = generateMesh(model,'GeometricOrder','linear');
[P,E,T] = meshToPet( msh );
%% Specify Coefficients
c = @(~,state) 0.7+0.003*state.u; % nonlinear coefficient
specifyCoefficients(model,'m',0,'d',1,'c',c,'a',0,'f',1);
%% Spacial BC
applyBoundaryCondition(model,'dirichlet','edge',[1 2 3 4],'u',0);
%% Initial guess and initial condition
setInitialConditions(model,3); % Initial condition
setInitialConditions(model,5); % Initial guess to solve non linear pde.... BUT DO I DIFFERENTIATE BOTH THIS COMMANDS TO ITS RESPECTIVE JOBS
0 件のコメント
採用された回答
Ravi Kumar
2021 年 3 月 4 日
For nonlinear elliptic problem, inputs in setInitialCcnditions is the initial guess for the nonlinear solver. For time-dependent problems initial condiions and initial gues are one and the same.
Regards,
Ravi
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Geometry and Mesh についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!