diff --git a/RTX class/BalazsAperture.m b/RTX class/BalazsAperture.m
index b8ccb7bbbe4d5528996f97c7090ba24afe41713e..3384ce13a131aad58cceb00e55ce0d3a8e1153ea 100644
--- a/RTX class/BalazsAperture.m	
+++ b/RTX class/BalazsAperture.m	
@@ -29,7 +29,10 @@ classdef BalazsAperture < Aperture
             histogram = obj.getCollisionHistogram();
             figure;            
             x = linspace(-obj.size/2, obj.size/2, length(histogram));
+            subplot(2,1,1);
             plot(x, abs(histogram));
+            subplot(2,1,2);
+            plot(x, angle(histogram));
             title("Apertúrán áthaladó sugarak eloszlása");
             xlabel("Pozíció");
             ylabel("Sugarak száma");
diff --git a/RTX class/FarField.m b/RTX class/FarField.m
index cf39a5c0137ca8c1e57713f93e47445fd15fe5b5..60b5d9f5bd7a545f9c535e3b736cb6a8299ef08c 100644
--- a/RTX class/FarField.m	
+++ b/RTX class/FarField.m	
@@ -84,11 +84,12 @@ classdef FarField < handle
             end
             figure;
             y = abs(obj.field);
-            %y = y/max(y);
+            y = y/max(y);
             plot(obj.theta*180/pi, 20*log10(y));
             title("Távoltér");
             xlabel("\Theta [°]");
             ylabel("S [dB]");
+            ylim([-40 0]);
         end
         
         function beamWidth = getBeamWidth(obj)
diff --git a/RTX class/SegmentedAperture.m b/RTX class/SegmentedAperture.m
index 14a61064f8d50674a7db149cce0b8e588419cc24..c17dde1206db84ac2ef50919fb456c7e4aa3abcc 100644
--- a/RTX class/SegmentedAperture.m	
+++ b/RTX class/SegmentedAperture.m	
@@ -18,7 +18,7 @@ classdef SegmentedAperture < Aperture
                 if length(trace.rays) == length(obj.prevTrace.rays)
                     segmentSize = abs(obj.prevCol.pos.y - col.pos.y);
                     obj.segments.add(Segment(obj.prevCol.pos.y, col.pos.y, ...
-                        trace.complexAmplitude/segmentSize * exp(1i*mod(trace.length, trace.wavelength))));
+                        trace.complexAmplitude/segmentSize * exp(1i*2*pi*mod(trace.length, trace.wavelength)/trace.wavelength)));
                 end
             end
             obj.prevTrace = trace;
@@ -37,9 +37,16 @@ classdef SegmentedAperture < Aperture
             [histogram,x1, x2] = obj.getCollisionHistogram();
             plot(0, 0);
             hold on;
-            for k = 1:length(histogram)
-                plot([x1(k) x2(k)], [abs(histogram(k)), abs(histogram(k))],'b');
-            end
+%             for k = 1:length(histogram)
+%                 plot([x1(k) x2(k)], [abs(histogram(k)), abs(histogram(k))],'b');
+%             end
+            x = [x1; x2];
+            h = [histogram; histogram];
+            subplot(2,1,1);
+            plot(x(:), abs(h(:)));
+            subplot(2,1,2);
+            plot(x(:), angle(h(:)));
+            %plot(x(:), h(:), 'b');
             hold off;
         end
     end
diff --git a/RTX class/rtx_test.m b/RTX class/rtx_test.m
index 50ce76dfb116931be0ed865f59b830020e5c271f..0cdb737af5de89450c7e15911ba1cc0ed4c9fabd 100644
--- a/RTX class/rtx_test.m	
+++ b/RTX class/rtx_test.m	
@@ -1,15 +1,15 @@
-%clear
-%close all
+clear
+close all
 
 reflectors = [PlaneReflector([2 0], 2), ParabolaReflector([0 0], 4, 3)];
 %reflectors = [PlaneReflector([-1 1], 0)];
-aperture = BalazsAperture([3 0], 20, 400);
+aperture = BalazsAperture([3 0], 20, 1000);
 aperture2 = SegmentedAperture([3 0], 20);
-antenna = Antenna(Vect(1,0), [ones(1,125), zeros(1,750), ones(1,125)], zeros(1,1000));
-%antenna = Antenna(Vect(1,0));
+antenna = Antenna(Vect(1,0), [ones(1,1250), zeros(1,7500), ones(1,1250)], zeros(1,10000));
+% antenna = Antenna(Vect(1,0), ones(1,10000), zeros(1,10000));
 wavelength = 3e8/1e9;
 nRay = 10000;
-nRay2 = 1000;
+nRay2 = 2000;
 
 rtx = RTX(reflectors, aperture, antenna, wavelength, nRay);
 rtx.trace();