home *** CD-ROM | disk | FTP | other *** search
/ ticalc.org / ticalc_org_rev_b.iso / archives / 81 / basic / math / sys3eq.81 < prev    next >
Encoding:
Text File  |  2001-07-01  |  1.1 KB  |  54 lines

  1. SYS3EQ.81 (System of 3 Equations) freeware
  2. by Daniel Bishop (danb2k@hotmail.com)
  3. 2000-10-14
  4.  
  5. This programs solves systems of 3 linear equations.
  6.  
  7. How to run it:
  8. 1.  Type it in.  (Hey, are you sure you don't need a link port?)
  9. 2.  Run the program.  Enter the coefficients when prompted.  (X, Y, Z, and constant).
  10. 3.  The program will give you the solution for X, Y, and Z.  If you need to write them in fractional form, just remember that X=MX/M, Y=MY/M, and Z=MZ/M.
  11.  
  12. Prgm_:SYSEQ3
  13. :Disp "AX+BY+CZ=D"
  14. :Disp "A="
  15. :Input A
  16. :Disp "B="
  17. :Input B
  18. :Disp "C="
  19. :Input C
  20. :Disp "D="
  21. :Input D
  22. :Disp "EX+FY+GZ=H"
  23. :Disp "E="
  24. :Input E
  25. :Disp "F="
  26. :Input F
  27. :Disp "G="
  28. :Input G
  29. :Disp "H="
  30. :Input H
  31. :Disp "IX+JY+KZ=L"
  32. :Disp "I="
  33. :Input I
  34. :Disp "J="
  35. :Input J
  36. :Disp "K="
  37. :Input K
  38. :Disp "L="
  39. :Input L
  40. :A(FK-GJ)+B(GI-EK)+C(EJ-FI -> M
  41. :If M=0
  42. :Goto N
  43. :(D(FK-GJ)+B(GL-HK)+C(HJ-FL))/M -> X
  44. :(A(HK-GL)+D(GI-EK)+C(EK-HI))/M -> Y
  45. :(A(FL-HJ)+B(HI-EL)+D(EJ-FI))/M -> Z
  46. :Disp "X="
  47. :Disp X
  48. :Disp "Y="
  49. :Disp Y
  50. :Disp "Z="
  51. :Disp Z
  52. :Stop
  53. :Lbl N
  54. :Disp "NO SOLUTION"