# Лабораторная работа №1. Программирование векторных и матричных операций, страница 5

VVODc(n,a,b);

Scolar_Pr_vekt(n,a,b,sk);

end;

'd': begin

VVODd(sk,n,x);

Mat_Sk(n,Sk,x,z);

end;

'e': begin

VVODe(n,x,a);

Mult_Matr_Vec(n,x,a,a1);

end;

'f': begin

VVODf(n,x,y);

sum_matr(n,x,y,z);

end;

'g': begin

VVODg(n,x,y);

mt_mt(n,x,y,z);

end;

else Writeln('Nepravilno vibranij punkt');

end;

Readln;

end.

Unit U_VVOD;

interface

const n1 = 50;

type

vector = array[1..n1] of real;

matrix = array[1..n1,1..n1] of real;

fn = string[20];

var n: integer;

sk: real;

a, b, a1: vector;

x, y, z: matrix;

fname: fn;

procedure VVODa(var sk_: real; var n_: integer; var a_: vector);

procedure VVODb(var n_: integer; var a_, b_: vector);

procedure VVODc(var n_: integer; var a_, b_: vector);

procedure VVODd(var sk_: real; var n_: integer; var x_: matrix);

procedure VVODe(var n_: integer; var x_: matrix; var a_: vector);

procedure VVODf(var n_: integer; var x_,y_: matrix);

procedure VVODg(var n_: integer; var x_,y_: matrix);

implementation

procedure VVODa;

var F: text;

i: Integer;

begin

Writeln('a * Sk');

Writeln('VV. fail n.d.:');

Readln(fname);

Assign(F,fname);

Reset(F);

Read(F, sk, n);

for i := 1 to n do

Read(F, a[i]);

Close(F);

sk_ := sk;

n_ := n;

a_ := a;

end;

procedure VVODb;

var F: text;

i: Integer;

begin

Writeln('a + b');

Writeln('VV. fail n.d.:');

readln(fname);

Assign(F,fname);

Reset(F);

Read(F, n);

for i := 1 to n do