Example #1
0
        public void init()
        {
            var       path   = Path.Combine(Directory.GetCurrentDirectory(), "VTUInputTest.vtu");
            VTKreader reader = new VTKreader(@path);

            unstructuredGrid = reader.readFile();

            cellDataReader = new VTKCellDataReader();
        }
Example #2
0
        public void init()
        {
            var       path   = Path.Combine(Directory.GetCurrentDirectory(), "VTUInputTest.vtu");
            VTKreader reader = new VTKreader(@path);

            unstructuredGrid = reader.readFile();
            correctIDMapping = new VTKCorrectIDMapping(unstructuredGrid);
            elID             = new int[20];
            for (int i = 0; i < 20; i++)
            {
                elID[i] = i;
            }
        }
        public void init()
        {
            RedirectVTKOutput errorObserver = new RedirectVTKOutput();
            var       path   = Path.Combine(Directory.GetCurrentDirectory(), "VTUInputTest.vtu");
            VTKreader reader = new VTKreader(@path);

            unstructuredGrid = reader.readFile();
            fieldDataReader  = new VTKFieldDataReader(unstructuredGrid);
            allForcesBeam    = fieldDataReader.readAllForcesBeam(true, null);
            int[] elIDsBeam = new int[20];
            for (int i = 0; i < 20; i++)
            {
                elIDsBeam[i] = i;
            }
        }
Example #4
0
        public void init()
        {
            var       path   = Path.Combine(Directory.GetCurrentDirectory(), "FocusResults.vtu");
            VTKreader reader = new VTKreader(@path);

            unstructuredGrid = reader.readFile();
            correctIDMapping = new VTKCorrectIDMapping(unstructuredGrid);
            nodeID           = new int[21];
            for (int i = 0; i < 20; i++)
            {
                nodeID[i] = i;
            }

            nodeID[20] = 20;
        }
        public void init()
        {
            RedirectVTKOutput errorObserver = new RedirectVTKOutput();
            var       path   = Path.Combine(Directory.GetCurrentDirectory(), "VTUInputTest.vtu");
            VTKreader reader = new VTKreader(@path);

            unstructuredGrid = reader.readFile();
            pointReader      = new VTKPointReader();

            VTKPointDataReader pointDataReader = new VTKPointDataReader(unstructuredGrid);

            translation         = pointDataReader.readTranslation(true, null);
            rotationVector      = pointDataReader.readRotationVectors(true, null);
            extremeDisplacement = pointDataReader.ExtremeDisplacement;
        }
Example #6
0
        public void hasCorrectIDMappingFieldDataShoudlWritePropertyWithEigtheenAtSecondPosition()
        {
            var       path   = Path.Combine(Directory.GetCurrentDirectory(), "VTUInputTestWithDifferentelID.vtu");
            VTKreader reader = new VTKreader(@path);

            unstructuredGrid = reader.readFile();
            correctIDMapping = new VTKCorrectIDMapping(unstructuredGrid);
            elID             = new int[20];
            for (int i = 0; i < 20; i++)
            {
                elID[i] = i;
            }

            correctIDMapping.hasCorrectIDMapping("BeamIDs", elID);
            Assert.AreEqual(18, correctIDMapping.BeamIDsNonContiniusAcending[1]);
        }
Example #7
0
        public void hasCorrectIDMappingPointDataShoudlWritePropertyWithEigtheenAtSecondPosition()
        {
            var       path   = Path.Combine(Directory.GetCurrentDirectory(), "FocusResultsDifferentIDs.vtu");
            VTKreader reader = new VTKreader(@path);

            unstructuredGrid = reader.readFile();
            correctIDMapping = new VTKCorrectIDMapping(unstructuredGrid);
            nodeID           = new int[21];
            for (int i = 0; i < 21; i++)
            {
                nodeID[i] = i;
            }

            correctIDMapping.hasCorrectIDMapping("NodeIDs", nodeID);
            Assert.AreEqual(19, correctIDMapping.NodeIDsNonContiniusAcending[1]);
        }
Example #8
0
            public void init()
            {
                RedirectVTKOutput errorObserver = new RedirectVTKOutput();
                var       path   = Path.Combine(Directory.GetCurrentDirectory(), "VTUInputTest.vtu");
                VTKreader reader = new VTKreader(@path);

                unstructuredGrid = reader.readFile();

                cellReader = new VTKCellReader();
                vtkCells   = cellReader.readCells(unstructuredGrid);

                VTKCellDataReader cellDataReader = new VTKCellDataReader();

                allForcesBeams  = cellDataReader.readAllForcesBeam(unstructuredGrid);
                allFourcesShell = cellDataReader.readAllForcesShell(unstructuredGrid);
                maxForcesBeam   = cellDataReader.CalculateMaxForcesBeam;
                minForcesBeam   = cellDataReader.CalculateMinForcesBeam;
                maxForceShell   = cellDataReader.CalculateMaxForcesShell;
                minForcesShell  = cellDataReader.CalculateMinForcesShell;
            }