Monday, 20 September 2021

Cheat Sheets / (Computer & Hand Writing) - Alg and Analytic Geometry

 These pages contains examples of my works on various compilations in academic works. During mathematical teachings I develop these simple cheat-sheets for students with handwriting:-









Saturday, 18 September 2021

CheatVid: Git Commands (CLI Commands With Short Description)




The following git commands are covered in this simple video linked below:




  • git config --global user.name “[firstname lastname]”
  • git config --global user.email “[valid-email]”
  • git config --global color.ui auto
  • git init
  • git clone [url]

  • git status
  • git add [file] 
  • git reset [file] 
  • git diff
  • git diff --staged 
  • git commit -m “[descriptive message]” 

  • git branch 
  • git branch [branch-name] 
  • git checkout 
  • git merge [branch] 
  • git log 

  • git log 
  • git log branchB..branchA 
  • git log --follow [file] 
  • git diff branchB...branch
  • git show [SHA] 

  • git rm [file] 
  • git mv [existing-path] [new-path] 
  • git log --stat -M 


Thursday, 9 September 2021

Regional Vintage Music

 Modern music is highly instrumental. Few days earlier I gone through vintage regional music and found the following songs best in terms described in comments:-


(1)
[shree-420][1955][Ramaya vasta vaya]
[https://www.youtube.com/watch?v=Vpq7YrgKNVs]
Comments:- beats are awesome. The dancing lady <shiela vaz> is fabolously expressive. The serious face of the silent man is generating storyteller-look.

(2)
[Pakeeza][1972]Chalo Dildar Chalo
[https://www.youtube.com/watch?v=OtM1WVwEO44]
Comments:-The simple music, good poetic imagination, vocal sweetness and night-mode videography almost put a lonely person into a trance. [Singer: Muhammad Rafi (late) and Lata Mangeshkar [now 90 years old]. This song is manytimes remixed. A version played by express-news chanell is here: https://www.youtube.com/watch?v=s__F7XNOG18

(3)
[Mela][1948][Ye zindagi ke mele]
[https://youtu.be/mCCPwTj4vLk?list=RDiZY2U7j8OAQ]
Comments:- Just thinking how each word is  proved true as beneath the colorful lights, the fairgrounds of this world are still populated - while the singer may not be here to see them. Note:- Dlip Kumar is alive in 97th year. [Singer: Muhammad Rafi died in 1980]

(4)
[Dulari][1949][Ai dil tujhe qasam hey]
[https://www.youtube.com/watch?v=TBMOyJa-hV8]
Comments:- One reason for me to like this song is that my dad has liking for it as I heard him several times singing in soliloquy.
[Continue..]

Salam Esapzay
salamk.blogspot.com

The Amphibians of Karachi

 Phylum Amphibia is a biological term which describes a group of vertebrates that are able to survive in water as well as on land. Species in this group includes the frogs, toads, turtles, salamanders and karachiites. The last specie in previous examples is recently discovered in a South-Asian country Pakistan's largest city known as Karachi. This recent addition to the Amphibians has successfully satisfied all conditions required to be included in the category. They have "a backbone" which places them in category of vertebrates and over the years they have consistently shown the ability to survive both in water and over the  land even without gills and special skin enough to qualify it in Amphibian category. Fortunately I am also an amphibian and the test I have passed last day confirmed my confidence in this regard.


I left my office located at Main Shara-e-Faisel near PAF museum at 4 PM for home (North Nazimabad Town) where I finally reached at 8 PM. The trip was important for me in the sense that being amphibian I have never found opportunity to test my abilities and this day I have successfully proved that I am in-fact an honorable member of this phylum because nearly half the way I confidently swam in all sort of waters.

I collected some images in favor of my claim, pasted below:-

The first picture is published by The Nation newspaper in which one can see several amphibians within the water.




In this picture one can see an amphibian going through water without any hesitation. The cute little baby amphibian can be seen sitting on strange machine that is also capable to run in water and land alike.




Probably bored in the bus some amphibians have naturally jumped into the water.


An amphibian is probably going to his home down the water but cannot find a suitable parking for his bike there. Another specie of the same class is standing to help him go down the water.

Wednesday, 8 September 2021

Data-Extraction from website

Extraction of daily market data refreshed after a time-interval of 5 minutes. I developed the program given below as part of a large financial software. I try to demonstrate it in a meaningful way.

There is a website http://www.psx.com.pk which is portal of a stock exchange. The stock exchange has a page which display OHLC data and company information formatted in html table. The java program use jsoup api to (a) connect to page (b) read the page (c) fetch the OHLC data values and exchange current status in the following format:-

Symbol  | Open | High | Low | Close | Volume

The exchange does not provide "symbol-code". Symbol values are determined through query from data table containing company-names and company-codes.  The following is screenshot of the web-page:-



The data extracted from the above web page is processed and displayed as shown in the screenshot below:-



The <download> button on the above screenshot triggers execution of the following code. 

  1 /*
  2  * To change this license header, choose License Headers in Project Properties.
  3  * To change this template file, choose Tools | Templates
  4  * and open the template in the editor.
  5  */
  6 package cmnew.downloader;
  7 
  8 import java.util.ArrayList;
  9 import java.util.Iterator;
 10 import java.util.Vector;
 11 import net.coolmarch.cmnew.common.DailyData;
 12 import net.coolmarch.cmnew.common.GeneralDB;
 13 import org.jsoup.Jsoup;
 14 import org.jsoup.nodes.Document;
 15 import org.jsoup.nodes.Element;
 16 import org.jsoup.select.Elements;
 17 
 18 /**
 19  *
 20  * @author salam
 21  */
 22 public class CurrentMarketState {
 23 
 24     ArrayList<DailyData> ddlist = new ArrayList<>();
 25 
 26     public CurrentMarketState() {
 27 
 28     }
 29 
 30     public CurrentMarketState(String status) {
 31         System.out.println("......thisfile...");
 32         String line = "";
 33         GeneralDB gdb = new GeneralDB();
 34         String query = "delete from current_data";
 35         String msg = gdb.execute(query);
 36         System.out.println(msg);
 37 
 38         try {
 39             Document doc = Jsoup.connect("https://www.psx.com.pk/market-summary/").get();
 40             String title = doc.title();
 41 
 42             Elements tabs = doc.select("table");
 43             for (Element table : tabs) {
 44                 if (table == tabs.first()) {
 45                     ;//do nothing
 46                 } else {
 47                     Elements rows = table.select("tr");
 48                     int c = 0;
 49                     for (int i = 1; i < rows.size(); i++) { //first row is the col names so skip it.
 50                         String l = "";
 51                         Element row = rows.get(i);
 52                         Elements cols = row.select("td");
 53                         String s_name = cols.get(0).wholeText();
 54                         if (s_name.startsWith("SCRIP") || s_name.contains("DEFAULTER")
 55                                 || s_name.contains("Indus") || s_name.contains("Millat")) {
 56                         } else {
 57                             String s_ldcp = cols.get(1).wholeText();
 58                             String s_open = cols.get(2).wholeText();
 59                             String s_high = cols.get(3).wholeText();
 60                             String s_low = cols.get(4).wholeText();
 61                             String s_close = cols.get(5).wholeText();
 62                             String s_change = cols.get(6).wholeText();
 63                             String s_volume = cols.get(7).wholeText();
 64 
 65                             s_name = s_name.replaceAll(",", "");
 66                             s_open = s_open.replaceAll(",", "");
 67                             s_high = s_high.replaceAll(",", "");
 68                             s_low = s_low.replaceAll(",", "");
 69                             s_close = s_close.replaceAll(",", "");
 70 //                            s_change = s_change.replaceAll(",", "");
 71                             s_volume = s_volume.replaceAll(",", "");
 72                             
 73                             //because the names in the table have slight difference but 
 74                             //usually the first and second word of the company are same.
 75                             String sq = "";
 76                             String[] st = s_name.split(" ");
 77                             if (st.length > 2) {
 78                                 sq = st[0] + " " + st[1];
 79                             } else {
 80                                 sq = s_name;
 81                             }
 82                             
 83                             
 84 
 85                             String q = "select cm_symbol from cm_companies "
 86                                     + "where cm_name like '" + sq + "%'";
 87                             String symbol = new GeneralDB().getSingleColumnData(q);
 88                             if (symbol == null || symbol.compareTo("") == 0) {
 89                                 symbol = s_name;
 90                             }
 91 
 92                             query = "insert into current_data(scrip, pr_open, pr_high,"
 93                                     + "pr_low, pr_close, pr_volume) values("
 94                                     + "'" + symbol + "',"
 95                                     + "" + s_open + ","
 96                                     + "" + s_high + ","
 97                                     + "" + s_low + ","
 98                                     + "" + s_close + ","
 99                                     + "" + s_volume + ""
100                                     + ")";
101                             System.out.println(query);
102                             System.out.println(gdb.execute(query));
103 //
104 
105                         }
106                     }
107 
108                 }
109 
110             }
111 
112         } catch (Exception e) {
113             System.out.println(e.getMessage());
114         }
115     }
116 
117     public ArrayList<DailyData> getDailySavedData() {
118         ArrayList<DailyData> dlist = new ArrayList<>();
119         String query = "select scrip, pr_open, pr_high, pr_low, pr_close, "
120                 + "pr_volume, (pr_volume*pr_close) as pr_mcap, "
121                 + "(pr_close-pr_open) as ch from current_data";
122         ArrayList al = new GeneralDB().searchRecord(query);
123         Iterator i = al.iterator();
124         while (i.hasNext()) {
125             Vector v = (Vector) i.next();
126             String symbol = (String) v.get(0);
127             String str_open = (String) v.get(1);
128             String str_high = (String) v.get(2);
129             String str_low = (String) v.get(3);
130             String str_close = (String) v.get(4);
131             String str_volume = (String) v.get(5);
132             String str_mcap = (String) v.get(6);
133             String str_ch = (String) v.get(7);
134             
135            
136 
137             DailyData dd = new DailyData();
138             dd.setSymbol(symbol);
139             dd.setOpen(Double.parseDouble(str_open));
140             dd.setHigh(Double.parseDouble(str_high));
141             dd.setLow(Double.parseDouble(str_low));
142             dd.setClose(Double.parseDouble(str_close));
143             dd.setVolume(Double.parseDouble(str_volume));
144             dd.setChange(Double.parseDouble(str_ch));
145             dd.setMcap(Double.parseDouble(str_mcap));
146             dlist.add(dd);
147             
148             System.out.println(symbol+" "+str_close+"  "+str_ch);
149         }
150 
151         return dlist;
152     }
153 
154     public ArrayList<DailyData> getDailyData() {
155         return ddlist;
156     }
157 
158     public static void main(String[] args) {
159         new CurrentMarketState("");
160     }
161 
162 }
163 

LOGO WORKS COOLMARCH

 


physics chap 6 (X)

 





Banned Outfits

 

Son of Asif Ali Zardari and Chairman PPP Mr. Bilawal Bhutto Zardari has blamed the government of giving support and even patronage to banned organizations. This fresh narrative arrived at a time when top leadership including Bilawal himself is under serious corruption inquiries in Fake Accounts Scandal and Money Laundering Scams in Pakistan. It looks very strange as to why out of sudden Mr. Bilawal arose the issue of Banned Organizations and government linkage therewith? Apparently it is to give an impression to Pakistani people and international community that the cases they are facing are outcome of PPP narrative against BO(s). Secondly to pressurize the government by means of defamation which otherwise has a very well-established perception of being standing on a liberal and anti-sectarian humanitarian stance.

While scoring political points against opponents leader of a political party should be serious enough to differentiate between government and state. It is an unwritten but well understood principle that matters having significant long-term value to the integrity and security of state itself should not be sacrificed for short-term political gains. This is up to apex courts to decide the involvement of PPP leadership in the cases under observation. Neither the references are filed by nor Chairman NAB is appointed by current government. As for BO(s) people of Pakistan know very well that the worst time they faced in terms of terrorism and growth of terrorist organization in Pakistan were the times when PPP ruled the country under the presidency of Mr. Asif Ali Zardari.

Bilawal or his good father may not be involved in anything. Nothing can be said as the case is yet to be decided and fair trial means a trial on court floor not in the media rooms. However the question right at the desk is not the issue of BO(s). People of Pakistan desperately wait to hear something from you in support of your innocence rather than your unnatural and untimely response to the issue of BO s by citing out prehistoric references from statements of one or two cabinet members without reference to the context. There won’t be any political gains achievable by this narrative nor it can do any help to lessen the burden brought by ongoing corruption inquiries.

Do it yourself

 


[T.E.X.T]

Each time I tried to make my mind on saying something about Feminism and related women marches, that are widely observed in Pakistan, I got stuck in confusion over subject specially in its relation with contemporary Pakistani society. Like other countries in the world, Pakistan too has divided opinions into which majority of men and women vehemently oppose it while there are social divisions, individuals and mainstream political bodies that, at least in theory, agree with it though practically stands at a gape. It is also observed that majority of people who oppose the feminist views either does not understand the move at all or for some good reasons think it unnatural and even harmful for society and the underlying family system.


It is observed that majority of people who oppose the feminist views either does not understand the move at all or for some good reasons think it unnatural and even harmful for society and the underlying family system.

Before analyzing the case in cultural perspective of Pakistan let us first see what actually Feminism is and what change it demands from society? Feminism is all about gender equality. Commonly agreed upon definition of includes (1) Social Equality (2) Economic Equality and (3) Political Equality. Feminism advocates that women and men have equal social, political and economical rights. Many people fail to understand the meanings of equality. Equality here does not mean similarity. Thus a feminist is not likely to say man and woman are same. Their advocacy is about equal rights for example equal access to education, ownership of land or holding a public office.


Equality here does not mean similarity. Thus a feminist is not likely to say man and woman are same. Their advocacy is about equal rights


There were times in Europe and America when women were not given the rights to vote in elections. They were not allowed ownership of property, traveling or running a business without a male partner. It was almost established that woman has no role in society outside home and the prime duty expected from woman was domestic one at the top of which was to give birth to the heirs of family property.

Though status of women in society has always been a subject of philosophy dated back to Plato who discussed it in details - the term, in modern sense, was first coined in France during French Revolution. The movement has different objectives during the times with more or less the same theme ie. same rights as men enjoy.


During the last few years feminist views, specially Woman March on designated days, got wide attention on social media probably due to indecorous messages conveyed by some of the participants on their play-cards. I shall discuss the symbolic meanings of the messages sometimes later and focus only on the move itself.
When it comes to society, women in Pakistan are generally expected to behave in a pattern defined by man. At the atomic level an average married woman has to confirm the supremacy of her husband (traditionally the head of the family) and an unmarried one is usually under the influence of her mother, father and brothers. The mother which is under the influence of her husband usually reinforce the patriarchy. The collective equilibrium of all these forces create the picture of woman in society.

it is seemingly not the the real female issues that provoked the fierce remarks rather it is the male attitude in Pakistan towards female issues.


Generally speaking, it is seemingly not the the real female issues that provoked the fierce remarks we received as message on Women Day rather it is the male attitude in Pakistan towards female issues. As for the laws in Pakistan they are generally women friendly and at par with other countries. It is however not the law but the social pressure and general male attitude which intimidate the women to access the rights and privilege that usually a male enjoys.
Written and Posted by Salam Esapzay on 11-03-2019

Things You Should Know Before You Visit Fishery

 Karachi Fishery is not only a prime commercial market for wholesale fish supply across Pakistan but also a good place for Karachiites to buy varieties of fresh seafood at comparatively low rates. Read this article if you have plans to visit this place the next time.


Losing its bites when the cold Siberian waves finally reach Karachi it is time for Karachiites to plan activities specific to the season, one of which is, to rush around tables containing seafood specially fried fish. To kill my appetite and boredom with the same arrow I planned to visit Karachi Fish Harbour the next saturday partly to see how things work here and partly to buy some of the things this place is famous for. The next morning at O'clock I along with Adnan, my brother, got ready to make it happen.
On driving seat of my car, the first problem that I encountered was to locate accurately the place I had to reach. Thanks to google maps which not only did locate my destination on the vast planet Earth but also guided me on my route to the destination. It happened that the Fishery is at @24.8483957 ,66.9776966 latitude and longitude alongside the famous Maripur Road. If you are travelling from Merewether Tower you need to go down the Jinnah Flyover to touch West Wharf Road which leads to the Karachi Fish Harbours. Anyway in these days perhaps the google maps will explain much better than this description so I leave further probe to the company.

The moment I felt stench of rotten fish I realized we must have reached about the destination. The stench was normal and after a while it did not felt at all perhaps because our nostrils have adapted well to the new environment. Paying RS-20/ parking fee at the gate the security guard loosen the rope to let me enter into the parking area. I found the parking area large enough to park my car anywhere the place without any hurdle. Located at separate pace Fishery is not a place for general public and probably due to this, there is little to no concern for incidents like theft from cars here as the place has no attraction to things-lifters. Making necessary precautions as locking your car appropriately you should feel safe while shopping here.

As soon as I grounded myself out of car I encountered a group of teenagers asking my requirements. At first I ignored them as I felt they are getting advantage of me for being a newcomer. The young guys were, however, neither offensive nor over-active and unlike market-guys I found them humble, shy and to some degree helpful. Probing later it opened that the guys are actually doing fish skinning and the benefit for this engagement is to let the purchased fish be skinned through them. One of the guys guided us to the main market area where the buyers were found negotiating with sellers over price, quality and quantity and it is there that I handover the charge to Mr. Adnan and silently observing and processing the data I received through my senses.

The area I found myself in was divided into five main divisions (1) the boarding area where fisherman moor their launches (2) The controlling area where the Authority keep their offices (3) the market where local buyers and sellers engage (4) Utility companies such as ice thrashing and packing facilities (5) The surrounding which includes parking, mosque, hotel, banks and skinning area. Allocated space for Karachi fishery is large enough to contain all these sections.

5 Wrong Assumptions on Polio Vaccination

 A baseless propaganda against polio vaccination is observed on social media for some days by individuals of certain mindset urging others not to vaccine their children on basis of groundless assumptions.

Not going into details of words uttered by each Tom, Harry and Dick in scattered streets of Pakistan about conspiracy theories we are focusing mainly on debunking those reasons that are somehow propagated on social media as outcome of some sort of serious research in this regard. Following are most common misconceptions regarding this subject.


  • That the vaccine is invention of the Jews and Christians
  • That the vaccine itself contain polio virus
  • That there is no laboratory to test vaccine safety
  • That why do they (WHO and West) worry so much about our health?
  • That why our government use Police force to impose vaccines?
Polio vaccine is invention of Jews and Christians
Not only does the polio vaccines but a lot more things are also made by Jews and Christians than why not prohibit all of them? A car made by a Christian, according to this theory, may contain virus in its dashboard intended to harm the Muslim driver that may drive it. From a simple cough syrup to a cancer cure , there are many medicines the inventions of which are credited to people of other religions specially Christians and the Jews, so this is not a reason that anything prepared by them should necessarily be harmful for Muslims.

That the vaccine itself contain polio virus
Yes, the vaccine contain polio virus but inactive and without antigens. All vaccines contain sample of inactive viruses for introduction and identification of the same to the human immune system so that whenever the system encounters one it has already developed force to fight with it. So it is baseless to say that Polio is transmitted through polio vaccines itself because it contain polio virus. Had this the case every hospital should have filled with polio patients up to now.

There is no laboratory in Pakistan to test vaccine safety
Obviously a wrong assumption as polio vaccines are tested by Drug Control Authority of Pakistan and has found nothing harmful. Click here and here to read details in this regard.

Why WHO is so much worried about our health?
They do worry not because that they are in some emotional relation with you but because you are part of the same system that they are living into. Unless polio virus is eliminated completely from the entire system there always be chances that other entities of the system can be infected through transmission of virus from an infected element of the same system. By now many countries in the world have effectively eliminated polio except Afghanistan, Nigeria and Pakistan which has persistent reports of Polio discovery every year. That is why WHO has focus on Pakistan and Afghanistan in this regard.




Why our government use police for polio vaccines
Because there are elements in Pakistan who kill the innocent polio workers which are declared by these elements as part of international biological warfare against Muslim population. The Police is there not to force your children to be vaccinated but for the safety of Polio workers who refused to work without proper safety measures.

Logos

 



Marksheetz

 


                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

File: ESL4U

  m