function [arraysito,arraysitoENG,controlsito,yesTL,yesTLHR,yesTLH,yesTLHRH,yesPL,yesBL,yesLL,...
    yesRL,yesKL,yesKLHR,yesThL,yesPT100,yesIPL,yesIPLHR,yesTuL,yesRaL,yesPCL,yesPCLHR,...
    yesPrL,yesEL,yes3DEL,yesWEL,yesMPBEL,yesCrL,yes3DCrL,yesBML,yesHL,...
    yesLuxL,yesCO2,yesRSN,yesRSNHR,yesTrL,yesSM,yes2DCrL,yesPE,yesWL,yesGF,yesGS,...
    rTL,rTLHR,rTLH,rTLHRH,rPL,rBL,rLL,rRL,rKL,rKLHR,rThL,rPT100,rIPL,rIPLHR,rTuL,rRaL,...
    rPCL,rPCLHR,rPrL,rEL,r3DEL,rWEL,rMPBEL,rCrL,r3DCrL,rBML,rHL,rLuxL,rCO2,rRSN,rRSNHR,...
    rTrL,rSM,r2DCrL,rPE,rWL,rGF,rGS,nCT,...
    NodoTiltLink,NodoTiltLinkHR,NodoTiltLinkH,NodoTiltLinkHRH,NodoPiezoLink,NodoBaroLink,...
    NodoLoadLink,NodoRainLink,NodoKlinoLink,NodoKlinoLinkHR,NodoThermLink,NodoPT100Link,...
    NodoInPlaceLink,NodoInPlaceLinkHR,NodoTunnelLink,NodoRadialLink,NodoPreConvLink,...
    NodoPreConvLinkHR,NodoPressureLink,NodoExtensometerLink,Nodo3DExtensometerLink,...
    NodoWireExtensometerLink,NodoMultiPointExtensometerLink,NodoCrackLink,Nodo3DCrackLink,...
    NodoBaroMusaLink,NodoHumidityLink,NodoLuxLink,NodoCO2Link,NodoRSNLink,NodoRSNHRLink,...
    NodoTriggerLink,NodoStressMeter,Nodo2DCrackLink,NodoPendulum,NodoWeirLink,NodoGflowLink,...
    NodoGshockLink,tipoarray,tipoalarms,nVMS,nTL,nCAM,nAL] = info_Sito(chainID,alarms,...
    Chain_Scheme,conn,num_nodi,FileName)

fileID = fopen(FileName,'a');
fmt = '%s \r';
text = 'info_Sito function started';
fprintf(fileID,fmt,text);

%% Conto gli Array

% identifico la tipologia di array
[dev,~] = size(chainID); % Numero di Array
tipoarray = cell(dev,1);
for d = 1:dev
    comando = ['select type from tools where unit_id = ''' num2str(cell2mat(chainID(d,1)))...
        ''' and id = ''' num2str(cell2mat(chainID(d,3))) ''' '];
    curs = exec(conn,comando);
    curs = fetch(curs);
    tipoarray(d,1) = curs.Data;
end

% Scarico l'allarme relativo al sito
[ctrl,ctrl2] = size(alarms); % Numero di Control Tools
tipoalarms = cell(ctrl,1);
if ctrl2 ~= 1
    for c = 1:ctrl
        comando = ['select type from ctrltypes where id = ''' num2str(cell2mat(alarms(c,3))) ''' '];
        curs = exec(conn,comando);
        curs = fetch(curs);
        tipoalarms(c,1) = curs.Data;
    end
    evita = 0;
else
    evita = 1;
end

[rA,~] = size(tipoarray);
[rC,~] = size(tipoalarms);
% conto quanti array ci sono per ciascuna tipologia
nVA = 0; % Vertical Array
nHA = 0; % Horizontal Array
nPZA = 0; % Piezo Array
nTA = 0; % Therm Array
nVAS = 0; % Vertical Array Structure
nIPA = 0; % In Place Array
nKA = 0; % Klino Array
nCA = 0; % Cir Array
nRA = 0; % Rad Array
nPCA = 0; % PreConv Array
nRSN = 0; % RockFall Safety Network
nMUSA = 0; % Musa System
nAA = 0; % Analog Array
nTS = 0; % Trigger System
nVMS = 0; % Variable Message System
nTL = 0; % Traffic Lights
nAL = 0; % Alarms
nCAM = 0; % Camera
nP = 0; % Pluviometro
nDFSN = 0; % Debris Flow Safety Network

for a = 1:rA
    if strcmp(tipoarray(a),'Cir Array')
        nCA = nCA+1;
    elseif strcmp(tipoarray(a),'Rad Array')
        nRA = nRA+1;
    elseif strcmp(tipoarray(a),'PreConv Array')
        nPCA = nPCA+1;
    elseif strcmp(tipoarray(a),'Vertical Array')
        nVA = nVA+1;
    elseif strcmp(tipoarray(a),'Horizontal Array')
        nHA = nHA+1;
    elseif strcmp(tipoarray(a),'Piezo Array')
        nPZA = nPZA+1;
    elseif strcmp(tipoarray(a),'Pluviometro')
        nP = nP+1;
    elseif strcmp(tipoarray(a),'Therm Array')
        nTA = nTA+1;
    elseif strcmp(tipoarray(a),'Rockfall Safety Network')
        nRSN = nRSN+1;
    elseif strcmp(tipoarray(a),'Debris Flow Safety Network')
        nDFSN = nDFSN+1;
    elseif strcmp(tipoarray(a),'Vertical Array Structure')
        nVAS = nVAS+1;
    elseif strcmp(tipoarray(a),'In Place Array')
        nIPA = nIPA+1;
    elseif strcmp(tipoarray(a),'MUSA')
        nMUSA = nMUSA+1;
    elseif strcmp(tipoarray(a),'Klino Array')
        nKA = nKA+1;
    elseif strcmp(tipoarray(a),'Analog Array')
        nAA = nAA+1;
    elseif strcmp(tipoarray(a),'Trigger System')
        nTS = nTS+1;
    end
end
for a = 1:rC
    if strcmp(tipoalarms(a),'VMS')
        nVMS = nVMS+1;
    elseif strcmp(tipoalarms(a),'Traffic Lights')
        nTL = nTL+1;
    elseif strcmp(tipoalarms(a),'Alarms')
        nAL = nAL+1;
    elseif strcmp(tipoalarms(a),'Camera')
        nCAM = nCAM+1;
    end
end

% Conto le tipologie di Array
indice = 1;
if nCA > 0
    contarray{indice,1} = [num2str(nCA) ' Cir Array'];
    if nCA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nCA) ' Cir Arrays'];
    end
    indice = indice +1;
end
if nRA > 0
    contarray{indice,1} = [num2str(nRA) ' Rad Array'];
    if nRA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nRA) ' Rad Arrays'];
    end
    indice = indice +1;
end
if nPCA > 0
    contarray{indice,1} = [num2str(nPCA) ' PreConv Array'];
    if nPCA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nPCA) ' PreConv Arrays'];
    end
    indice = indice +1;
end
if nVA > 0
    contarray{indice,1} = [num2str(nVA) ' Vertical Array'];
    if nVA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nVA) ' Vertical Arrays'];
    end
    indice = indice +1;
end
if nHA > 0
    contarray{indice,1} = [num2str(nHA) ' Horizontal Array'];
    if nHA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nHA) ' Horizontal Arrays'];
    end
    indice = indice +1;
end
if nPZA > 0
    contarray{indice,1} = [num2str(nPZA) ' Piezo Array'];
    if nPZA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nPZA) ' Piezo Arrays'];
    end
    indice = indice +1;
end
if nP > 0
    contarray{indice,1} = [num2str(nP) ' Pluviometro'];
    if nP == 1
        contarrayENG{indice,1} = [num2str(nP) ' Rain Gauge'];
    else
        contarrayENG{indice,1} = [num2str(nP) ' Rain Gauges'];
    end
    indice = indice +1;
end
if nTA > 0
    contarray{indice,1} = [num2str(nTA) ' Therm Array'];
    if nTA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nTA) ' Therm Arrays'];
    end
    indice = indice +1;
end
if nRSN > 0
    contarray{indice,1} = [num2str(nRSN) ' RockFall Safety Network'];
    if nRSN == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nRSN) ' RockFall Safety Networks'];
    end
    indice = indice +1;
end
if nDFSN > 0
    contarray{indice,1} = [num2str(DFRSN) ' Debris Flow Safety Network'];
    if nDFSN == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nDFSN) ' Debris Flow Safety Networks'];
    end
    indice = indice +1;
end
if nVAS > 0
    contarray{indice,1} = [num2str(nVAS) ' Vertical Array Structure'];
    if nVAS == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nVAS) ' Vertical Arrays Structure'];
    end
    indice = indice +1;
end
if nIPA > 0
    contarray{indice,1} = [num2str(nIPA) ' In Place Array'];
    if nIPA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nIPA) ' In Place Arrays'];
    end
    indice = indice +1;
end
if nMUSA > 0
    contarray{indice,1} = [num2str(nMUSA) ' MUSA'];
    if nMUSA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nMUSA) ' MUSAs'];
    end
    indice = indice +1;
end
if nKA > 0
    contarray{indice,1} = [num2str(nKA) ' Klino Array'];
    if nKA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nKA) ' Klino Arrays'];
    end
    indice = indice +1;
end
if nAA > 0
    contarray{indice,1} = [num2str(nAA) ' Analog Array'];
    if nAA == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nAA) ' Analog Arrays'];
    end
    indice = indice +1;
end
if nTS > 0
    contarray{indice,1} = [num2str(nTS) ' Trigger System'];
    if nTS == 1
        contarrayENG{indice,1} = contarray{indice,1};
    else
        contarrayENG{indice,1} = [num2str(nTS) ' Trigger Systems'];
    end
end
arraysito = strjoin(contarray, ', ');
arraysitoENG = strjoin(contarrayENG, ', ');

if evita == 0
    % Conto le tipologie di Control Tools
    indice_bis = 1;
    if nVMS > 0
        conttools{indice_bis,1} = [num2str(nVMS) ' Variable Message System'];
        indice_bis = indice_bis +1;
    end
    if nTL > 0
        conttools{indice_bis,1} = [num2str(nTL) ' Traffic Lights'];
        indice_bis = indice_bis +1;
    end
    if nAL > 0
        conttools{indice_bis,1} = [num2str(nAL) ' Alarms'];
        indice_bis = indice_bis +1;
    end
    if nCAM > 0
        conttools{indice_bis,1} = [num2str(nCAM) ' Camera'];
    end
    controlsito = strjoin(conttools, ', ');
    nCT = nVMS+nTL+nAL+nCAM;
else
    controlsito = 0;
    nCT = 0;
end

%% Stabilisco se è presente o meno un sensore ed il numero di sensori per ogni tipologia
[col,~] = size(chainID); % Numero di Array
% Per ogni tipologia di nodo, riconosco se è presente o meno nella catena
yesTL = zeros(col,1); % Tilt Link V
yesTLHR = zeros(col,1); % Tilt Link HR V
yesTLH = zeros(col,1); % Tilt Link H
yesTLHRH = zeros(col,1); % Tilt Link HR H
yesPL = zeros(col,1); % Piezo Link
yesBL = zeros(col,1); % Baro Link
yesLL = zeros(col,1); % Load Link
yesRL = zeros(col,1); % Rain Link
yesKL = zeros(col,1); % Klino Link
yesKLHR = zeros(col,1); % Klino Link HR
yesThL = zeros(col,1); % Therm Link
yesPT100 = zeros(col,1); % PT100 link
yesIPL = zeros(col,1); % In Place Link
yesIPLHR = zeros(col,1); % In Place Link HR
yesTuL = zeros(col,1); % Tunnel Link 
yesRaL = zeros(col,1); % Radial Link 
yesPCL = zeros(col,1); % Preconv Link 
yesPCLHR = zeros(col,1); % Preconv Link HR
yesPrL = zeros(col,1); % Pressure Link
yesEL = zeros(col,1); % Extensometer Link
yes3DEL = zeros(col,1); % 3D Extensometer Link
yesWEL = zeros(col,1); % Wire Extensometer Link
yesMPBEL = zeros(col,1); % Multi Point BoreHole Extensometer Link
yesCrL = zeros(col,1); % Crack Link
yes2DCrL = zeros(col,1); % 2D Crack Link
yes3DCrL = zeros(col,1); % 3D Crack Link
yesBML = zeros(col,1); % Baro Musa Link
yesHL = zeros(col,1); % Humidity link
yesLuxL = zeros(col,1); % Lux link
yesCO2 = zeros (col,1); % CO2 Link
yesRSN = zeros (col,1); % RSN Link
yesRSNHR = zeros (col,1); % RSN Link HR
yesTrL = zeros (col,1); % Trigger Link
yesSM = zeros (col,1); % Stress Meter
yesPE = zeros(col,1); % Pendulum
yesWL = zeros(col,1); % Weir Link
yesGF = zeros(col,1); % G-Flow Link
yesGS = zeros(col,1); % G-Shock Link

% Numero di nodi per catena
rTL = zeros(col,1);
rTLHR = zeros(col,1);
rTLH = zeros(col,1);
rTLHRH = zeros(col,1);
rPL = zeros(col,1);
rBL = zeros(col,1);
rLL = zeros(col,1);
rRL = zeros(col,1);
rKL = zeros(col,1);
rKLHR = zeros(col,1);
rThL = zeros(col,1);
rPT100 = zeros(col,1);
rIPL = zeros(col,1);
rIPLHR = zeros(col,1);
rTuL = zeros(col,1); 
rRaL = zeros(col,1); 
rPCL = zeros(col,1);
rPCLHR = zeros(col,1);
rPrL = zeros(col,1);
rEL = zeros(col,1);
r3DEL = zeros(col,1);
rWEL = zeros(col,1);
rMPBEL = zeros(col,1);
rCrL = zeros(col,1);
r3DCrL = zeros(col,1);
rBML = zeros(col,1);
rHL = zeros(col,1);
rLuxL = zeros(col,1);
rCO2 = zeros(col,1);
rRSN = zeros(col,1);
rRSNHR = zeros(col,1);
rTrL = zeros(col,1);
rSM = zeros(col,1);
r2DCrL = zeros(col,1);
rPE = zeros(col,1);
rWL = zeros(col,1);
rGF = zeros(col,1);
rGS = zeros(col,1);

indice = 1;
[rCS,cCS] = size(Chain_Scheme);
for ii = 1:rCS
    for jj = 1:cCS
        if isempty(cell2mat(Chain_Scheme(ii,jj))) == 1
            Chain_Scheme{ii,jj} = 0;
        end
    end
end
Chain_Scheme = cell2mat(Chain_Scheme);
NodoTiltLink = [];
NodoTiltLinkHR = [];
NodoTiltLinkH = [];
NodoTiltLinkHRH = [];
NodoPiezoLink = [];
NodoBaroLink = [];
NodoLoadLink = [];
NodoRainLink = [];
NodoKlinoLink = [];
NodoKlinoLinkHR = [];
NodoThermLink = [];
NodoPT100Link = [];
NodoInPlaceLink = [];
NodoInPlaceLinkHR = [];
NodoTunnelLink = [];
NodoRadialLink = [];
NodoPreConvLink = [];
NodoPreConvLinkHR = [];
NodoPressureLink = [];
NodoExtensometerLink = [];
Nodo3DExtensometerLink = [];
NodoWireExtensometerLink = [];
NodoMultiPointExtensometerLink = [];
NodoCrackLink = [];
Nodo3DCrackLink = [];
NodoBaroMusaLink = [];
NodoHumidityLink = [];
NodoLuxLink = [];
NodoCO2Link = [];
NodoRSNLink = [];
NodoRSNHRLink = [];
NodoTriggerLink = [];
NodoStressMeter = [];
Nodo2DCrackLink = [];
NodoPendulum = [];
NodoWeirLink = [];
NodoGflowLink = [];
NodoGshockLink = [];
for a = 1:col % Array
    nTL = 1;
    nTLHR = 1;
    nTLH = 1;
    nTLHRH = 1;
    nPL = 1;
    nBL = 1;
    nLL = 1;
    nRL = 1;
    nKL = 1;
    nKLHR = 1;
    nThL = 1;
    nPT100 = 1;
    nIPL = 1;
    nIPLHR = 1;
    nTuL = 1;
    nRaL = 1;
    nPCL = 1;
    nPCLHR = 1;
    nPrL = 1;
    nEL = 1;
    n3DEL = 1;
    nWEL = 1;
    nMPBEL = 1;
    nCrL = 1;
    n3DCrL = 1;
    nBML = 1;
    nHL = 1;
    nLuxL = 1;
    nCO2 = 1;
    nRSN = 1;
    nRSNHR = 1;
    nTrL = 1;
    nSM = 1;
    n2DCrL = 1;
    nPenL = 1;
    nWL =1;
    nGF = 1;
    nGS = 1;
    
    for b = 1:num_nodi(a) % Numero di nodi dell'Array
        if Chain_Scheme(b,indice) == 1 % Tilt Link V
            yesTL(a) = 1;
            NodoTiltLink(nTL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nTL = nTL+1;
        elseif Chain_Scheme(b,indice) == 5 % Tilt Link HR V
            yesTLHR(a) = 1;
            NodoTiltLinkHR(nTLHR,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nTLHR = nTLHR+1;
        elseif Chain_Scheme(b,indice) == 11 % Tilt Link H
            yesTLH(a) = 1;
            NodoTiltLinkH(nTLH,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nTLH = nTLH+1;
        elseif Chain_Scheme(b,indice) == 12 % Tilt Link HR H
            yesTLHRH(a) = 1;
            NodoTiltLinkHRH(nTLHRH,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nTLHRH = nTLHRH+1;
        elseif Chain_Scheme(b,indice) == 2 % Piezo Link
            yesPL(a) = 1;
            NodoPiezoLink(nPL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nPL = nPL+1;
        elseif Chain_Scheme(b,indice) == 3 % Baro Link
            yesBL(a) = 1;
            NodoBaroLink(nBL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nBL = nBL+1;
        elseif Chain_Scheme(b,indice) == 15 % Load Link
            yesLL(a) = 1;
            NodoLoadLink(nLL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nLL = nLL+1;
        elseif Chain_Scheme(b,indice) == 27 % Rain Link
            yesRL(a) = 1;
            NodoRainLink(nRL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nRL = nRL+1;
        elseif Chain_Scheme(b,indice) == 26 % Klino Link
            yesKL(a) = 1;
            NodoKlinoLink(nKL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nKL = nKL+1;
        elseif Chain_Scheme(b,indice) == 44 % Klino Link HR
            yesKLHR(a) = 1;
            NodoKlinoLinkHR(nKLHR,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nKLHR = nKLHR+1;
        elseif Chain_Scheme(b,indice) == 4 % Therm Link
            yesThL(a) = 1;
            NodoThermLink(nThL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nThL = nThL+1;
        elseif Chain_Scheme(b,indice) == 28 % PT100 Link
            yesPT100(a) = 1;
            NodoPT100Link(nPT100,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nPT100 = nPT100+1;
        elseif Chain_Scheme(b,indice) == 42 % In Place Link
            yesIPL(a) = 1;
            NodoInPlaceLink(nIPL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nIPL = nIPL+1;
        elseif Chain_Scheme(b,indice) == 43 % In Place Link HR
            yesIPLHR(a) = 1;
            NodoInPlaceLinkHR(nIPLHR,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nIPLHR = nIPLHR+1;
        elseif Chain_Scheme(b,indice) == 17 % Tunnel Link
            yesTuL(a) = 1;
            NodoTunnelLink(nTuL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nTuL = nTuL+1;
        elseif Chain_Scheme(b,indice) == 18 % Radial Link
            yesRaL(a) = 1;
            NodoRadialLink(nRaL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nRaL = nRaL+1;
        elseif Chain_Scheme(b,indice) == 23 % PreConv Link
            yesPCL(a) = 1;
            NodoPreConvLink(nPCL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nPCL = nPCL+1;
        elseif Chain_Scheme(b,indice) == 24 % PreConv Link HR
            yesPCLHR(a) = 1;
            NodoPreConvLinkHR(nPCLHR,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nPCLHR = nPCLHR+1;
        elseif Chain_Scheme(b,indice) == 21 % Pressure Link
            yesPrL(a) = 1;
            NodoPressureLink(nPrL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nPrL = nPrL+1;
        elseif Chain_Scheme(b,indice) == 16 % Extensometer Link
            yesEL(a) = 1;
            NodoExtensometerLink(nEL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nEL = nEL+1;
        elseif Chain_Scheme(b,indice) == 19 % 3D Extensometer Link
            yes3DEL(a) = 1;
            Nodo3DExtensometerLink(n3DEL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            n3DEL = n3DEL+1;
        elseif Chain_Scheme(b,indice) == 22 % Wire Extensometer Link
            yesWEL(a) = 1;
            NodoWireExtensometerLink(nWEL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nWEL = nWEL+1;
        elseif Chain_Scheme(b,indice) == 25 % Multi Point Borehole Extensometer Link
            yesMPBEL(a) = 1;
            NodoMultiPointExtensometerLink(nMPBEL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nMPBEL = nMPBEL+1;
        elseif Chain_Scheme(b,indice) == 36 % Crack Link
            yesCrL(a) = 1;
            NodoCrackLink(nCrL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nCrL = nCrL+1;
        elseif Chain_Scheme(b,indice) == 37 % 3D Crack Link
            yes3DCrL(a) = 1;
            Nodo3DCrackLink(n3DCrL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            n3DCrL = n3DCrL+1;
        elseif Chain_Scheme(b,indice) == 41 % Baro Musa Link
            yesBML(a) = 1;
            NodoBaroMusaLink(nBML,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nBML = nBML+1;
        elseif Chain_Scheme(b,indice) == 35 % Humidity Link
            yesHL(a) = 1;
            NodoHumidityLink(nHL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nHL = nHL+1;
        elseif Chain_Scheme(b,indice) == 34 % Lux Link
            yesLuxL(a) = 1;
            NodoLuxLink(nLuxL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nLuxL = nLuxL+1;
        elseif Chain_Scheme(b,indice) == 33 % CO2 Link
            yesCO2(a) = 1;
            NodoCO2Link(nCO2,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nCO2 = nCO2+1;
        elseif Chain_Scheme(b,indice) == 38 % RSN Link
            yesRSN(a) = 1;
            NodoRSNLink(nRSN,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nRSN = nRSN+1;
        elseif Chain_Scheme(b,indice) == 39 % RSN Link HR
            yesRSNHR(a) = 1;
            NodoRSNHRLink(nRSNHR,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nRSNHR = nRSNHR+1;
        elseif Chain_Scheme(b,indice) == 40 % Trigger Link
            yesTrL(a) = 1;
            NodoTriggerLink(nTrL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nTrL = nTrL+1;
        elseif Chain_Scheme(b,indice) == 47 % Stress Meter
            yesSM(a) = 1;
            NodoStressMeter(nSM,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nSM = nSM+1;
        elseif Chain_Scheme(b,indice) == 51 % 2D Crack Link
            yes2DCrL(a) = 1;
            Nodo2DCrackLink(n2DCrL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            n2DCrL = n2DCrL+1;
        elseif Chain_Scheme(b,indice) == 52 % Pendulum
            yesPE(a) = 1;
            NodoPendulum(nPenL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nPenL = nPenL+1;
        elseif Chain_Scheme(b,indice) == 53 % Weir Link
            yesWL(a) = 1;
            NodoWeirLink(nWL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nWL = nWL+1;
        elseif Chain_Scheme(b,indice) == 48 % G-Flow Link
            yesGF(a) = 1;
            NodoGflowLink(nWL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nGF = nGF+1;
        elseif Chain_Scheme(b,indice) == 50 % G-Shock Link
            yesGS(a) = 1;
            NodoGshockLink(nWL,a) = Chain_Scheme(b,indice+2); % Ogni colonna riporta i nodi di un array
            nGS = nGS+1;
        end
    end
    indice = indice+3;
    rTL(a) = nTL-1;
    rTLHR(a) = nTLHR-1;
    rTLH(a) = nTLH-1;
    rTLHRH(a) = nTLHRH-1;
    rPL(a) = nPL-1;
    rBL(a) = nBL-1;
    rLL(a) = nLL-1;
    rRL(a) = nRL-1;
    rKL(a) = nKL-1;
    rKLHR(a) = nKLHR-1;
    rThL(a) = nThL-1;
    rPT100(a) = nPT100-1;
    rIPL(a) = nIPL-1;
    rIPLHR(a) = nIPLHR-1;
    rTuL(a) = nTuL-1;
    rRaL(a) = nRaL-1;
    rPCL(a) = nPCL-1;
    rPCLHR(a) = nPCLHR-1;
    rPrL(a) = nPrL-1;
    rEL(a) = nEL-1;
    r3DEL(a) = n3DEL-1;
    rWEL(a) = nWEL-1;
    rMPBEL(a) = nMPBEL-1;
    rCrL(a) = nCrL-1;
    r3DCrL(a) = n3DCrL-1;
    rBML(a) = nBML-1;
    rHL(a) = nHL-1;
    rLuxL(a) = nLuxL-1;
    rCO2(a) = nCO2-1;
    rRSN(a) = nRSN-1;
    rRSNHR(a) = nRSNHR-1;
    rTrL(a) = nTrL-1;
    rSM(a) = nSM-1;
    r2DCrL(a) = n2DCrL-1;
    rPE(a) = nPenL-1;
    rWL(a) = nWL-1;
    rGF(a) = nGF-1;
    rGS(a) = nGS-1;
end

text = 'info_Sito function executed correctly';
fprintf(fileID,fmt,text);
fclose(fileID);

end