Types Of Computational Problems
Updated Jan 10, 20254 min read
Following are the some commonly known problem types:
Sorting
Searching
Graph problems
Combinatorial problems
Geometric problems
Numerical problems
Sorting:
The sorting is the process to arrange the given set of items in a certain order, assuming that the nature of the items allow such an ordering. For example, sorting a set of numbers in increasing or decreasing order and sorting the character strings, like names, in an alphabetical order.
For any sorting algorithm following two characteristics are desirable:
1. Stability
A sorting algorithm is called stable if it does not change the relative positions of any two equal items of the input list. Say, in an input list, there are two equal item sat positions i and j where i< j, then the final position of these items in the
sorted list should also be k and l respectively, such that k<l. That is there
should not be any swapping among these equal items and should not
interchange their position with each other.
2. In-place.
A sorting algorithm needs extra memory space to store elements during the swapping process. For a small set of items in a list, this constraint is not observable but, for an input list of large elements the required storage space is considerably large. An algorithm is said to be in-place if the required extra memory is not markable.
Searching:
Searching is finding an element, referred to as a search key, in a given set of items (may have the redundant value). Searching is one of the most important and frequently performed operations on any dataset/database.
String Processing:
String processing refers to techniques and operations performed on strings (sequences of characters) to extract, manipulate, or analyze textual data. It is a fundamental concept in programming and is used in various domains like data cleaning, natural language processing, pattern matching, and more.
Applications of String Processing
Text Parsing and Tokenization: Extracting meaningful components from a string.
Data Cleaning: Removing unwanted characters or formatting strings for uniformity.
Pattern Matching: Detecting and replacing patterns in strings using regular expressions.
Natural Language Processing (NLP): Analyzing and transforming textual data for AI/ML tasks.
Log Analysis: Extracting valuable insights from logs and text data.
Input Validation: Ensuring strings conform to expected formats (e.g., email validation).
Graph Problems:
Graph problems refer to a class of computational problems that involve graph data structures. A graph is a mathematical representation of a set of objects (called vertices or nodes) and the connections (called edges) between them. Graph problems are central to computer science and have applications in areas such as networking, social media, AI, logistics, and biology.
Applications of Graph Problems
Social Networks: Finding friends, influencers, or communities.
Transportation: Optimizing routes and traffic flow.
Telecommunications: Designing efficient networks.
Biology: Analyzing gene or protein interaction networks.
Project Management: Dependency resolution and scheduling.
Combinatorial Problems:
Combinatorial problems involve finding, counting, or optimizing arrangements, combinations, or subsets of discrete structures such as numbers, sets, or graphs. These problems arise in various fields, including mathematics, computer science, operations research, and optimization.
These types of problems have a combination of solutions i.e. more than one solution are possible. The aim of the combinatorial problems is to find permutations, combinations, or subsets, satisfying the given conditions. The travelling salesman problem, independent set and the graph-coloring problems can be categorized as examples of combinatorial problems.
Applications of Combinatorial Problems
Cryptography: Secure key generation.
Scheduling: Assigning tasks optimally to resources.
Game Theory: Analyzing possible strategies.
Logistics: Vehicle routing and packing problems.
Bioinformatics: DNA sequencing and protein folding.
Geometric Problems:
Geometric problems involve solving computational or mathematical challenges related to shapes, points, lines, angles, surfaces, and volumes in 2D or 3D spaces. These problems have applications in computer graphics, robotics, CAD, computational geometry, and more.
Following are widely known classic problems of computational geometry:
1. The closest-pair problem
The closest-pair problem is to find the closest pair out of a given set of points in the plane.
2. The convex-hull problem
In the convex-hull problem, the smallest convex polygon is to be constructed so that it includes all the points of a given set.
Applications of Geometric Problems
Computer Graphics: Rendering and modeling.
Robotics: Pathfinding and obstacle avoidance.
GIS: Geographic information systems for map analysis.
Physics: Collision detection in simulations.
Astronomy: Analyzing celestial object positions.
