Google Custom Search Refinements

Google is a very popular search engine. One of the driving forces behind the popularity is the Google Inc’s generous offers such as free site based search. The Google Custom Search Engine (CSE) is a such free Webmaster tool. It allows the site owners to integrate the powerful Google search system into their website. I already discussed how to replace the default WordPress site search with your CSE. In this article, I will introduce you to creating content filters.

Filtering the web

As time progress, the amount of pages and media also increase with it. This is not just true for large scale cooperate websites, but also true for personal websites like SANUJA.COM. Someone who publish articles and other web items regularity would at least have one or two articles/items per week. If you multiply them by the number of weeks per year, that’s a lot of information. The problem with general web search on your site is that the visitor may move out of the site as a result of it. The solution is to use an integrated site search that only search your site. All Content Management System (CMS) comes with some form of built-in or modular site search. For average web owners, that’s all they need. But what if you would like to have more control over how the site content is search? The CSE will allow you to restrict your search to specific area of your site. This is how you configure your Google CSE to refine your search results.

Refining

If you have a section of your website that is more important than the rest, then refining is a good way to help the visitors narrow down their search. For example, on my site I empathize the academic exam bank. I want my visitors to filter out all the materials under Exams and Resources during a search (if desired). Here are the steps to creating a refining filter:

1. Log-in to Google Custom Search Engine (GCS) and select the search engine you would like to edit.

Selecting your Google CSE
Selecting your Google CSE

2. Choose “Search features” from the right hand menu and select the second tab “Refinements”. Now press “Add” button from the Refinements pane.

Adding a refinements.
Adding a refinements.

3. A pop-up window will appear with form for new Refinement addition. Save the item.

Add new refinement popup.
Add new refinement popup.

4. Choose “Setup” from the right hand menu and select the “Basics” tab. Under “Sites to search” you can add a limitation.

Refinement directory/link limitation.
Refinement directory/link limitation.

In this particular example I provided my visitors an option to limit their search to my exams area. Since all my exams bank questions are followed by the common URL, “http://sanuja.com/blog/exams/*”. Which is like a prefix. It will allow the Google CSE to limit all the returned search results to Exams pages.

5. Choose the Refinement option created in step 3.

Limiting the site directory and adding the Refinement
Limiting the site directory and adding the Refinement

Here is an example of a refined search…

Refined search results using the tab style.
Refined search results using the tab style.

Excluding content

You can prevent the Google Custom Search from indexing certain pages or URL (link) patterns. To do that, you can:

1. Navigate to exclude section by clicking the “Advanced” link at the bottom of “Sites to search” section.

Advanced link.
Advanced link.

2. Once in the Advanced sections, you should see “Sites to exclude”. Add either one URL at a time or use the prefix method just like in the refinement configuration.

Restricting (excluding) a prefix URL pattern.
Restricting (excluding) a prefix URL pattern.

There are few reasons to why you may exclude URLs, pages, images or other data. Pages from access restricted or membership based areas can be hidden from search results to prevent unwanted traffic to such areas. Sometimes images have copyright agreements that specifically restrict your users from searching images. You may have “junk” or temporary URLs such as http://domain.xxxx/P?7299 which often generated by some Content Management Systems or plugins/scripts.

Shut Up or Get Out

I am proud to live as a free thinker who sees things as it is rather than a slave who follow the popular opinion

The society is dynamic. To some people, it can be difficult to adapt to evolving nature of our social norms. I must admit that I am one of those people. Thankfully I realized that I am not the only one who rather stand up for what is right over enslaving to popular opinion.

if you don’t like Canada, why don’t leave Canada?

Yes, it is normal to be unfair

Hypocrisy is the corner stone of most societies. From East to West, from ancient to modern and from very successful to failed civilizations have one thing in common; dynamic nature. No civilization is perfect. No community is a united community. While to the outsiders, a society like the Canadian society look perfect, it is impossible to achieve a perfect society. After all, how do you define what is right and what is wrong? How do you determine who is successful and who is not? Who is responsible for keeping scores and what would be the criteria for scoring high oh the moral/ethical high ground scale?

Personally, I believe no one is perfect, including myself. Like is unfair and it is supposed to be like that. What annoys me is that the media controlled by few (less than 10% of the world human population), mislead the public to paint a very bias picture for some benefactors. During 2012 to 2013, I monitored how some popular opinions in Canada (specifically in Calgary) shaped by the media. In October 2013, the Western media started a bullying campaign against Russia ahead of the Sochi 2014 Winter Olympics. The hypocrisy is that the Western block is working hard to influence domestic politics in Russia using the Olympics as a weapon. What most media failed to point out, if the sample principles of criticism for Russia is used on Canada with respect to “police state” style G20 preparation and subsequent human rights abuses by the Canadian police and paramilitary groups, the whole smoke screen will disappear. But the BBC, CNN and other media giants did their best to please their masters by softening any information comes out of Canada. Every bit of information was per-planned and well filtered before released to the public. In fact the news related to human rights abuses by the Canadian officials in 2010 G-20 Toronto summit have NOT being fully broadcasted by the BBC and CNN wold services channels. So the rest of the world population such as India and China would hear the good side of the G20.

oh well, I was never raped… so you must be wrong!

However, now compare the coverage of CHOGM (Commonwealth Heads of Government Meeting) Summit in Sri Lanka this year. Not only the media has been on the offensive against the Government of Sri Lanka even before the event, but the human rights violators of their own citizens like Mr. Stephen Harper (PM of Canada) refused to participate in the event. Who gave the Harper the right to criticize internal affairs of Sri Lanka? After all, isn’t he the same person who told the media that the G-20 human rights abuses in Canada is an internal affair? It would be nice if it was only the top Government officials who is doing this. As soon as Canada refused to participate in CHOGM, a lot of Canadians, took to social media to show their pride supporting the PM’s decision.

The point is no one is perfect. But pointing figure against people like Adolf Hitler by accusing him of propaganda, when we are also doing exactly the same thing is hypocritical. Canada and it’s people with racist and violent past have been sugarcoating Canadian history for years. In this free speaking and democratic country, no abiding taxpayer is allowed to allow to criticize the popular opinion. One of my favorite quotes from hypocritical Canadians is “if you don’t like Canada, why don’t leave Canada?”. Why should a taxpaying Canadian citizen should be banned from Canada? Why a law-abiding Canadian citizen is not allow to criticize Canada, but the Canadians truly believe that they have the moral high grounds to citizen Sri Lanka? Mr. Harper do not pay taxes to Government of Sri Lanka!

I am not saying that you should not be critical of others. What I am saying is that you should also allow criticism of yourself. Accusing other countries of everything and being very defensive when someone problems in our own backyard is not a healthy solution. It will rather create more divisions in our human population than solving any problems. Yes, there are a lot of human rights abuses in China and Sri Lanka for example. But why not we also focus the light on Canadian Army raping children in Haiti peacekeeping mission? You love to have hypocritical one side of the argument because it only highlight the human rights violations of Chinese, but never the Canadians.

Shut Up or Get Out

as soon as a South Asian walked in to the same department, even the French-Canadians become discriminators rather than the victims

It is fact that Canadians used Chinese slaves to build our railroads. It is a fact that majority of foreign earned degrees were not recognized in Canada after the influx of immigrants turn out to be non-Christian and non-Whites. While the Canadians have used the few successful South Asians as a smoke screen to prove that Canada is truly multicultural, the true colours of Canadians have came out during the economic down turn in 2012. The promotions for South Asian Engineers, except for those who are puppets of the game (people who say, “well I am South Asian too and I never face discrimination…so you must be wrong”), have been halted while more and more even the non-English speaking Canadians of White descendents have been promoted. Irony is that I have proof that the discrimination among European populations disappear as soon as a non-European enters the picture. In one Calgary company the French-Canadians were discriminated for a long period. However, as soon as a South Asian walked in to the same department, even the French-Canadians become discriminators rather than the victims. Funny how Canada funds research into internal political and social issues of Sri Lanka and China, but yet no social research has been funded to prove issues in the Canadian society.

I asked my friends, if they would asked a rape victim to shut-up if they spoke against their predator. The majority said no…. and yet, every time I highlight a simple issue like workplace racial and religious discrimination in Canada, I was told to shut up or get out. I could safely say, “oh well, I was never raped… so you must be wrong!”. Oh ya… the irony and hypocrisy at their best.

Where is the evidence?

problem with publishing evidence is the repercussions

Since the powerful Western governments have spent millions of dollars in proving why Communist Party of China is bad for human race, they also pulled out all the funds for research that damage the utopian society in their backyard. Few of my friends asked me where is the evidence to prove that most South Asian Canadians were racially discriminated. I would like to ask my readers, where is your proof that the Communism is bad? If you are critical of where I obtain data, why I am not allow to be critical of where you obtain your data? Who gave you the right to be critical of China? Do you live there? Work their? I earned the right to be critical of Canada because I pay taxes and and I have contributed to the economic development of this country. What is your excuse to criticize the human rights of Sri Lanka? After all, the Canadian Prime Minister refused to attended the CHOGM 2013 in Sri Lanka based on his opinion on Sri Lanka’s internal affairs! According your logic, the Canadian Senate scandal should be justified to avoid all “Made in Canada” products and boycott anything Canadian. After all, who cares if it is an internal problem or not.

Another problem with publishing evidence is the repercussions. Canada lacks human rights and workers rights regulations to protect the whistleblowers. If I specifically publish the names of the companies on my website, I will be sued and the bad guys always have the ability to hide or alter the evidence to fit their “Canadian values”. Unlike in Capitalist countries like Canada, most Socialist countries including the United Kingdom (EU), have regulations to protect who stand up for what is right. But this bullshit free thinkers of Canada lags far behind when it comes to protecting victims from the criminals. However, I think one reason the empire (EU, Canada and US) is loosing ground in the United Nation on bullies other countries is that it has been increasingly difficult to keep the facts hidden. For example, the immigration to Canada from Asia and Africa increased because Canada created wars in Asia and Africa. It was the weapons companies in US and Canadian Security Intelligence Service that benefited from these wars. Now the Canada is paying the price by allowing immigrants including criminals the right to enter, live and be part of the Canadian society. Stop blaming the messenger and face the consequences of your own actions. By simply stating the obvious, I will make a lot of enemies and even lose friends. But I am proud to live as a free thinker who sees things as it is rather than a slave who follow the popular opinion.

Speak up now, but not before

The reason why I spoke out about issues hidden in Canada is that recently the Canadian Federal Government officials and so called “Human Rights Organizations” have yelled at other people’s face. For what? For what they called, “rights violations”. That’s why finally I decided to speak up. Someone has to take the bullet against hypocrisy.

Interference Figures

Introduction

Interference figures or some text may refer to as optical figures are used by mineralogists and other scientists to describe optical properties of crystals. In Geology, optical properties of naturally occurring crystals are used to identify and classify minerals. In addition some companies are interested in manufacturing economically valuable minerals such as synthetic diamonds have a growing interest on the behaviors of these figures.

The interference figures are produced when the polarized light is “split” by a crystal as a result of its physical and chemical properties. However, most textbook will refer to these properties as optical properties. Remember optical properties are caused by physical and chemical variations within the mineral. To obtain an interference figure, the mineral must be anisotropic (as opposed to isotropic).

A petrographic microscope (polarizing transmitting light microscope) must be setup the following way to obtain an interference figure:

1) Focus on a grain under Medium power objective lens on the center of the cross hair.
2) Switch the objective lens to High power (40X and up).
3) Flip the Condenser lens to the path of the light ray.
4) Insert/flip the Polarize to the path of the light that traveled through the mineral.
5) Insert the Bertrand lens and focus it (or remove the ocular lens).
6) Use the Accessory plate to determine the sign (+/-) of the figure. The measurements of vibration is always depend on the slow direction of the Accessory plate.

Uniaxial Minerals

The light will be slip into two components; epsilon (ε) and omega (ω). Following is an example of such image obtained using a microscope. Only one Optic Axis hence, the angle of which the isogyres (bands of extinction – black lines) form is 90-degrees.

Uniaxial Centered Optic
Uniaxial Centered Optic

The following is the same crystal when the Accessory Plate is inserted. Since the upper right has a blue isochrome (colour curves), it is clearly a positive mineral. But take a note that while the diagrams in textbooks may indicate strong blue and yellow regions with clear separations between them, it is just a representation of the following image.

Uniaxial Centered Optic Figure (positive)
Uniaxial Centered Optic Figure (positive)

Uniaxial Negative Figures

The value of component ε less than the value of component ω. Hence, will produce a negative interference figure.

Uniaxial Negative Ellipsoid of Revolution
Figure 1: Uniaxial Negative Ellipsoid of Revolution

Scenario A – If you are looking down at the Optic Axis (A on Figure 1 – above), in which the mineral is cut perpendicular to the Optic Axis, then a Centered Optic Axis interference figure (Figure 2 – below) can be obtained. In uniaxial we can only measure the O – vibration direction.

Interference Figure Diagram for Uniaxial Negative Centered Optic Axis
Figure 2: Interference Figure Diagram for Uniaxial Negative Centered Optic Axis

Scenario B – This is a situation where you are looking down the crystal in between the two vibration directions, but further away from the omega (ω). With each rotation of the stage, the interference figure will move around the field of view.

Interference Figure Diagram for Uniaxial Negative Uncentered Optic Axis
Figure 3: Interference Figure Diagram for Uniaxial Negative Uncentered Optic Axis

Scenario C – When a mineral is cut parallel to the optic axis, you will be looking down at C axis. This will produce a Flash figure. It is not very useful for Interference Figure analysis, but this type of figure is best used for determining birefringence.

Uniaxial Positive Figures

The value of component ε greater than the value of component ω. Hence, will produce a positive interference figure.

Uniaxial Positive Ellipsoid of Revolution
Figure 4: Uniaxial Positive Ellipsoid of Revolution

Scenario A – Bxa interference figure

Interference Figure Diagram for Uniaxial Positive Centered Optic Axis
Figure 5: Interference Figure Diagram for Uniaxial Positive Centered Optic Axis

Scenario B – Optic Axis interference figure

Interference Figure Diagram for Uniaxial Positive Centered Optic Axis
Figure 6: Interference Figure Diagram for Uniaxial Positive Centered Optic Axis

Biaxial Minerals

Biaxial Negative Figures

Biaxial Negative Ellipsoid of Revolution
Figure 7: Biaxial Negative Ellipsoid of Revolution

Scenario A – Between the 2-Optic Axises. Figure 8 below. This is a special Interference Figure known as Acute Bisectrix Figure (Bxa).

Interference Figure Diagram for Biaxial Bxa
Figure 8: Interference Figure Diagram for Biaxial Bxa Negative

Scenario B – Optic Axis based interference figure.

Interference Figure Diagram for Optic Axis Negative
Interference Figure Diagram for Optic Axis Negative

Scenario D – This will results in a Flash figure. Useful for determining birefringence, but not helpful in obtaining an interference figure.

Biaxial Positive Figures

Biaxial Positive Ellipsoid of Revolution
Biaxial Positive Ellipsoid of Revolution

Scenario A – Between the 2-Optic Axises. Figure X below. This is a special Interference Figure known as Acute Bisectrix Figure (Bxa).

Interference Figure Diagram for Biaxial Bxa Positive
Interference Figure Diagram for Biaxial Bxa Positive

Scenario B – Optic Axis interference figure.

Interference Figure Diagram for Optic Axis Positive
Interference Figure Diagram for Optic Axis Positive

Scenario D – This will results in a Flash figure. Useful for determining birefringence, but not helpful in obtaining an interference figure.