Jump to content

to solve an equations system

Featured Replies

Hi , I need your help .

I search on the web an algorithm that can solve an n equations system at n unknowns .

 

Thanks a lot!

Can you do it for two unknowns? Then you can do it for n unknowns. Or look up Gaussian elimination.

Or, if you have a range where you think the solution will be, you could just approximate numerically with a do/until loop. Or, if you don't have a range, you could use determinants (may be a little hard if you want a programmable algorithm...though I've never actually tried to program it). Or, you could just use matrices (the famous AX=B ).

gaussian elimination is the way to go. you could use cramer's rule. but as n gets big it becomes pointless

thanks , I hope I 'll find the algorithm on Internet.

I know how to use it manually but in order to program it , it's very difficult.

 

Above all , it must write the algorithm and then program it with pascal for example

this is a part of the result of my pascal program

 

procedure pivot(var mat1:matrice);

begin

 

 

 

for k:=1 to DIM_MAX-1 do

 

 

 

 

begin

 

for i:=k to DIM_MAX-1 do

 

begin

 

for j:=k to DIM_MAX-1 do

begin

mat1[i+1,1+j]:= mat1[i+1,j+1] * mat1[k,k] - mat1[i+1,k]* mat1[k,j+1] ;

mat1[i+1,k]:=0;

end;

 

 

 

end;

end;

 

 

end;

Archived

This topic is now archived and is closed to further replies.

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.