Welcome to NALIN.

An Official and Personal Blog of NALIN ADHIKARI.

This blog includes about my works, activities and achievements. To contact me click here

Let's take a tour and discover about me.

Last but not the least, I have included some programming and technical articles and will include more in the near future.

Stay connected by signning up for email updates.

Thank you !!!

What is GPS and how it works?

Leave a Comment

The Global Positioning System (GPS) is a satellite-based navigation system made up of a network of 24 satellites placed into orbit by the U.S. Department of Defense. GPS was originally intended for military applications, but in the 1980s, the government made the system available for civilian use. It works in any weather conditions, anywhere in the world, 24 hours a day. There are no subscription fees or setup charges to use GPS. Accuracy can be pinpointed to within one meter with special military-approved equipment. GPS equipment is widely used in science and has now become sufficiently low-cost so that almost anyone can own a GPS receiver.

GPS Technology

The 24 satellites that make up the GPS space segment are orbiting the earth about 12,000 miles above us. They are constantly moving, making two complete orbits in less than 24 hours. These satellites are travelling at speeds of roughly 7,000 miles an hour. GPS satellites are powered by solar energy & have backup batteries. They have backup batteries onboard to keep them running in the event of a solar eclipse, when there's no solar power. Small rocket boosters on each satellite keep them flying in the correct path.

GPS Facts

  • The first GPS satellite was launched in 1978.
  • A full constellation of 24 satellites was achieved in 1994.
  • Each satellite is built to last about 10 years. 
  • Replacements are constantly being built and launched into orbit.
  • A GPS satellite weighs approximately 2,000 pounds and is about 17 feet across with the solar panels extended.
  • Transmitter power is only 50 watts or less.

How GPS works?

  • GPS satellites broadcast radio signals providing their location, status, and precise time {t1} from on-board atomic clocks.
  • The GPS radio signals travel through space at the speed of light {c}, more than 299,792 KM/Second.
  • A GPS device receives the radio signals, noting their exact time of arrival {t2}, and uses these to calculate its distance from each satellite in view.
  • Once a GPS device knows its distance from at least 4 satellites, it can use geometry to determine its location on Earth in three dimensions.

Scope and application areas of GIS

Leave a Comment
GIS technology can be used for scientific investigations, resource management, asset management, archaeology, environmental impact assessment, urban planning, cartography, criminology, geographic history, marketing, logistics, Prospectivity Mapping, and other purposes.

For example, GIS might allow emergency planners to easily calculate emergency response times in the event of a natural disaster, GIS might be used to find wetlands that need protection from pollution, or GIS can be used by a company to site a new business location to take advantage of a previously under-served market.

Uses of GIS range from indigenous people, communities, research institutions, environmental scientists, health organizations, land use planners, businesses, and government agencies at all levels.

Uses range from information storage; spatial pattern identification; visual presentation of spatial relationships; remote sensing - all sometimes made available through internet web interfaces, involving large numbers of users, data collectors, specialists and/or community participants.

One of the primary services provided by a GIS project is the geo-referencing of various data layers for mapping projection, involving the use of satellite image data for GIS mapping including:
  • Mineral Mapping
  • Pipeline Corridor Mapping
  • Defence Mapping
  • Airport Mapping
  • Land Cover Classification
  • Urban Development
  • Pre and post 2D/3D seismic surveys
  • Environmental Impact Studies (EIS)
  • Coastal erosion studies
  • Cadastre Mapping
  • Disaster Analysis
Mineral Mapping
Satellite Imagery and aerial photography have proven to be important tools in support of mineral exploration projects.  They can be used in a variety of ways.  Firstly they provide geologists and field crews the location of tracks, roads, fences and inhabited areas.  This is important for mapping out potential access corridors for exploration areas and considering the environmental impact of large project.  These images are also useful for mapping outcrops and regolith systematics and vegetation cover across exploration blocks and over regional areas.

Pipeline Corridor Mapping
Improve Safety and Security for Pipeline and Transmission Surveys:  Satellite imagery and GIS data have significant potential to reduce a number of safety and security issues for pipeline corridor planning as well as supply managers with solutions through spatial representation of data for land, lease management, exploration, production, transmissions, environmental, financial and facilities management. This information is required to make decisions that will significantly impact the operator's ability to provide the services demanded by their customers.

Defence Mapping
Satellite imagery and GIS maximizes security programs which can enable local governments to better assess and understand how to develop programs to save lives, protect property and enhance the future economic stability of their communities. The current threats to a country range from incidents of terrorism and information attacks on critical infrastructure to the potential use of weapons of mass destruction and the spread of infectious diseases. Each one of these threats could cause massive casualties and disruption to a country.

Airport Mapping
Satellite Imaging Corporation (SIC) provides 3D airport mapping using high resolution stereo satellite imagery to support airport pre-planning and design, airport layout plans (ALPs), navigational mapping, and airport security and aviation safety operations.
3D Digital Surface Models (DSM's) and Digital Terrain Models (DTM's) can be created to support airport and aviation operations to provide details and data for the construction of airport runways, airport terminals, airport layout design, airspace analysis, obstruction surveys, facility mapping, taxiways, aprons/parking areas, 3D flight simulation for pilot training, aircraft operations, and GIS database development.

Land Cover Classification
Satellite imagery and GIS maps for land cover, land use and its changes is a key to many diverse applications such as environment, forestry, hydrology, agriculture and geology. Natural Resource Management, Planning and Monitoring programs depend on accurate information about the land cover in a region. Methods for monitoring vegetation change range from intensive field sampling with plot inventories to extensive analysis of remotely sensed data which has proven to be more cost effective for large regions, small site assessment and analysis.

Evaluation of the static attributes of land cover (types, amount, and arrangement) and the dynamic attributes (types and rates of change) on satellite image data may allow the types of change to be regionalized and the approximate sources of change to be identified or inferred.

Urban Development
Satellite imagery for urban and land development can be used to gather strategic planning information pertaining to a district or an entire city. High resolution satellite imagery and LiDAR incorporated into a GIS (Geographic Information Systems) and CAD (Computer Aided Drafting) has gained popularity among Planners, Developers and Engineers for large scale mapping of any region for most urban and land development applications.

Information from satellite images when combined with GIS mapping is used for analysis in evaluating construction costs as well as environmental impact of alternative routes for utility and transport corridors; land cover and land use classification; identifying population groups at risk where human intervention is most needed to limit and prevent hazards during development stages.

Pre and post 2D/3D seismic surveys
No matter how remote, Satellite Imaging Corporation (SIC) can retrieve satellite images from the most difficult-to-photograph areas of the world. For heavily forested areas, we provide medium-to-high resolution "Bare Earth" DEMs. This provides weather independency, allowing us to map large areas of terrain in limited timeframes, independent of the weather and solar illumination conditions. We are also familiar with specialized retrieval methods used for satellite imagery in remote areas, highly developed areas and areas of persistent heavy cloud cover such as the tropics.

Environmental Impact Studies (EIS)
Satellite Imaging Corporation (SIC) provides satellite image data at different spatial, spectral, and temporal resolutions by using the appropriate combination of bands to bring out the geographical and manmade features that are most pertinent to your project for detecting and monitoring environmental changes.

Satellite imagery and GIS have greatly expanded opportunities for data integration, analysis, modelling, and map production for environmental monitoring and assessment. As populations grow, as countries boost their economies, as landscapes change, governments have increasingly relied on up-to-date satellite imagery and other geospatial data for applications such as environmental planning, land registration, disaster response, public health, agricultural biodiversity conservation and forestry.

Coastal erosion studies
Many coastal managers are changing the way they manage coastal problems. Instead of only undertaking corrective measures, officials are moving toward prevention. Using potential models with satellite imaging technology and land cover data through GIS, managers can create scenarios for future development, as well as permitting and land use scenarios, to estimate the impacts on sensitive water bodies.

Satellite images can provide coastal management researchers and scientists with data for assessment and analysis of water temperature, salinity, phytoplankton, hydrology, shoreline changes, bathymetry, soil moisture and potential threats to our coasts.

Assessments and predictive capabilities through satellite imagery incorporated with GIS are needed to predict onset of events that may significantly affect human health, critical wetlands and ecosystems, and economic development.

Cadastre Mapping
Satellite images which forms the base for the generation of action plan maps, if used in the background of intelligent cadastral vector data, can improve the details of the thematic maps as well as action plan maps. It also helps in the monitoring of land cover changes that can be identified by detailed change detection processing procedures and implemented in the GIS cadastre mapping project.

Disaster Analysis
Satellite imagery and GIS maps can give emergency and disaster response officials a wealth of information for assessment, analysis and monitoring of natural disasters such as hurricanes, tornadoes and cyclone damage from small to large regions around the globe.

Estimates of the particular land cover classes that may be inundated by a natural disaster can enable operators and planners to better assess their region's risk and vulnerability. This information will allow for prioritizing target mitigation and preparedness activities for their area.

The use of multispectral satellite imagery is therefore critical for the separation of constituent materials within an image and for the interpretation of images of damage for pre or post-disaster assessment. View Before and after example satellite images here.

Geographical Information System (GIS)

Leave a Comment
Geography is the study of Earth’s features and patterns of their variations in spatial location and time. Many questions of agricultural production are geographic in nature as the production depends on the environment and prevailing socio economic conditions, both of which vary spatially and in time. Examples are questions related to natural resources management, precision agriculture, agro-ecological classification for land use planning, regional trends and patterns in technology adaptation, agricultural productivity and income, non-Pont source pollution from agricultural lands, etc. Answering these questions requires access to large volumes of multidimensional geographical (spatial) information of weather, soils, topography, water resources, socio economic status, etc. Further, answers to even apparently simple questions require that the data from several sources be integrated in a consistent form. Geographical Information Systems or GIS enable representation and integration of such spatial information.

Geographic information systems (GIS) (also known as Geospatial information systems) are Computer Software and hardware systems that enable users to capture, store, analyze and manage spatially referenced data. GISs have transformed the way spatial (geographic) data, relationships and patterns in the world are able to be interactively queried, processed, analyzed, mapped, modelled, visualized, and displayed for an increasingly large range of users, for a multitude of purposes.

In a general sense, the term describes any information system that integrates, stores, edits, analyzes, shares, and displays geographic information. GIS applications are tools that allow users to create interactive queries (user-created searches), analyze spatial information, edit data in maps, and present the results of all these operations. Geographic information science is the science underlying geographic concepts, applications, and systems.

It is a special case of information system where the database consists of observations on spatially distributed features, activities or events, which are definable in space as points, lines or area. A geographic information systems manipulates data about these points, lines and areas to retrieve data for ad hoc queries and analyses.

Whether siting a new business, finding the best soil for growing bananas, or figuring out the best route for an emergency vehicle, local problems also have a geographical component GIS will give you the power to create maps, integrate information, visualize scenarios, solve complicated problems, present powerful ideas, and develop effective solutions like never before. GIS is a tool used by individuals and organizations, schools, governments, and businesses seeking innovative ways to solve their problems.

Today, GIS is a multibillion-dollar industry employing hundreds of thousands of people worldwide. GIS is taught in schools, colleges, and universities throughout the world. Professionals in every field are increasingly aware of the advantages of thinking and working geographically.
  • Geographic:  80% of government data collected is associated with some location in space.
  • Information: attributes, or the characteristics (data), can be used to symbolize and provide further insight into a given location.
  • System:  a seamless operation linking the information to the geography – which requires hardware, networks, software, data, and operational procedures.

GIS is:

  • Not just software!!! 
  • Not just for making maps!!!

GIS can be used as synonymous to:

  • GI Systems: A computerized tool that helps solve geographic problems. 
  • GI Science: The development of data models, algorithms, and methods for representing geography and spatial relationships in order to support spatial analysis and location-based computing 
  • GI Studies: The systematic study of society’s use of geographic information, including institutional, organizational and procedural issues. 
  • GI Services: The business of providing GIS data and analysis tools to GIS users (often by chaining interoperable components in logo-block fashion).

Jetty Application Server

1 comment

How to Install Jetty Application Server

Jetty is an open-source Servlet container and Application Server which is known to be lightweight, portable, robust, flexible, extensible and providing support for various technologies like SPDY, WebSocket, OSGi, JMX, JNDI, and JAAS. Jetty is very convenient for development and also widely used in production environments.

Jetty presents Standalone, Embedded and Jetty Maven Plugin modes of operation.

  • Download Jetty binaries from the Jetty Homepage
  • First we have to extract the zip (or tgz) archive to a convenient directory. After extracting the binaries, have to go inside the root directory of the extracted folder and execute the following command.
    java -jar start.jar
  • If we see similar output like this 2015-11-06 23:00:18.042:INFO:oejs.Server:main: Started @1021ms at the end of the terminal then the Jetty is successfully started.
  • To verify it through the browser, have to navigate to this url http://localhost:8080/ and we will get Error 404 - Not Found page with Jetty Server signature at the end like Powered by Jetty:// 9.3.5.v20151012

Running Web Applications In Jetty

Create a WAR file and drop that file in the webapps folder. We do not even need to restart Jetty. webapps directory is monitored periodically and new applications are deployed automatically.

Changing the Jetty Port

By default, Jetty runs on 8080. In order to change it to some other port, we have to do the following:
  • Open start.ini under Jetty root directory.
  • Add this line jetty.port=7070
  • Save and close the file.

WildFly Server

Leave a Comment
WildFly is an application server which is flexible and lightweight that helps us build amazing application. It is authorized by JBoss and now developed by Red Hat. This application server is written in Java and implements the Java Platform, Enterprise Edition (Java EE) specification and runs on multiple platforms.

Some features of WildFly Server.
  1. Unparalleled Speed
    • Fast Startup
    • Ultimate Web Performance & Scalability
  2. Exceptionally Lightweight
    • Memory Diet
    • Slimable / Customizable Runtime
  3. Powerful Administration
    • Unified configuration & Management
    • Domain & Standalone Management
  4. Supports Latest Standards and Technology
    • Java EE 7
    • Modern Web
  5. Modular Java
    • No more jar
    • Fast Linking & Concurrent Loading
  6. Easily Testable
    • Arquillian
    • Smarter Development

Installation and running process.

  • Download and extract the ZIP or TGZ file from here.
  • Download the mysql driver for WildFly and extract if compressed.
  • Place mysql folder inside wildfly/modules/system/layers/base/com folder.
  • Create an user for deployment. For creating user, run wildfly/bin/add-user.sh. You can use any username and password. You will need this during deployment.
  • Open wildfly/standalone/configuration/standalone.xml and the add following XML snippets in <subsystem xmlns="urn:jboss:domain:datasources:3.0">.
          <driver name="mysql" module="com.mysql">

          <datasource jndi-name="java:jboss/datasources/nalinDS" pool-name="nalinDS"           
           enabled="true" use-java-context="true">
  • To start the project run command "wildfly/bin/standalone.sh".
  • To deploy the project, run command "mvn wildfly:deploy -Dwildfly.user=username -Dwildfly.password=password" in the root path of your project.
If any problem, feel free to comment. I will try to solve them. Regards.

Nepal Constitution 2072 (2015 AD)

Leave a Comment
The new constitution of Nepal (2072) has been finalized and is available for public to view. New constitution of Nepal is shown below.

Features of New constitution of Nepal 2072

  • 8 states in Nepal (Name to be given later with the help of special committee)
  • Discussion to continue on contentious issues and amend of some provision until the final one.
  • Vote of dissents are not a part of the draft but put there for further discussion.
  • Citizenship by Father name or mother name.
  • citizenship to NRN (Non resident Nepalese).
  • 60 percent FPTP and 40 PR in state assemblies as well.
  • Secularism to continue with freedom of any religion.
  • Bicameral legislation (275 Parliament and 45 National assembly members).
  • New Prime Minister, President and Parliament head election to be held within a month after promulgation of new constitution.
  • Five unchangeable provisions.
This is a good news for every citizen of Nepal that after a long waiting period draft of constitution has been released by constitutional assembly. We all Nepalese hope for peace, prosperous, united Nepal. Lets hope the new constitution of Nepal 2072 will be on favor of Nepal which can economically, politically boost Nepal. The draft constitution is yet to be finalized and CA members are committed to release the constitution of new nepal 2072 by the month of Shrawan.

Some photos on the day of declaration of new constitution of Nepal (2072).

You can drop down your views regarding new constitution of Nepal in the comment section below.

Click HERE to download a copy of Constitution of Nepal 2072.

Weird Facts

Leave a Comment
Hello there, today I am going to list some of the weird facts that I have encountered while surfing some social networking sites. The following facts are awesome and amazing. May be some of them you have already known but may be most of them are very new and jaw dropping to you.

  • The world's shortest commercially available flight takes place between the two Orkney Islands, Westray and Papa Westray, just north of Scotland, separated by a distance of only 1.7 miles. It is only 2 minutes long, and can be as short as 47 seconds in ideal conditions.
  • When Gangnam Style surpassed 2.15 billion views on YouTube, the View Counter went negative, causing YouTube to release a statement saying "We never thought a video would be watched in numbers greater than a 32-bit integer (=2,147,483,647 views), but that was before we met PSY.
  • The reason why we hate the recorded sound of our voice is because our skull changes the resonance of our voice from within and creates more bass. When we hear a digital recording of our voice, although slightly unfamiliar to ourselves, it's exactly how other people hear it.
  • Due to increased brain activity, people with higher intelligence tend to have a harder time falling asleep at night.
  • Chocolate can help fight against bacteria in the mouth and stop dental decay. Surprisingly, it can be good for your teeth.
  • When Katherine Johnson was little, she loved to count things. By the age of 10, she was in high school. In 1961, she calculated the trajectory of NASA's first trip into space/ She was so consistently accurate that when NASA began to use computers, they had her check the calculations to make sure they were correct.
  • A cat named Simon served on a Royal Navy ship in 1949, and received a medal for raising morale, killing off a rat infestation and surviving cannon shells during his service. Hundreds attended his funeral when he died from infected wounds.
  • There exists a variation of soccer where 3 teams face each other at the same times.
  • Did you know that when a dog sees it's owner, its brain secretes the same substances as ours when we are in love?
  • The reflex that causes people to sneeze when looking at the sun is called Autosomal-dominant Compelling Helio-Ophthalmic Outbrusr Syndrome, which abbreviates to ACHOO.
  • A cat has been the mayor of a town in Alaska for over 15 years. His name is Mr. Stubbs and every afternoon, he goes to a nearby restaurant and drinks water out of a wineglass laden with catnip.
  • Chinese government takes its officials and members of their families on prison tours on a regular basis to give officials an introduction to what awaits them if they should engage in corruption. The tours include meet-and-greets with former government officials who were caught for corruption.
  • A homeless man in NYC who would regularly order an expensive dinner at a restaurant and refuse to pay for it in order to be sent to prison where he would receive a meals a day and a clean bed. He refused to commit more serious crimes to get longer sentences as he did not want to hurt anyone.
  • Sitting straight upright in your chair is bad for your back. You should instead slouch at an angle of 135 degrees.
  • According to a legend in Iceland, if you don't get new clothes on Christmas you will be eaten by a giant cat.
  • Iceland has one of the largest gun ownership rates in the world and yet has one of the lowest crime rates in the world.
  • The first ever speeding fine was given to Walter Arnold of Kent, UK, in January 1896. His speed was 8mph in a 2mph zone. He was caught by a policeman on a bicycle.