Subject Computer Science MATLAB for Computer Science

Question

See Question.pdf

Solution Preview

This material may consist of step-by-step explanations on how to solve a problem or examples of proper writing, including the use of citations, references, bibliographies, and formatting. This material is made available for the sole purpose of studying and learning - misuse is strictly forbidden.

%------------Problem2------------


clear all
clc
close all

global Inputs

Inputs.delta = 0.04; %given value of delta
Inputs.xmin = 0;
Inputs.xmax = 1;
Inputs.ymin = 0;
Inputs.ymax = 1;
Inputs.nbc = 4; %no. of boundary conditions
Inputs.xnseg = 100; % equal segments in X and Y direction
Inputs.ynseg = 100;
Inputs.neq = (Inputs.xnseg+1)*(Inputs.ynseg+1);
Inputs.dx = (Inputs.xmax-Inputs.xmin)/Inputs.xnseg;
Inputs.dy = (Inputs.ymax-Inputs.ymin)/Inputs.ynseg;

% Initialize
Inputs.x = linspace (Inputs.xmin,Inputs.xmax,Inputs.xnseg+1)';
Inputs.y = linspace (Inputs.ymin,Inputs.ymax,Inputs.ynseg+1)';
u = zeros(Inputs.xnseg+1,Inputs.ynseg+1);...

This is only a preview of the solution. Please use the purchase button to see the entire solution

$50.00

or $1 if you
register a new account!

Assisting Tutor

Related Homework Solutions

Get help from a qualified tutor
Live Chats