Points to consider while developing regression suite for CAD Projects

As the development of software makes its progress, there comes a stage where it needs to be evaluated before concluding it as the final output. This phase is usually known as testing. Testing detects and pinpoints the bugs and errors in the software, which eventually leads to rectification measures. There are instances where the rectifications bring in new errors, thus sending it back to another round of testing, hence creating a repeating loop. This repeated testing of an already tested application to detect errors resulting from changes has a term — Regression Testing.

Regression testing is the selective retesting of an application to ensure that modifications carried out has not caused unintended effects in the previously working application.

In simple words, to ensure all the old functionalities are still running correctly with new changes.

This is a very common step in any software development process by testers. Regression testing is required in the following scenarios:

  • If the code is modified owing to changes in requirements
  • If a new functionality is added
  • While rectifying errors
  • While fixing performance related issues

Although, every software application requires regression testing, there are specific points that apply to different applications, based on their functioning and utility. Computer-Aided design or CAD software applications require specific points to keep in mind before undergoing regression testing.

Regression testing can be broadly classified into two categories, UI Testing and Functionality Testing. UI testing stands for User Interface which is basically testing an applications graphical interface. Numerous testing tools are available for carrying out UI testing. However, functional testing presents situation for us. This content focuses on the points to take care while carrying out functional regression testing.

Here are most effective points to consider for functional regression testing:

  • It is important to know what exactly needs to be tested and the plans or procedures for the testing. Collect the information and test the critical things first.
  • It is important to be aware of market demands for product development. Document or matrix should be prepared to link the product to the requirement and to the test cases. Matrices should be modified as per the changes in requirement.
  • Include the test cases for functionalities which have undergone more and recent changes.
    It’s difficult to keep writing (modifying) test cases, as the application keeps on getting updated often, which leads to some internal defects and changes into the code which in turn might break some already existing functionalities.
  • It is preferred to run the functionality testing in the background mode (non-UI mode) because often it is faster and eliminates problems associated with display settings on different machines.
  • One needs to lay down precise definitions of the output parameters that are of interest. Anything from the number of faces, surface area, volume, weight, centre of gravity, surface normal, curvature at a particular point etc. It is always a good idea to have a quantifiable output parameter that can be compared.
  • It is often advisable to develop a utility to write the parameters that are of interest in an output file it could be text, CSV or xml file.
  • Creating baseline versions of output data files is a good idea to visually see every part for which the baseline data is created.
  • Developing automation script enables the entire test suite to run without any manual intervention and the results can be compared.
  • Compare the output data generated with the baseline version, for every run of test case, for it is very important to keep in mind that if there are doubles or floats in the output data, tolerance plays a very important role.
  • Some areas in the application are highly prone to errors; so much that they usually fail with even a minute change in code. It is advisable to keep a track of failing test cases and cover them in regression test suite.

Failure to address performance issues can hamper the functionality and success of your application, with unwelcome consequences for end users if your application doesn’t perform to expectations.

Read More

The Reverse Engineering process

Sometimes, situations arise where you don’t have access to a part’s original design documentation from its original production. This might be due to the absence of the original manufacturer altogether or stoppage on the production itself.

Reverse engineering empowers us to analyze a physical part and explore how it was originally built to replicate, create variations, or improve on the design. The goal is to ultimately create a new CAD model for use in manufacturing.

Let us take a look at the steps involved in reverse engineering. Commonly, it involves careful executions of the following steps:

  • Scanning

The first step involves using a 3D scanner for collecting the geometric measurements and dimensions of the existing part quickly and accurately using projected light patterns and camera system. Generally, the types of scanners used for such execution are blue light scanner, white light scanner, CT scanner and /or laser scanner. The former two captures the outward dimension and measurements while the latter two is capable of scanning the entire inside out.

  • Point Cloud

Once a certain part is scanned, the data gets transformed in the form of point clouds. Point cloud is a 3D visualization consisting of thousands or even millions of points. Point clouds define the shape of a physical system.

  • Meshing/Triangulation

This stage serves involves conversion of point clouds to mesh (STL or Stereolithographic format). Mesh generation is the practice of converting the given set of points into a consistent polygonal model that generates vertices, edges and faces that only meet at shared edges. Common software tools used to merge point clouds are Polyworks, Geomagic, ImageWare, MeshLab. The meshed part is then run for alignment in the mentioned software tools.

  • Parametric/Non-parametric Modeling

After the meshed part is aligned, it goes through either of two stages. The first option involves applying surface modeling on meshed part in tools such as Polyworks. It results in the generation of non-parametric model (IGES or STEP format). An alternate option is creating a sketch of the meshed part instead of putting it through surfacing. This work-process is known as parametric modeling (.PRT format). For a non parametric model, predicting future data is based on not just the parameters but also in the current state of data that has been observed. For a parametric model to predict new data, knowing just the parameters is enough.

  • CAD Modeling

The next stage consists of transferring the data through CAD software tools such as NX, Catia, Solidworks, Creo etc, for applying functions such as ‘stitch’, ‘sew’, ‘knit’, ‘trim’, ‘extrude’, ‘revolve’ etc for creation of 3D CAD model.

  • Inspection

This stage includes visual computer model inspections and alignment of the merged models against actual scanned parts (STL) for any discrepancies in the geometry as well as dimensions. Generally, inspection is carried out by using tools such as Polyworks or Geomagic. Reverse engineering inspection provides sufficient information to check tolerances, dimensions and other information relevant to the project.

  • Documentation

Documentation of 3D stage model depends solely on one’s technical/business requirements. This step is about converting 3D model to 2D sketch, usually with the help of tools such as inventor or Isodraw/Coraldraw, citing measurements which can be used for reference in the future.

 

Read More

Types of Geometric Modeling

The previous edition gave a brief introduction of Geometric Modeling and its features. Geometric modeling is the mathematical representation of an object’s geometry. It incorporates the use of curves to create models. It can be viewed either in 2D or 3D perspective.

This edition details the primary types of geometric modeling. Geometric modeling can be classified into the following:

SOLID MODELING

Also known as volume modeling, this is the most widely used method as it provides a complete description of solid modeling. Solid modeling defines an object by its nodes, edges, and surfaces;  therefore, it gives a perfect and explicit mathematical representation of a precisely enclosed and filled volume. Solid modeling requires the use of topology rules to guarantee that all surfaces are stitched together correctly. This geometry modeling procedure is based upon the “Half-Space” concept.

 

Solid Modeling

 

There are two prevalent ways for representing solid models –

Constructive solid geometry: Constructive solid geometry is a combination of primary solid objects (prism, cylinder, cone, sphere, etc.). These shapes are either added or deleted to form the final solid shape.

Boundary representation: In boundary representation, an object’s definition is determined by their spatial boundaries. It describes the points, edges, surfaces of a volume, and issues command to rotate, sweep a binds facets into a third dimensional solid. The union of these surfaces enables the formation of a surface that explicitly encloses a volume.

Solid Modeling is the most widely used geometric modeling in three dimensions, and it serves the following purpose:

  • Solid modeling supports weight or volume calculation, centroids, moments of inertia calculation, stress analysis, heat conduction calculations, dynamic analysis, system dynamics analysis.
  • Solid modeling supports the generation of codes, robotic and assembly simulation
  • Solid modeling stores both geometric and topological information; can verify if the two objects occupy same space
  • Solid modeling improves the quality of design, enhances visualization, and has the potential for functional automation and integration.

 Different solid modeling techniques are as follows:

  • Constructive Solid Geometry
  • Boundary Representation
  • Feature-based modeling
  • Primitive Instancing
  • Cell decomposition, spatial enumeration, octree
SURFACE MODELING

Surface modeling represents the solid appearing object. Although it is a complicated method of representation than wireframe modeling, it is not as refined as solid modeling. Although surface models and solid models look identical, the former cannot be sliced open the way solid models can be. This model makes use of B-splines and Bezier for controlling curves.

 

 

Surface Modeling

 

 

A typical surface modeling process involves the following steps:

  •  Generation of a model combining the three-dimensional surfaces and solids
  • Conversion of the model to surfaces, taking advantage of associative modeling
  • Validation of imperfections with surface analysis tools
  • Reconstructing surfaces of objects to apply smoothness to the object

Surface modeling is used to:

  • To shape design and representation of complicated objects such as a car, ship, and airplane bodies as well as castings
  • There are situations where models imported from another CAD system usually lack details of the features it is comprised of. If the surfaces are complex, applying changes to this type of geometry can be quite the task. In such cases, surface modeling techniques can be used to one or more faces of the model to make the desired changes.
  • Surface modeling enables building one face at a time so that one can control the exact contour and direction of any face. This feature comes in handy at a time when solid modeling technique fails to create the complex shape of a feature as it builds up several sides of shape at once.
  • As it is not limited to the direct construction of a model face, surfaces can also be used as a reference geometry in a transitional step towards the creation of the required model face.
  • Now, there is another modeling technique which requires a combination of solid and surface modeling techniques to create a solid model. This technique generally involves starting the model as a solid and using surfaces to modify it. Or, changing the solid to surfaces to shape and contour it, then turning it back to a solid when done.
WIREFRAME MODELING

The wireframe model is perhaps one of the earliest ways of representing a solid model. It consists of vertices and lines and is a skeletal representation of a real-world 3D object. It was developed back in the 1960s; it is also referred to as “Stick figure” or “edge representation.”

 

Wireframe Modeling

 

The lines within a wireframe connect to create polygons, such as triangles and rectangles, that represent three-dimensional shapes when bound together. The outcome may range from a cube to a complex three-dimensional scene with people and objects. The number of polygons within a model is a good indicator of how detailed the wireframe 3D model is.

Wireframe modeling helps in matching a 3D drawing model to its reference. It allows the creator to match the vertex points, so they are in alignment with the desired reference and see the reference through the model as well. Although Wireframe modeling is a quick and easy way to demonstrate concepts, creating a fully detailed, precisely constructed model for an idea can be extremely time-consuming, and if it does not match what was visualized for the project, all that time and effort was wasted. In wireframe modeling, one can skip the detailed work and present a very skeletal framework that is simple to create and is apprehensible to others.

Read More

What is Digital Image Processing

Previously we have learned what visual inspection is and how it helps in inspection checks and quality assurance of manufactured products. The task of vision-based inspection implements a specific technological aspect with the name of Image Processing.

Image processing is a technique to carry out a particular set of actions on an image for obtaining an enhanced image or extracting some valuable information from it.

It is a sort of signal processing where the input is an image, and output may be an improved image or characteristics/features associated with the same. Over the years, image processing has become one of the most rapidly growing technologies within engineering and even the computer science sector too.

Image processing consists of these three following steps:

  • Importing the image via image capturing tools;
  • Manipulating and analyzing the image;
  • Producing a result where the output can be an altered image or report that is based on image analysis.

Image processing includes the two types of method: 

Analogue Image Processing: Generally, analogue image processing is used for hard copies like photographs and printouts. Image analysts use various facets of interpretation while using these visual techniques.

Digital image processing: Digital image processing methods help in the manipulation and analysis of digital images. The three general steps that all types of data have to undergo while using digital image processing techniques are -  pre-processing, enhancement, and information extraction.

This article discusses primarily digital image processing techniques and various phases.

 

Image processing

 

Digital Image Processing and different phases

Digital image processing requires digital computers to convert images into digital form using digital conversion method and then process it. It is about subjecting various numerical depictions of images to a series of operations to obtain the desired result. The primary advantages of Digital Image Processing methods lie in its versatility, repeatability and the preservation of original data.

Main techniques of digital image processing are as follows:

  • Image Editing: It means changing/altering digital images with the use of graphic software tools.
  • Image Restoration: It means processing a corrupt image and taking out a clean original image to get back the lost information.
  • Independent Component Analysis: It separates a variety of signals computationally into additive subcomponents.
  • Anisotropic Diffusion: This method enables reducing image noise without having to remove essential portions of the image.
  • Linear Filtering. It’s another digital image processing method, which is about processing time-varying input signals and generating output signals.
  • Neural Networks: Neural networks are the computational models used in machine learning for solving various tasks.
  • Pixelation: It is a method for turning printed images into digitized ones.
  • Principal Components Analysis: It is a digital image processing technique that is used for feature extraction.
  • Partial Differential Equations: This method refers to dealing with de-noising
  • Hidden Markov Models: This technique is used for image analysis in 2D (two dimensional).
  • Wavelets: Wavelets are the mathematical functions used in image compression.
  • Self-organizing Maps: a digital image processing technique that classifies images into several classes.

Image recognition technology has grown up to be of great potential for wide adoption in various industries. This technology has seen significant usage with each passing year, as enterprises have become more time-efficient and productive due to the incorporation of better manufacturing, inspection and quality assurance tools and processes. Big corporations and start-ups such as Tesla, Google, Uber, Adobe Systems, etc heavily use image processing techniques in their day to day operations. With the advancements in the field of AI (Artificial Intelligence), this technology will see significant upgrades in the coming years.

Read More

What is Mesh and what are the types of Meshing

For those acquainted with mechanical design and reverse engineering, they can testify to the fact that the road to a new product design involves several steps. In reverse engineering, the summary of the entire process involves scanning, point cloud generation, meshing, computer-aided designing, prototyping and final production. This section covers a very crucial part of the process — Meshing or simply put, Mesh.

To put a simple definition, a mesh is a network that constitutes of cells and points.

Mesh generation is the practice of converting the given set of points into a consistent polygonal model that generates vertices, edges and faces that only meet at shared edges. It can have almost any shape in any size. Each cell of the mesh represents an individual solution, which when combined, results in a solution for the entire mesh.

 

mesh

Mesh is formed of facets which are connected to each other topologically. The topology is created using following entities:

  • Facet - A triangle connecting three data points
  • Edge - A line connecting two data points
  • Vertex - A data point
Mesh Property

Before we proceed to know the types of meshes, it is necessary to understand the various aspects that constitute a mesh. It is important to know the concept of a polygonal mesh.

A polygon mesh is a collection of vertices, edges and faces that defines the shape of a polyhedral object in 3D graphics and solid modeling. The faces usually consist of triangles, quadrilaterals or other simple polygons as that simplifies rendering. It may also be composed of more general concave polygons or polygons with holes.

Objects created with polygon meshes must store different types of elements. These include:

  • Vertex: A position (usually in 3D space) along with other information such as color, normal vector and texture coordinates
  • Edge: A connection between two vertices
  • Face: A closed set of edges, in which a triangle face has three edges, and a quad face has four edges
  • Surfaces: They are often called smoothing groups. Generally, surfaces are not required to group smooth regions

A polygon mesh may be represented in a variety of ways, using different methods to store the vertex, edge and face data. These include:

  • Face-vertex meshes
  • Winged edge meshes
  • Corner tables
  • Vertex-vertex meshes
Types of meshes

Meshes are commonly classified into two divisions, Surface mesh and Solid mesh. Let us go through each section one by one.

Surface Mesh: A surface mesh is a representation of each individual surface constituting a volume mesh. It consists of faces (triangles) and vertices. Depending on the pre-processing software package, feature curves may be included as well.

Generally, a surface mesh should not have free edges and the edges should not be shared by two triangles.

The surface should ideally contain the following qualities of triangle faces:

  • Equilateral sized triangles
  • No sharp angles/surface folds etc. within the triangle proximity sphere
  • Gradual variation in triangle size from one to the next

The surface mesh generation process should be considered carefully. It has a direct influence on the quality of the resulting volume mesh and the effort it takes to get to this step.

surface mesh

Solid Mesh: Solid mesh, also known as volume mesh, is a polygonal representation of the interior volume of an object. There are three different types of meshing models that can be used to generate a volume mesh from a well prepared surface mesh.

The three types of meshing models are as follows:

  • Tetrahedral - tetrahedral cell shape based core mesh
  • Polyhedral - polyhedral cell shape based core mesh
  • Trimmed - trimmed hexahedral cell shape based core mesh

Once the volume mesh has been built, it can be checked for errors and exported to other packages if desired.

solid mesh

Mesh type as per Grid structure

A grid is a cuboid that covers entire mesh under consideration. Grid mainly helps in fast neighbor manipulation for a seed point.

mesh grid

Meshes can be classified into two divisions from the grid perspective, namely Structured and Unstructured mesh. Let us have a look at each of these types.

Structured Mesh: Structured meshes are meshes which exhibits a well-known pattern in which the cells are arranged. As the cells are in a particular order, the topology of such mesh is regular. Such meshes enable easy identification of neighboring cells and points, because of their formation and structure. Structured meshes are applied over rectangular, elliptical, spherical coordinate systems, thus forming a regular grid. Structured meshes are often used in CFD.

structured mesh

Unstructured Mesh: Unstructured meshes, as the name suggests, are more general and can randomly form any geometry shape. Unlike structured meshes, the connectivity pattern is not fixed hence unstructured meshes do not follow a uniform pattern. However, unstructured meshes are more flexible. Unstructured meshes are generally used in complex mechanical engineering projects.

Unstructured Mesh

Read More

Page 2 of 2