public XCellAND CreateAnXCellANDGivenItsIDInTemporalList(string id)
        {
            if (string.IsNullOrEmpty(id))
            {
                return(null);
            }

            var xCellAND = new XCellAND(id, this);

            xCellAND.AssignLevel();
            ListOfXCellsAND.Add(xCellAND);
            if (xCellAND.ListOfOutputChannels.Count() == 0)
            {
                xCellAND.ListOfOutputChannels.Add(new Channel {
                    XCellOrigin = xCellAND
                });
            }
            //LayerUp.ListOfInputChannels.Add(xCellAND.ListOfOutputChannels[0]);

            TemporalListOfXCellsANDGroupedByLevels.TryGetValue(xCellAND.Li, out var listOfXCellsANDGroupedByLevels);
            if (listOfXCellsANDGroupedByLevels == null)
            {
                var listXCellAND = new List <XCellAND>();
                listXCellAND.Add(xCellAND);
                TemporalListOfXCellsANDGroupedByLevels.Add(xCellAND.Li, listXCellAND);
            }
            else
            {
                listOfXCellsANDGroupedByLevels?.Add(xCellAND);
            }
            return(xCellAND);
        }
        public XCellAND CreateAnXCellANDGivenItsID(string id)
        {
            if (string.IsNullOrEmpty(id))
            {
                return(null);
            }

            var xCellAND = new XCellAND(id, this);

            xCellAND.AssignLevel();
            ListOfXCellsAND.Add(xCellAND);
            if (xCellAND.ListOfOutputChannels.Count() == 0)
            {
                xCellAND.ListOfOutputChannels.Add(new Channel {
                    XCellOrigin = xCellAND
                });
            }
            LayerUp.ListOfInputChannels.Add(xCellAND.ListOfOutputChannels[0]);
            return(xCellAND);
        }