Thursday, January 30, 2025

Software Engineering

 Software Engineering is the process of designing, developing, testing, and maintaining software. It is a systematic and disciplined approach to software development that aims to create high-quality, reliable, and maintainable software.

The term software engineering is the product of two words, software, and engineering. The software is a collection of integrated programs. Software subsists of carefully-organized instructions and code written by developers on any of various particular computer languages. Computer programs and related documentation such as requirements, design models and user manuals.

Engineering is the application of scientific and practical knowledge to invent, design, build, maintain, and improve frameworks, processes, etc.

Software engineering includes a variety of techniques, tools, and methodologies, including requirements analysis, design, testing, and maintenance. It is a rapidly evolving field, and new tools and technologies are constantly being developed to improve the software development process. By following the principles of software engineering and using the appropriate tools and methodologies, software developers can create high-quality, reliable, and maintainable software that meets the needs of its users. Software Engineering is mainly used for large projects based on software systems rather than single programs or applications.

The main goal of Software Engineering is to develop software applications for improving quality,  budget, and time efficiency. Software Engineering ensures that the software that has to be built should be consistent, correct, also on budget, on time, and within the required requirements. Software is the program that is required to work on the input, processing, output, storage and control.


Why is Software Engineering required?

  • To manage Large software
  • For more Scalability
  • Cost Management
  • To manage the dynamic nature of software
  • For better quality Management


Need of Software Engineering

The necessity of software engineering appears because of a higher rate of progress in user requirements and the environment on which the program is working.

Huge Programming: It is simpler to manufacture a wall than to a house or building, similarly, as the measure of programming become extensive engineering has to step to give it a scientific process.

Adaptability: If the software procedure were not based on scientific and engineering ideas, it would be simpler to re-create new software than to scale an existing one.

Cost: As the hardware industry has demonstrated its skills and huge manufacturing has let down the cost of computer and electronic hardware. But the cost of programming remains high if the proper process is not adapted.

Dynamic Nature: The continually growing and adapting nature of programming hugely depends upon the environment in which the client works. If the quality of the software is continually changing, new upgrades need to be done in the existing one.

Quality Management: Better procedure of software development provides a better and quality software product.


Types of Software

It can be categorized into different types:

  1. Based on Application
  2. Based on Copyright


1. Based on Application

The software can be classified on the basis of the application. These are to be done on this basis.

1. System Software:

System Software is necessary to manage computer resources and support the execution of application programs. Software like operating systems, compilers, editors and drivers, etc., come under this category. A computer cannot function without the presence of these. Operating systems are needed to link the machine-dependent needs of a program with the capabilities of the machine on which it runs. Compilers translate programs from high-level language to machine language. 

2. Application Software:

Application software is designed to fulfill the user’s requirement by interacting with the user directly. It could be classified into two major categories:- generic or customized. Generic Software is software that is open to all and behaves the same for all of its users. Its function is limited and not customized as per the user’s changing requirements. However, on the other hand, customized software is the software products designed per the client’s requirement, and are not available for all.  

3. Networking and Web Applications Software:

Networking Software provides the required support necessary for computers to interact with each other and with data storage facilities. Networking software is also used when software is running on a network of computers (such as the World Wide Web). It includes all network management software, server software, security and encryption software, and software to develop web-based applications like HTML, PHP, XML, etc. 

4. Embedded Software:

This type of software is embedded into the hardware normally in the Read-Only Memory (ROM) as a part of a large system and is used to support certain functionality under the control conditions. Examples are software used in instrumentation and control applications like washing machines, satellites, microwaves, etc. 

5. Reservation Software:

A Reservation system is primarily used to store and retrieve information and perform transactions related to air travel, car rental, hotels, or other activities. They also provide access to bus and railway reservations, although these are not always integrated with the main system. These are also used to relay computerized information for users in the hotel industry, making a reservation and ensuring that the hotel is not overbooked. 

6. Business Software:

This category of software is used to support business applications and is the most widely used category of software. Examples are software for inventory management, accounts, banking, hospitals, schools, stock markets, etc. 

7. Entertainment Software:

Education and Entertainment software provides a powerful tool for educational agencies, especially those that deal with educating young children. There is a wide range of entertainment software such as computer games, educational games, translation software, mapping software, etc.  

8. Artificial Intelligence Software:

Software like expert systems, decision support systems, pattern recognition software, artificial neural networks, etc. come under this category. They involve complex problems which are not affected by complex computations using non-numerical algorithms. 


2. Based on Copyright

Classification of Software can be done based on copyright. These are stated as follows:

1. Commercial Software:

It represents the majority of software that we purchase from software companies, commercial computer stores, etc. In this case, when a user buys software, they acquire a license key to use it. Users are not allowed to make copies of the software. The company owns the copyright of the program.

2. Shareware Software:

Shareware software is also covered under copyright, but the purchasers are allowed to make and distribute copies with the condition that after testing the software, if the purchaser adopts it for use, then they must pay for it. In both of the above types of software, changes to the software are not allowed. 

3. Freeware Software:

In general, according to freeware software licenses, copies of the software can be made both for archival and distribution purposes, but here, distribution cannot be for making a profit. Derivative works and modifications to the software are allowed and encouraged. Decompiling of the program code is also allowed without the explicit permission of the copyright holder.

4. Public Domain Software:

In the case of public domain software, the original copyright holder explicitly relinquishes all rights to the software. Hence, software copies can be made both for archival and distribution purposes with no restrictions on distribution. Modifications to the software and reverse engineering are also allowed.


Software Characteristics

Functionality:

It refers to the degree of performance of the software against its intended purpose. 

Functionality refers to the set of features and capabilities that a software program or system provides to its users. It is one of the most important characteristics of software, as it determines the usefulness of the software for the intended purpose. Examples of functionality in software include:

  • Data storage and retrieval
  • Data processing and manipulation
  • User interface and navigation
  • Communication and networking
  • Security and access control
  • Reporting and visualization
  • Automation and scripting

Reliability:

A set of attributes that bears on the capability of software to maintain its level of performance under the given condition for a stated period of time. 

Reliability is a characteristic of software that refers to its ability to perform its intended functions correctly and consistently over time. Reliability is an important aspect of software quality, as it helps ensure that the software will work correctly and not fail unexpectedly.


Examples of factors that can affect the reliability of software include:

  • Bugs and errors in the code
  • Lack of testing and validation
  • Poorly designed algorithms and data structures
  • Inadequate error handling and recovery
  • Incompatibilities with other software or hardware


Efficiency:

It refers to the ability of the software to use system resources in the most effective and efficient manner. The software should make effective use of storage space and executive command as per desired timing requirements. 

Efficiency is a characteristic of software that refers to its ability to use resources such as memory, processing power, and network bandwidth in an optimal way. High efficiency means that a software program can perform its intended functions quickly and with minimal use of resources, while low efficiency means that a software program may be slow or consume excessive resources.

Examples of factors that can affect the efficiency of the software include:

  • Poorly designed algorithms and data structures
  • Inefficient use of memory and processing power
  • High network latency or bandwidth usage
  • Unnecessary processing or computation
  • Unoptimized code


Usability:

It refers to the extent to which the software can be used with ease. the amount of effort or time required to learn how to use the software. 


Maintainability:

It refers to the ease with which modifications can be made in a software system to extend its functionality, improve its performance, or correct errors. 


Portability:

A set of attributes that bears on the ability of software to be transferred from one environment to another, without minimum changes. 


Software Development Life Cycle

Software Development Life Cycle (SDLC) is a well-defined, structured sequence of stages in software engineering to develop the intended software product.


Communication

This is the first step where the user initiates the request for a desired software product. The user contacts the service provider and tries to negotiate the terms, submits the request to the service providing organization in writing.

Requirement Gathering

This step onwards the software development team works to carry on the project. The team holds discussions with various stakeholders from problem domain and tries to bring out as much information as possible on their requirements. The requirements are contemplated and segregated into user requirements, system requirements and functional requirements. The requirements are collected using a number of practices as given –

• studying the existing or obsolete system and software,

• conducting interviews of users and developers,

• referring to the database or

• collecting answers from the questionnaires.

Feasibility Study

After requirement gathering, the team comes up with a rough plan of software process. At this step the team analyzes if a software can be designed to fulfill all requirements of the user, and if there is any possibility of software being no more useful. It is also analyzed if the project is financially, practically, and technologically feasible for the organization to take up. There are many algorithms available, which help the developers to conclude the feasibility of a software project.

System Analysis

At this step the developers decide a roadmap of their plan and try to bring up the best software model suitable for the project. System analysis includes understanding of software product limitations, learning system related problems or changes to be done in existing systems beforehand, identifying and addressing the impact of project on organization and personnel etc. The project team analyzes the scope of the project and plans the schedule and resources accordingly.

Software Design

Next step is to bring down whole knowledge of requirements and analysis on the desk and design the software product. 

The inputs from users and information gathered in requirement gathering phase are the inputs of this step. The output of this step comes in the form of two designs; logical design, and physical design. Engineers produce meta-data and data dictionaries, logical diagrams, data-flow diagrams, and in some cases pseudo codes.

Coding

This step is also known as programming phase. The implementation of software design starts in terms of writing program code in the suitable programming language and developing error-free executable programs efficiently.

Testing

An estimate says that 50% of whole software development process should be tested. Errors may ruin the software from critical level to its own removal. Software testing is done while coding by the developers and thorough testing is conducted by testing experts at various levels of code such as module testing, program testing, product testing, in-house testing, and testing the product at user’s end. Early discovery of errors and their remedy is the key to reliable software.

Integration

Software may need to be integrated with the libraries, databases, and other program(s). This stage of SDLC is involved in the integration of software with outer world entities.

Implementation

This means installing the software on user machines. At times, software needs post-installation configurations at user end. 

Software is tested for portability and adaptability and integration related issues are solved during implementation.

Operation and Maintenance

This phase confirms the software operation in terms of more efficiency and less errors. If required, the users are trained, or aided with the documentation on how to operate the software and how to keep the software operational. The software is maintained timely by updating the code according to the changes taking place in user end environment or technology. This phase may face challenges from hidden bugs and real-world unidentified problems.


Waterfall Model

Waterfall model is the simplest model of software development paradigm. All the phases of SDLC will function one after another in linear manner. That is, when the first phase is finished then only the second phase will start and so on.

This model assumes that everything is carried out and taken place perfectly as planned in the previous stage and there is no need to think about the past issues that may arise in the next phase. This model does not work smoothly if there are some issues left at the previous step. The sequential nature of model does not allow us to go back and undo or redo our actions.

Advantage:

This model is best suited when developers already have designed and developed similar software in the past and are aware of all its domains.

Drawback:

The sequential nature of model does not allow to go back and undo or redo the actions.


Iterative Model

This model leads the software development process in iterations. It projects the process of development  cyclic manner repeating every step after every cycle of SDLC process.

The software is first developed on very small scale and all the steps are followed which are taken into consideration. Then, on every next iteration, more features and modules are designed, coded, tested, and added to the software. Every cycle produces a software, which is complete in itself and has more features and capabilities than that of the previous one.

After each iteration, the management team can do work on risk management and prepare for the next iteration. Because a cycle includes small portion of whole software process, it is easier to manage the development process but it consumes more resources.

Advantage:

Because a cycle includes small portion of whole software process, it is easier to manage the development process.

Drawback:

Since more features are added to the software on every iteration, it consumes more resources.


Spiral Model

Spiral model is a combination of both, iterative model and one of the SDLC model. It can be seen as if you choose one SDLC model and combined it with cyclic process (iterative model).

This model considers risk, which often goes un-noticed by most other models. The model starts with determining objectives and constraints of the software at the start of one iteration. Next phase is of prototyping the software. This includes risk analysis. Then one standard SDLC model is used to build the software. In the fourth phase of the plan of next iteration is prepared.

Advantage:

1. Additional functionality or changes can be done at the later stage

2. Cost Estimation becomes easy Drawback:

1. Not advisable for smaller projects, as it might cost more

2. Demands Risk assessment expertise



V – model

The V-model is a type of SDLC model where process executes in a sequential manner in V-shape.

The major drawback of waterfall model is we move to the next stage only when the previous one is finished and there was no chance to go back if something is found wrong in later stages. V-Model provides means of testing of software at each stage in reverse manner.

At every stage, test plans and test cases are created to verify and validate the product according to the requirement of that stage. For example, in requirement gathering stage the test team prepares all the test cases in correspondence to the requirements. Later, when the product is developed and is ready for testing, test cases of this stage verify the software against its validity towards requirements at this stage.

This makes both verification and validation go in parallel. This model is also known as verification and validation model.

Advantage:

1. Each phase has specific deliverables.

2. Works well for small projects where requirements are easily understood.

3. Utility of the resources is high.

Drawback:

1. Very rigid, like the waterfall model.

2 Little flexibility and adjusting scope is difficult and expensive.



Thursday, January 23, 2025

Blockchain Technology

 


Blockchain is a decentralized distributed database (ledger) of immutable records accessed by various business applications over the network. Client applications of related businesses can read or append transaction records to the blockchain. Transaction records submitted to any node are validated and committed to the ledger database on all the nodes of blockchain network. Committed transactions are immutable because each block is linked with its previous block by means of hash and signature values. Protocols such as Gossip and Consensus ensure that the submitted transactions are transferred to all nodes and committed on all blockchain nodes consistently.

Blockchain ecosystem consists of blockchain client, blockchain node, blockchain network, transaction processor and consensus process.


Blockchain client is an application that creates transaction message in a prescribed format and submits it to blockchain node through web API. It may be any existing application, which posts transaction message to blockchain node. Clients are restricted using Public Key Infrastructure (PKI) technology at blockchain node level.

Blockchain node is a server node that runs blockchain services responsible for receiving the transaction and transmits the transaction to other blockchain nodes. With respect to the design, the node participates in consensus process to commit the block of transaction data to ledger database.

Blockchain network is a network of linked nodes used for read, write transactions into ledger database. The topology is based on the nodes participating in consensus process. Traditional systems are centralized where all data and decision-making is concentrated on a single node or cluster of nodes. In decentralized systems, the data and decision-making are spread out among a large number of nodes. These nodes maintain copies of the shared database and decide among themselves which data is to be committed to the database using consensus mechanism. Decentralized networks can be an interconnection of centralized or hub-and-spoke type networks. A distributed network is a special case of decentralized system where every single node in the network maintains the shared database and participates in consensus to determine which data is to be committed to the database.

There are at  types of blockchain networks 


  • public blockchains, 
  • private blockchains, 
  • consortium blockchains and 
  • hybrid blockchains.

Public blockchains

A public blockchain has absolutely no access restrictions. Anyone with an Internet connection can send transactions to it as well as become a validator (i.e., participate in the execution of a consensus protocol). Usually, such networks offer economic incentives for those who secure them and utilize some type of a proof-of-stake or proof-of-work algorithm.

Some of the largest, most known public blockchains are the bitcoin blockchain and the Ethereum blockchain.

Private blockchains

A private blockchain is permissioned. One cannot join it unless invited by the network administrators. Participant and validator access is restricted. To distinguish between open blockchains and other peer-to-peer decentralized database applications that are not open ad-hoc compute clusters, the terminology Distributed Ledger (DLT) is normally used for private blockchains.

Hybrid blockchains

A hybrid blockchain has a combination of centralized and decentralized features. The exact workings of the chain can vary based on which portions of centralization and decentralization are used.

Sidechains

A sidechain is a designation for a blockchain ledger that runs in parallel to a primary blockchain. Entries from the primary blockchain (where said entries typically represent digital assets) can be linked to and from the sidechain; this allows the sidechain to otherwise operate independently of the primary blockchain (e.g., by using an alternate means of record keeping, alternate consensus algorithm, etc.).

Consortium blockchain

A consortium blockchain is a type of blockchain that combines elements of both public and private blockchains. In a consortium blockchain, a group of organizations come together to create and operate the blockchain, rather than a single entity. The consortium members jointly manage the blockchain network and are responsible for validating transactions. Consortium blockchains are permissioned, meaning that only certain individuals or organizations are allowed to participate in the network. This allows for greater control over who can access the blockchain and helps to ensure that sensitive information is kept confidential.


Bitcoin and blockchain are not the same. Blockchain provides the means to record and store bitcoin transactions, but blockchain has many uses beyond bitcoin. Bitcoin is only the first use case for blockchain.


Proof of work

  • A proof of work is a piece of data which is difficult (costly, time consuming) to produce but easy for others to verify and which satisfies certain requirements.
  • In order for a block to be accepted by network participants, miner must complete a proof of work which covers all of the data in the block.
  • The difficulty of this work is adjusted so as to limit the rate at which new blocks can be generated by the network to one every 10 minutes.
  • Due to the very low probability of successful generation, this makes it unpredictable which worker computer in the network will be able to generate the next block.


Ethereum

  • Functions as a platform through which people can use tokens to create and run applications and create smart contracts
  • Ethereum allows people to connect directly through powerful decentralized super computer
  • Language- Solidity
  • Currency- Ether
  • Uses- POS


Smart Contracts

• A smart contract is an agreement or set of rules that govern a business transaction;

• It’s stored on the blockchain and is executed automatically as part of a transaction

• Their purpose is to provide security superior to traditional contract law while reducing the costs and delays associated with traditional contracts.


Hyperledger 

  • Hyperledger is an open source collaborative effort created to advance cross-industry blockchain technologies. 
  • It is a global collaboration, hosted by The Linux Foundation, including leaders in finance, banking, Internet of Things, supply chains, manufacturing and Technology.


Consensus 

Consensus is a procedure to select a leader node, which decides whether the block of transactions is to be committed or rejected. Earlier versions of blockchain system used Proof of Work (PoW) for consensus process. Every node or participatory node is given a mining task, and a node elected as leader completes the mining task first. Mining task is to find or calculate a certain pattern value of hash value by adding nonce to current hash. Node that participates in mining process requires heavy computing resources. Latest consensus protocol uses PoET, “Proof of Elapsed Time”. Every node in the consensus process selects random time and keeps decreasing. The node that reaches zero first is selected as leader.

Transaction

Transaction is a unit of business data within Block. Block is a set of transactions bundled with signatures and hash value of previous block. Genesis block is the first block of chain created during installation and configuration.

Merkle Tree

Merkle Tree is a tree data structure in which leaf node holds hashes of every transaction and intermediate node holds hash calculated from immediate child nodes. In blockchain, a block consists of one or more transactions and its respective tree of hashes. In a distributed system, this tree is used to maintain data consistency among all participating nodes.

Ledger

Ledger/ Chain Database is a key-value database for a chain of serialized blocks. One block may contain one or more transactions.

State Database is a key-value database for storing transaction state and links of its related transactions.

AI chatbot

 An AI chatbot is a software application designed to simulate human conversation using artificial intelligence (AI). It can interact with us...