Subscribe by Email


Showing posts with label Patterns. Show all posts
Showing posts with label Patterns. Show all posts

Saturday, May 25, 2013

What are advantages and disadvantages of artificial neural networks?


The artificial neural networks, since they can simulate the biological nervous system are used in many real life applications which are also their one of the biggest advantages. 
They have made it easy for carrying out complex processes such as:
Ø  Function approximation
Ø  Regression analysis
Ø  Time series prediction
Ø  Fitness approximation
Ø  Modeling
- With the artificial neuron networks, the classification based on sequence and pattern recognition along with other difficult things such as the sequential decision making and the novelty detection is possible. 
- A number of operations falling under the data processing category such as clustering, filtering, compression and blind source separation etc. are also carried out with the help of artificial neural networks. 
- Artificial neural networks can be considered as the backbone of the robotics engineering field. 
- They are used in computer numerical control and in directing the manipulators.
- It offers advantages in the following fields of:
  1. System control (this including process control, vehicle control and natural resources management),
  2. System identification,
  3. Game – playing,
  4. Quantum chemistry
  5. Decision making (in games such as poker, chess, backgammon and so on.)
  6. Pattern recognition (including face identification, radar systems, object recognition and so on.)
  7. Sequence recognition (in handwritten text recognition, speech, gesture etc.)
  8. Medical diagnosis
  9. Financial applications i.e., in automated trading systems
  10. Data mining
  11. Visualization
  12. E – mail spam filtering
- Today several types of cancers can be diagnosed using the artificial neural networks. 
- HLND is an ANN based hybrid system for detection of lung cancer. 
- The diagnosis carried out with this is more accurate plus the speed of radiology is more. 
- These diagnoses are then used for making some models based up on information of the patient. 
- Its following theoretical properties are nothing but an advantage to the industry:
  1. Computational power: It provides a universal function approximator i.e., the multilayer perceptron or MLP.
  2. Capacity: This property indicates about the ability of ANN to model almost any given function. It has a relation with both the notion of complexity and information contained in a network.
  3. Convergence: This property is dependent on a number of factors such as:
Ø  Number of existing local minima which in turn depends up on model and the cost function.
Ø  Optimization method used
Ø  Impracticality of few methods for a large amount of parameters.
4. Generalization and statistics: Over training is quite a prominent problem in the applications where it is required to create a system that is capable of generalizing in unseen examples. This in turn leads to problem of the over specified or the convoluted systems along with the network exceeding the limit of the parameters. There are two solutions offered by ANN for this problem:
-   Croos – validation and
-   Regularization

Disadvantages of Artificial Neural Networks

1. It requires a lot of diverse training for making the artificial neural networks ready for the real world operations which is a drawback more prominent in the robotics industry.
2. Many storage and processing resources are required for implementing large software neural networks using ANNs.
3. The human has the ability to process the signals via a graph of neurons. A similar simulation of even a very small problem can call for excessive HD and RAM requirements.
4. Time and money cost for building ANNs is very large. 
5. Furthermore, simulation of the signal transmission through all the connections and associated neurons is required.     


Monday, December 10, 2012

What is Object Proxy Mechanism in IBM Rational Functional Tester?


The proxy pattern is recognized as a pattern for software designing in the field of computer science. In the most general term, the proxy can be defined as a class which functions as an interface to some other program or application. 

Where is Proxy used?

- A proxy can be used as an interface to anything such as the following:
  1. A network connection
  2. A large object present in the memory
  3. A file
- Or in other words, we can say that it can be used for any resource that is quite expensive and it is not affordable to duplicate it.
- An example of the proxy can be given by a reference counting pointer object. 
- There are situations where it is required to have multiple copies of a complex object. In such situations proxy pattern comes to play a big role. 
- It is adapted for incorporating the fly weight pattern for reducing the memory foot print of the application. 
- In typical situations, the instance created for a complex object is only one in count and multiple proxy objects are created. 
- All these proxy objects consist of a reference to an original object that is both single and complex. 
- The operations that are performed in a proxy object are carried forward to the original object. 
- If all the instances created for the proxy lose their scope, the memory of the complex object is de–allocated for that particular instance. 
- A virtual proxy pattern is used in java. 
- A proxy class can be used to access the remote methods. 

About Object Proxy Mechanism

- Firstly, an interface is created against which the rational functional tester creates the classes using the proxy patterns. 
- An interface may consist of many methods. 
- These methods need to be coded by all the classes which are to implement those particular methods. 
- If a proxy class is running on some other system rather than the original class, then the proxy class can represent its real image itself over there. 
- All the information regarding the image is obtained from the disk. 
- The multiple loading of the image can be avoided by using the proxy pattern with the code of the image. 
- This happens so because the image is accessed in a memory saving manner from some other system. 
- The primary purpose of the proxy object is to act as an intermediate object between the accessible object and the client. 
- The proxy object then serves the purpose of monitoring the life span of the object that is accessible. 
- Also, if the accessible object is not destroyed, all the calls are forwarded to it. - The proxy object checks for the availability of the accessible objects whenever a client makes calls to its accessible properties for getting some info. - If the object is found to be available, the client’s call is passed on to that accessible object. 
- If the case is opposite i.e., if the object is unavailable, an error is returned by the proxy object. 
- Returning of an error message by the proxy object is an indication that the destruction of the object has taken place and this indication is recommended.
The error returned is “CO E OBJNOTCONNECTED”.
- The COM or the component object model returns this error after CoDisconnectObject is called by the server. 
- A transparency is maintained between the client and the proxy object. 
Whenever client calls an accessible object, a pointer to the interface of that object is returned to the client. 
- In turn when this pointer is used by the client to call any of the object’s properties or methods, the execution of the code takes place within proxy object. 
- It is important for the rational functional tester to understand the interface of a given object in order to interact with it. 
- Usually, it is easy to interact with objects such as buttons, list boxes etc, however there are some custom objects in an application for which a proxy needs to be created.


Saturday, May 5, 2012

What is the development style used in test driven development?


Several aspects, approaches and styles have been designed for carrying out the test driven development process. Adequate focus is kept on the writing of the code so that only the necessary code is produced that is required for passing the tests. Such an approach makes sure that the program designs are simple, clearer and cleaner. 

Popular aspects used in TDD


Below mentioned are few of the aspects that are quite popular among the programmers and developers using the test driven development methodology:

KISS:  
- It stands for 'Keep it Simple Stupid' and states that keeping some systems simple yields better outcomes rather than keeping them complex. 
- It defines simplicity as a key goal in the process of program designing and avoids unnecessary complexity. - Some examples of failure to follow Kiss are given by the function creep, scope creep and so on. 
- This principle of software programming was coined by Kelly Johnson.


YAGNI:  
- It stands for 'You Ain’t Gonna Need It'. 
-This though being one of the primary principles of the extreme programming is followed in the test driven development also.
- According to this principle, the functionalities should not be added until they are very much required.
- In other words, it says that the functionalities should be implemented only when they are actually needed and not merely by what one foresees. 
- This aspect has got a few drawbacks.
- The time required is obtained from the other processes like adding, testing, etc. 
- It calls for the need of debugging and documentation of the new features. 
- New features might impose certain constraints which can conflict with the working of a necessary feature in the future. 
- The program may experience the code bloat i.e., it may get bigger and complex and thus complicated. 
- A strict revision control is needed. 
- Addition of more and more features may cause snow ball effect leading to the creeping featurism.


Fake it till you make it:
- This aspect boosts the real confidence of the developers, thus preventing them from getting stuck in to their self fulfilling prophecies. 
- This technique can effectively combat the depression that most of the developers and programmers experience.

Tests are written to achieve the desired design of the software system or application whether is it advance or primitive. The code may pass all the tests being simpler as compared to the target pattern. This may sound odd at the first go but it eventually helps the developer to keep a sharp focus up on the important elements.

Whichever style is followed, there are two basic steps that should be compulsorily followed

1. First write the tests: 
It is required that the tests are written first before the functionality is actually implemented. This step is    known for having two benefits:
       (a)  It ensures that the application is worth testing i.e., it provides testability to the application. The application is considered to be tested via the outset by the developer and he/ she does not need to worry about testing later.
      (b) It ensures that every feature and functionality has a unique test developed for it so that the functionalities are tested as the executable specifications.


2. First fail the test cases: 
This step is carried out in order to ensure the correctness of the test and also its error detection ability. Once this is done, it becomes easy for the implementation of the functionality. This step is the essence of the test driven development. The following steps are constantly repeated:
(a)    Adding of tests cases that fail.
(b)   Writing ode to pass them.
(c)    Refactoring
The productivity is also enhanced following the above two steps. 


Sunday, July 24, 2011

Introduction to Pattern-based design in software design?

Pattern based design is a technique that reuses the design elements. Each architectural pattern, design pattern, or idiom is cataloged, thoroughly documented and carefully considered as it is assessed for inclusion in a specific application.

A description of design pattern may consider a set of design forces. Design forces are those characteristics of the problem and attributes of the solution that constrain the way in which the design is developed. These design forces also describe the environment and conditions that must exist to make design pattern applicable.

Types of design patterns available are:
- Architectural patterns
The overall structure of software, relationship among subsystems and software components and rules are defined for relationship among elements of architecture.
- Design patterns
It addresses a specific element of design to solve some design problem, relationships among components or mechanisms for good communication among components.
- Idioms
These are language specific patterns. They implement the algorithmic element of a component. They can act as a specific interface protocol or a mechanism for communication among components.


Thursday, April 14, 2011

What are different characteristics of design patterns?

A design pattern is a general repeatable solution to a commonly occurring problem in software design.
- It is a proven solution to problems that keep recurring.
- They are reusable solutions to common problems.
- Design patterns are not frameworks.
- Design patterns are more abstract than frameworks.
- Design pattern cannot be directly implemented.
- Design patterns are more primitive than a framework.
- A design pattern cannot incorporate a framework.
- Patterns may be documented using one of several alternative templates.
- Design patterns can speed up the development process by providing tested, proven development paradigms.
- Reusing design patterns helps to prevent subtle issues that can cause major problems and improves code readability for coders and architects familiar with the patterns.
- Patterns allow developers to communicate using well-known, well understood names for software interactions.

A pattern description includes the following elements:
- name of the pattern should be meaningful.
- context of the pattern represents the circumstances or preconditions.
- Problem description that pattern addresses should be provided.
- Solution is a description of the static and dynamic relationships amongthe components of the pattern.
The use of design patterns requires careful analysis of the problem that is to be
addressed and the context in which it occurs.


Monday, March 14, 2011

Architectural Design - Representing the System in Context and Defining Archetypes

As architectural design begins, the design should define the external entities that the software interacts with and nature of the interaction. Once the context is modeled and all external interfaces are described, the structure of the system is specified by the designer. It is done by defining and refining software components that implement the architecture.

REPRESENTING THE SYSTEM IN CONTEXT


Architectural context represents how the software interacts with entities external to its boundaries. A system context diagram accomplishes this requirement by representing the flow of information into and out of the system. At the architectural design level, a software architect uses an architectural context diagram to model the manner in which software interacts with entities external to its boundaries.

How do systems inter-operate with the target system?
Superordinate Systems
These systems use the target system as part of some higher level processing scheme.
Subordinate Systems
These systems are used by the target system and provide data or processing that are necessary to complete target system.
Peer-level Systems
These systems interact on a peer-to-peer basis.
Actors
These entities interact with the target system by producing or consuming information necessary for requisite processing.
Each of these external entities communicates with target systems through an interface.

DEFINING ARCHETYPES


Archetypes are the abstract building blocks of an architectural design. It is a class or pattern that represents a core abstraction that is critical to design of an architecture for the target system. Archetypes can be derived by examining analysis classes defined as part of analysis model.Target system architecture is composed of these archetypes which represent stable elements of the architecture. Some kind of archetypes are:
- Nodes
- Detector
- Indicator
- Controller


Friday, March 11, 2011

What are different types of architectural pattern domains?

Architectural patterns define a specific approach for handling some behavioral characteristics of the system. A software architecture may have a number of architectural patterns that address issues such as concurrency, persistence and distribution.

CONCURRENCY
To promote parallelism, applications must handle multiple tasks and there are different ways to handle concurrency by an application and each way can be presented by a different architectural pattern.
- One approach is to use an operating system process management pattern that provides built-in operating system features allowing components to execute concurrently.
- Another approach is to define a task scheduler at the application level.

PERSISTENCE
Data persists if it survives past the execution of the process that created it. Persistent data can be read or modified by other processes at a later time as they are stored in a database or file. Persistence can be achieved through two architectural patterns:
- database management system pattern that applies the storage and retrieval capability of a database management system to the application architecture.
- application level persistence pattern that builds persistence features into application architecture.

DISTRIBUTION
The distribution problem addresses in a manner in which systems or components communicate with one another in a distributed environment. The most common architectural pattern established to address distribution problem is the broker pattern. Broker acts as middle man between client and server component.


Thursday, March 10, 2011

What are different types of architectural styles?

Large number of computer systems are created. Some of the architectural styles are:

Data Centered Architecture
Data store resides at center of architecture and is accessed frequently by other components that update, add, delete or otherwise modify data within the store. A data centered architecture promotes integrability, which means existing components can be changed and new client components added to the architecture without concern about other clients.

Data-flow Architecture
Data flow architecture is applied when input data is to be transformed through a series of computational or manipulative components into output data. Pile and filter structure has a set of components called by filters connected by pipes that transmit data from one component to another. Each filter works independently. If data flow degenerates into a single line of transforms, it is called batch sequential.

Object Oriented Architecture
In this architecture, data and operations are encapsulated by the components of a system. Communication and coordination between components is done by message passing.

Call and Return Architecture
In this architecture, software designer achieves a program structure which is relatively easy to modify and scale. Two sub-styles exist: Main program/subprogram architecture and Remote Procedure Call Architecture.

Layered Architecture
In this architecture, different layers are defined. Each layer accomplishes operations that progressively become closer to machine instruction set. Components service user interface operations at outer layer. Components perform operating system interfacing at the inner layer.


Tuesday, March 8, 2011

Software Architecture Design - why is it important?

The architecture is not the operational software, rather it is a representation that enables a software engineer to analyze the effectiveness of the design in meeting its stated requirements, consider architectural alternatives at a stage when making design changes is still relatively easy and reduce the risk associated with the construction of the software.

- Software architecture enables and shows communication between all parties interested in the development of a computer based system.
- Early design decisions that has a profound impact on software engineering work is highlighted through architecture.
- Architecture constitutes a relatively small, intellectually graspable model of how the system is structured and how its components work together.

The architectural design model and the architectural patterns contained within it are transferable. Architectural styles and patterns can be applied to the design of other systems and represent a set of abstractions that enable software engineers to describe architecture in predictable ways.

Software architecture considers two levels of design pyramid - data design and architectural design. The software architecture of a program or computing system is the structure or structures of the system, which compose software components, the externally visible properties of those components and the relationships among them.


Thursday, March 3, 2011

How do we create an architectural design....an overview

Design is an activity concerned with making major decisions, often of a structural nature. It is a multi-step process in which representations of data and program structure, interface characteristics, and procedural detail are synthesized from information requirements.

Architectural design represents the structure of data and program components that are required to build a computer based system. It considers the architectural style that the system will take, the structure and properties of the components that constitute the system, and the interrelationships that occur among all architectural components of a system. A software engineer can design both data and architecture, the job is often allocated to specialists when large, complex systems are to be built. A database or data warehouse designer creates the data architecture for a system. The system architect selects an appropriate architectural style for the requirements derived during system engineering and software requirements analysis.

Architectural design provides with the big picture and ensures that you have got it right in a same manner as before building a house, you need a blueprint. Architectural design begins with data design and then proceeds to the derivation of one one or more representations of the architectural structure of the system. Alternative architectural styles or patterns are analyzed to derive the structure that is best suited to customer requirements and quality attributes. Once an alternative has been selected, the architecture is elaborated using an architectural design method.

An architecture model encompassing data architecture and program structure is created during architectural design. In addition, component properties and relationships are also described. At each stage, software design work products are reviewed for clarity, correctness, completeness, and consistency with requirements and with one another.


Wednesday, February 16, 2011

Interface Design Steps - Applying Interface Design Steps, User Interface Design Patterns and Design Issues

Interface design is an iterative process. Interface design activities commences once interface analysis has been completed. Each user interface design occurs a number of times, each elaborating and refining information developed. Interface designer begins with sketches of each interface state and then work backward to define objects, actions, and other important design information.

APPLYING INTERFACE DESIGN STEPS


- Definition of interface objects.
- Defining the actions that are applied to them.
- Description of a use case is written.
- Once objects and actions are defined and elaborated, they are categorized by type.
- Target, source and application objects are identified.
- A source objects is dragged and dropped onto a target object.
- Application objects represents application specific data that is not directly manipulated as part of screen interaction.
- Screen layout is performed once all objects and actions are defined.
- Screen layout is interactive process in which graphical design and placement of icons, major and minor menus, screen text is conducted.
- Although automated tools can be useful in developing layout prototypes, sometimes a pencil and paper are all that are needed.

USER INTERFACE DESIGN PATTERNS


- A wide variety of user interface design patterns have emerged.
- A design pattern is an abstraction that prescribes a design solution to a specific well bounded design problem.

DESIGN ISSUES


Four common design issues are:
- system response time: it is measured from the point at which the user performs some control action. its two main characteristics are length and variability.If system response is too long, user frustration and stress is the result.Variability refers to the deviation from average response time.
- user help facilities: design issues must be addressed when a help facility is considered.
- error information handling: A good error message should describe problem in language that a user can understand. An error message should provide constructive advice for recovering from error. The message should indicate any negative consequences of the error. The error message should be accompanied by an audible or visual cue and the message should be non-judgmental.
- command labeling: Conventions for command usage should be established across all applications.It is confusing and often error-prone for a user to type command. The potential of error obvious.

Unnecessary iteration, project delays, and customer frustration often result. It is better to establish a design issue to be considered at beginning of software design, when changes are easy and costs are low.


Wednesday, January 19, 2011

Hypermedia Design Patterns in Web Engineering

Web engineering uses design patterns. These are of two types:
- Generic design patterns - applicable for every software.
- Hypermedia design pattern - specific to WebApps.
Design problems can be solved by using design patterns. There are some pattern categories:

NAVIGATION PATTERNS
These patterns helps in the design of NSU, navigation links and overall navigation flow of the web application.

ARCHITECTURAL PATTERNS
It helps in the design of content and web application architecture. Many architectural patterns are available for web engineers who design web applications in various business domains.

COMPONENT CONSTRUCTION PATTERNS
The web application components can be combined by the methods provided by these patterns. When data processing functionality is required within a web application, the architectural and component level design patterns are applicable.

PRESENTATION PATTERNS
Presentation patterns assist in the presentation of content as it is presented to the user via the interface. They tell how to organize user interface control functions, shows the relationship between an interface action and the content object it affects, establish content hierarchies.

BEHAVIOR AND USER INTERACTION PATTERNS
These patterns assist in design of user machine interaction. They address how the interface informs the user of the consequences of a specific action, how a user expands content based on usage context, how to best describe the destination that is implied by a link.


Facebook activity