Задача сводится к табуляции функции двух переменных
// PascalABC.Net 3.0, сборка 1052
const
g:double=9.81; // среднее ускорение свободного падения
m:double=80;
h:double=20; mb:double=100; me:double=300;
var
a,m2:double;
m1:=mb;
begin
repeat
Writeln('m1=',m1);
m2:=mb;
repeat
Writeln('m2=',m2,', a=',(m2-m1)*g/(m1+m2+m/2):0:3);
m2+=h
until m2>me;
m1+=h
until m1>me
end.
Результат выполнения программы:
m1=100
m2=100, a=0.000
m2=120, a=0.755
m2=140, a=1.401
m2=160, a=1.962
m2=180, a=2.453
m2=200, a=2.885
m2=220, a=3.270
m2=240, a=3.614
m2=260, a=3.924
m2=280, a=4.204
m2=300, a=4.459
m1=120
m2=100, a=-0.755
m2=120, a=0.000
m2=140, a=0.654
m2=160, a=1.226
m2=180, a=1.731
m2=200, a=2.180
m2=220, a=2.582
m2=240, a=2.943
m2=260, a=3.270
m2=280, a=3.567
m2=300, a=3.839
m1=140
m2=100, a=-1.401
m2=120, a=-0.654
m2=140, a=0.000
m2=160, a=0.577
m2=180, a=1.090
m2=200, a=1.549
m2=220, a=1.962
m2=240, a=2.336
m2=260, a=2.675
m2=280, a=2.986
m2=300, a=3.270
m1=160
m2=100, a=-1.962
m2=120, a=-1.226
m2=140, a=-0.577
m2=160, a=0.000
m2=180, a=0.516
m2=200, a=0.981
m2=220, a=1.401
m2=240, a=1.784
m2=260, a=2.133
m2=280, a=2.453
m2=300, a=2.747
m1=180
m2=100, a=-2.453
m2=120, a=-1.731
m2=140, a=-1.090
m2=160, a=-0.516
m2=180, a=0.000
m2=200, a=0.467
m2=220, a=0.892
m2=240, a=1.280
m2=260, a=1.635
m2=280, a=1.962
m2=300, a=2.264
m1=200
m2=100, a=-2.885
m2=120, a=-2.180
m2=140, a=-1.549
m2=160, a=-0.981
m2=180, a=-0.467
m2=200, a=0.000
m2=220, a=0.427
m2=240, a=0.818
m2=260, a=1.177
m2=280, a=1.509
m2=300, a=1.817
m1=220
m2=100, a=-3.270
m2=120, a=-2.582
m2=140, a=-1.962
m2=160, a=-1.401
m2=180, a=-0.892
m2=200, a=-0.427
m2=220, a=0.000
m2=240, a=0.392
m2=260, a=0.755
m2=280, a=1.090
m2=300, a=1.401
m1=240
m2=100, a=-3.614
m2=120, a=-2.943
m2=140, a=-2.336
m2=160, a=-1.784
m2=180, a=-1.280
m2=200, a=-0.818
m2=220, a=-0.392
m2=240, a=0.000
m2=260, a=0.363
m2=280, a=0.701
m2=300, a=1.015
m1=260
m2=100, a=-3.924
m2=120, a=-3.270
m2=140, a=-2.675
m2=160, a=-2.133
m2=180, a=-1.635
m2=200, a=-1.177
m2=220, a=-0.755
m2=240, a=-0.363
m2=260, a=0.000
m2=280, a=0.338
m2=300, a=0.654
m1=280
m2=100, a=-4.204
m2=120, a=-3.567
m2=140, a=-2.986
m2=160, a=-2.453
m2=180, a=-1.962
m2=200, a=-1.509
m2=220, a=-1.090
m2=240, a=-0.701
m2=260, a=-0.338
m2=280, a=0.000
m2=300, a=0.316
m1=300
m2=100, a=-4.459
m2=120, a=-3.839
m2=140, a=-3.270
m2=160, a=-2.747
m2=180, a=-2.264
m2=200, a=-1.817
m2=220, a=-1.401
m2=240, a=-1.015
m2=260, a=-0.654
m2=280, a=-0.316
m2=300, a=0.000