function [MPointsC1,MPointsC2,MPointsT2,MPointsP] = ChangePointsTransDesp(MPointsC1O,MPointsC2O,MPointsT2O,MPointsPO,T,n)
%Esta função serve para alterar as matrizes com as coordenadas dos pontos 
%através da aplicação das transformações presentes em T

%Quadrado 1º andar pointsc1
TC1_1=T(:,:,n,2)*T(:,:,n,1);
pointsc1=TC1_1*MPointsC1O(:,:,1);
MPointsC1(:,:,1)=pointsc1;

%Quadrado 2º andar pointsc21
TC2_2=T(:,:,n,4)*T(:,:,n,3);
pointsc21=TC1_1*TC2_2*MPointsC2O(:,:,1);
MPointsC2(:,:,1)=pointsc21;

%Pentagono pointsp
TP_1=T(:,:,n,6)*T(:,:,n,5);
pointsp=TC1_1*TC2_2*TP_1*MPointsPO(:,:,1);
MPointsP(:,:,1)=pointsp;

%Quadrado 1º andar pointsc2
TC1_2=T(:,:,n,8)*T(:,:,n,7);
pointsc2=TC1_2*MPointsC1O(:,:,2);
MPointsC1(:,:,2)=pointsc2;

%Triangulo 2º andar pointst1
TT2_1=T(:,:,n,10)*T(:,:,n,9);
pointst1=TC1_2*TT2_1*MPointsT2O(:,:,1);
MPointsT2(:,:,1)=pointst1;

%Quadrado 1º andar pointsc3
TC1_3=T(:,:,n,12)*T(:,:,n,11);
pointsc3=TC1_3*MPointsC1O(:,:,3);
MPointsC1(:,:,3)=pointsc3;

%Quadrado 2º andar pointsc22
TC2_2=T(:,:,n,14)*T(:,:,n,13);
pointsc22=TC1_3*TC2_2*MPointsC2O(:,:,2);
MPointsC2(:,:,2)=pointsc22;

%Quadrado 1º andar pointsc4
TC1_4=T(:,:,n,16)*T(:,:,n,15);
pointsc4=TC1_4*MPointsC1O(:,:,4);
MPointsC1(:,:,4)=pointsc4;

%Triângulo 2º andar pointst2
TT2_2=T(:,:,n,18)*T(:,:,n,17);
pointst2=TC1_4*TT2_2*MPointsT2O(:,:,2);
MPointsT2(:,:,2)=pointst2;

%Quadrado 1º andar pointsc5
TC1_5=T(:,:,n,20)*T(:,:,n,19);
pointsc5=TC1_5*MPointsC1O(:,:,5);
MPointsC1(:,:,5)=pointsc5;

%Quadrado 2º andar pointsc23
TC2_3=T(:,:,n,22)*T(:,:,n,21);
pointsc23=TC1_5*TC2_3*MPointsC2O(:,:,3);
MPointsC2(:,:,3)=pointsc23;

%Quadrado 1º andar pointsc6
TC1_6=T(:,:,n,24)*T(:,:,n,23);
pointsc6=TC1_6*MPointsC1O(:,:,6);
MPointsC1(:,:,6)=pointsc6;

%Triângulo 2º andar pointst3
TT2_3=T(:,:,n,26)*T(:,:,n,25);
pointst3=TC1_6*TT2_3*MPointsT2O(:,:,3);
MPointsT2(:,:,3)=pointst3;

%Quadrado 1º andar pointsc7
TC1_7=T(:,:,n,28)*T(:,:,n,27);
pointsc7=TC1_7*MPointsC1O(:,:,7);
MPointsC1(:,:,7)=pointsc7;

%Quadrado 2º andar pointsc24
TC2_4=T(:,:,n,30)*T(:,:,n,29);
pointsc24=TC1_7*TC2_4*MPointsC2O(:,:,4);
MPointsC2(:,:,4)=pointsc24;

%Quadrado 1º andar pointsc8
TC1_8=T(:,:,n,32)*T(:,:,n,31);
pointsc8=TC1_8*MPointsC1O(:,:,8);
MPointsC1(:,:,8)=pointsc8;

%Triângulo 2º andar pointst4
TT2_4=T(:,:,n,34)*T(:,:,n,33);
pointst4=TC1_8*TT2_4*MPointsT2O(:,:,4);
MPointsT2(:,:,4)=pointst4;

%Quadrado 1º andar pointsc9
TC1_9=T(:,:,n,36)*T(:,:,n,35);
pointsc9=TC1_9*MPointsC1O(:,:,9);
MPointsC1(:,:,9)=pointsc9;

%Quadrado 2º andar pointsc25
TC2_5=T(:,:,n,38)*T(:,:,n,37);
pointsc25=TC1_9*TC2_5*MPointsC2O(:,:,5);
MPointsC2(:,:,5)=pointsc25;

%Quadrado 1º andar pointsc10
TC1_10=T(:,:,n,40)*T(:,:,n,39);
pointsc10=TC1_10*MPointsC1O(:,:,10);
MPointsC1(:,:,10)=pointsc10;

%Triângulo 2º andar pointst5
TT2_5=T(:,:,n,42)*T(:,:,n,41);
pointst5=TC1_10*TT2_5*MPointsT2O(:,:,5);
MPointsT2(:,:,5)=pointst5;

end