[SOLVED] Need help for Matlab code: Method of Moments: Conducting Plate

Status
Not open for further replies.

Teg-Men

Junior Member level 2
Joined
Sep 22, 2010
Messages
24
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,283
Location
Ankara
Activity points
1,468
Hi, I am trying to write a Matlab code that works for charged conducting Plate. Spesifically, the problem is from R.F. Harringston's "Field Computation by Moment Method" Ch2.2

I have following codes, but that does not work for the cases if I choose number of subsections more than one.

Here are codes:
function [x, y] = lengthVectors2x2(length, N)
%AREA2X2 Summary of this function goes here
% Detailed explanation goes here
subLength = length/(N);
for i = 1:N;
x(i) = abs((length+subLength)/2 - i* subLength);
end
y = x;
end

function [Gm] = MatrixG2x2(N,V)
%It calculates Lmn matrix by using point matching
% Enter the N*N matrix size
% Detailed explanation goes here
for m =1:N
Gm(m) =V;
end
Gm = Gm';
end



I think the problem is in the function MatrixL2x2. Because I calculate the value for the case #subsection = 1

Here are the actual results:
N = 1 => 31.5 picofarads/meter
N = 3 => 37.3 picofarads/meter
N = 4 => 38.2 picofarads/meter
N = 6 => 39.2 picofarads/meter

As I said, the code can find N=1 case result.
Please ignore comments.
Thanks.
 

I solved the problem, the topic can be closed.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…