Wednesday, May 28, 2008

Shell Scripting One Liners

To capture date parameters on shell
Day = date cut -d' ' -f1
Month = date cut -d' ' -f2
Date = date cut -d' ' -f3
Hour = date cut -d' ' -f4 cut -d':' -f1
Minutes = cut -d' ' -f4 cut -d':' -f2
Seconds = date cut -d' ' -f4 cut -d':' -f3

Monday, May 26, 2008

The Hot New Supernova

Stellar scientists announced last week that they've spotted the youngest supernova remnant ever seen in the Milky Way. Called "G1.9+0.3," the remnant's estimated age is just 140 years--meaning that's when the radio waves started reaching Earth. (The actual supernova happened 26,000 years ago.) How young is that, in supernova remnant terms? Until last week, the youngest remnant ever seen in our galaxy was a 330-year-old named "Cassiopeia A." So, why hadn't scientists spotted "G1.9+0.3" before, if its radio waves first reached us in the 1860s?
Because to see it, they had to peer through a thick cloak of interstellar dust. While astronomers pore over their super new data, we're here to help you understand what supernovas really are. It's all about the hot life and violent death of a big star.






A Star Is BornLike humans, stars are born through contractions--though the contractions here are not of muscle, but of massive clouds of gas and dust in interstellar space. Every now and then, such a cloud accumulates enough matter for gravitational forces to pull it together even more. A protostar is born, and gets hot. When the temperature near its center hits 18 million degrees Fahrenheit (10 million degrees Celsius), nuclear reactions kick in. Newborn stars are made mostly of hydrogen. At their cores, they "burn" hydrogen and generate helium. Of course, they don't use matches or flames. The burning at a young star's heart is a nuclear fusion reaction, in which four hydrogen atoms fuse to produce a single helium atom. The mass of that helium atom is less than the combined mass of the four hydrogen atoms, and the leftover mass is released as energy. The release of that energy drives the temperature inside the star way up--in some cases to hundreds of millions (even billions) of degrees Fahrenheit. Pressure inside the star increases enough to counteract the gravitational forces still trying to contract it. At the same time, heat pours from the star's core toward its cooler surface, and from there radiates into space. Presto: a relatively stable star is burning bright.Twinkle, Twinkle, Supergiant StarStars survive a long time by human measures, but eventually they all run out of gas, literally. And those that live larger burn out quicker. A relatively small star--like our sun--might burn for 10 billion years, and then linger for eons as a cosmic cinder called a "white dwarf." A star 10 times as massive might live just 10 million years, and then go out with a bang. When a star's core runs out of hydrogen to burn, it begins to contract again. The core's temperature increases until the helium made earlier ignites. Now a helium fusion reaction produces carbon and oxygen in the star's core, while hydrogen fusion fires up in a thin shell around it. The star generates far more energy than before, and puffs up accordingly. If the star started out modest, it grows into a red giant. If it started out big, it becomes a supergiant. Smaller stars' nuclear careers generally end with the burning of core helium. But big stars start burning the carbon and oxygen fused in the helium reaction, too. They go on to produce elements like neon, magnesium, silicon, and sulfur. Then they burn the silicon to produce iron. Such stars wind up layered like onions--with a central core of iron, surrounded by layers of burning silicon, magnesium, neon, oxygen, carbon, helium, and hydrogen.Out with a BangAfter taking several million years to grow up, a supergiant builds its iron core in about a day. At its peak, the iron core is around two-thirds the size of the Earth but contains more mass than the sun. It's also caught in an enormous gravitational crunch. The star's core no longer generates energy to counteract the forces of contraction--to fuse iron requires energy input rather than leading to energy release--so it can't hold out for long. When it goes, it goes fast. In less than a second, the core collapses from a 5,000-mile-wide sphere (8,000 km) into a 12-mile-wide one (20 km). The sudden crash releases a huge amount of energy--100 times the energy our sun will produce in its entire 10-billion-year life. Tiny particles called neutrinos carry most of that energy off into space. The rest races out through the star's layers in a supercharged shockwave. The resulting explosion blasts the star's gaseous shell into space at speeds exceeding 10 million miles per hour (16 million km/h). For a few weeks, this "supernova" burns brighter than a billion suns. And for millennia to come, the former star's gaseous shell plows into the interstellar medium. Meanwhile, the star's collapsed iron core carries on as a neutron star--or, in some cases, becomes a black hole. In the cosmos, it seems, big stars burn out and fade away.

Tuesday, May 20, 2008

A Camel In A Cage

A baby camel asked his mother, "Why do we have such large hooves on our feet?" She turned to him. "God made us that way for a very special reason," and she began her explanation. "The big hooves are to keep us from sinking into the sand."

"Oh! So why do we have long eyelashes?"

"It's to protect our eyes from the sand."

"Why the big humps?"

"That is to store fat and have enough energy to go long distances in the hot desert!"

"I see!" The baby camel stretched his neck and looked up at his mother, "The big hooves are to keep from sinking into the sand, the long eyelashes are to keep the sand out of our eyes, and the humps are to store energy to travel long distances--then what are we doing in this cage in the middle of a zoo?"

Like the camel, I had asked the same kind of questions. When my blindness set in, I initially locked myself in a cage of self-pity and bitterness. Weary from pacing within that gloomy cage, something nudged me to see beyond my circumstance and unfortunate plight.

Heavens! What was I thinking? Those bars were self-imposed. But worst of all, I'd supported them with the cold metal of my negative attitude.

Eventually, eagerness to leave my stuffy cell of discontent prompted me to open my ears to hear a reassuring whisper--God had created me for much more.

Itching to break free, I broke down those bars and stepped out into the desert of life. I trudged through the heat with determination and drive. I endured the blistering sun with perseverance and tenacity. I quenched my thirst with fresh inspiration and encouragement. And the hooves of confidence kept me from sinking into the sand of insecurity.

Thinking ahead, I made sure I'd stored a healthy supply of wisdom and positive attitude to take me through the long haul.

Goodness gracious. Each time I reached another point in my journey, my eyes saw a whole new world with opportunities to make a difference. Best of all, I was delighted with the affirmation that I was indeed created for much more! Bars come in all sizes and shapes. Some are physical, others are emotional or even mental. But none can withstand the force of determination that breaks them down. The effort is worth it and the results, simply amazing! So, batting my long eyelashes to keep out the sand of discouragement, I challenge you...

Step back and peek at what bars limit you. Take a deep breath, break them down, and emerge into the freshness of a new life!


What do you feel ??

Monday, May 19, 2008

Deadlock

Boss said to secretary: For a week we will go abroad,
so make arrangement.

Secretary make call to Husband: For a week my boss and
I will be going abroad, you look after yourself.

Husband make call to secret lover: My wife is going
abroad for a week, so lets spend the week together.

Secret lover make call to small boy whom she is giving
private tution: I have work for a week, so you need
not come for class.

Small boy make call to his grandfather: Grandpa, for a
week I don't have class 'coz my teacher is busy. Lets
spend the week together.

Grandpa(the 1st boss ;) ) make call to his secretary: This week I am
spending my time with my grandson. We cannot attend
that meeting.

Secretary make call to her husband: This week my boss
has some work, we cancelled our trip.

Husband make call to secret lover: We cannot spend
this week together, my wife has cancelled her trip.

Secret lover make call to small boy whom she is giving
private tution: This week we will have class as usual.

Small boy make call to his grandfather: Grandpa, my
teacher said this week I have to attend class. Sorry I
can't give you company.

Grandpa make call to his secretary: Don't worry this
week we will attend that meeting, so make arrangement

See how life catchs you from behind :)

Sunday, May 18, 2008

Secrets of Success

You will find the eight keys to success right there in your very own room where you are sitting now.

The Fan says BE COOL.
The Roof says AIM HIGH.
The Window says take PAINS.
The Clock says every minute is PRECIOUS.
The Mirror says reflect before you ACT.
The Calendar says be up-to-date.
The Door says push.
The Lamp says illuminate your mind by Education.

Listen to what things around are trying to tell you to achieve greater heights of success.


Friday, May 16, 2008

SideCar Investment

What Does it Mean?

An investment strategy in which one investor allows a second investor to control where and how to invest the capital. The sidecar investment will usually be used when one of the parties lacks the ability or confidence to invest for themselves. The strategy will place trust in someone else's ability to gain profits.

Investopedia Says...

The word "sidecar" refers to a motorcycle sidecar; the person riding in the sidecar must place his or her trust in the driver's skills. This differs from coattail investing, where one investor mimics the moves of another. For example, suppose there are two individuals - Fred, who is experienced in trading stock, and Barney, who has a background in real estate. They decide to work together in a sidecar investing strategy. In this case, Fred would give Barney money to invest in real estate on his behalf and Barney would give Fred money to invest in stocks. This setup allows both Fred and Barney to diversify their portfolios and benefit from one another's expertise.

Thursday, May 15, 2008

Happy For No Reason

From 'Happy for No Reason' by Marci Shimoff with Carol Kline. Copyright 2008 by Marci Shimoff. Reprinted by permission of Free Press, a Division of Simon & Schuster, Inc.


If you and I were sitting over some tea at a sidewalk café and I asked you, "Are you happy?," what would your answer be?

A few of you might say, "Absolutely—if I were any happier, I'd be twins!" (Okay, that would be a very few of you.)

A lot of you would probably reply, "Sometimes."

But I'd bet dollars to doughnuts that at least half of you would say, "No, not really."

Some people enjoy their lives no matter what happens, while others can't find happiness no matter how hard they try. Most of us fall somewhere in between.

The reason for this puzzling disparity is the happiness set-point. Researchers have found that no matter what happens to you in life, you tend to return to a fixed range of happiness. Like your weight set-point, which keeps the scale hovering around the same number, your happiness set-point will remain the same unless you make a concerted effort to change it.

In fact, there was a famous study conducted that tracked people who'd won the lottery—what many people think of as the ticket to the magic kingdom of joy. Within a year, these lucky winners returned to approximately the same level of happiness they'd experienced before their windfall. Surprisingly, the same was true for people who became paraplegic. Within a year or so of being disabled, they also returned to their original happiness level.

Whatever the experience—positive or negative—people return to their happiness set-point. Further research has shown only three exceptions to this phenomenon: losing a spouse, which can take more time to recover from; chronic unemployment; and extreme poverty.

Okay, you may be thinking, if my happiness level is set—how did it get there? Dr. David Lykken, a scientist at the University of Minnesota, had the same question. To determine how much of a person's happiness comes from nature and how much from nurture, Lykken and his team, in the late 1980s, began studying thousands of sets of twins, including a number of identical twins who had been raised apart. After extensive testing they found that approximately 50 percent of our happiness set-point is genetic and the other 50 percent is learned. Half of the reason you walk around generally cheery or perennially dreary is that you were born that way, the other half is determined by your thoughts, feelings, and beliefs formed in response to your life experiences.

In a recent review of the literature and studies on happiness, positive psychology researchers Sonja Lyubomirsky, Kennon Sheldon, and David Schaade confirmed Lykken's earlier findings that 50 percent of our happiness comes from our genetics. But more exciting was the new information they uncovered about the remaining 50 percent. It appears that only 10 percent of our happiness set-point is determined by circumstances such as our level of wealth, marital status, and job. The other 40 percent is determined by our habitual thoughts, feelings, words, and actions. This is why it's possible to raise your happiness set-point. In the same way you'd crank up the thermostat to get comfortable on a chilly day, you actually have the power to reprogram your happiness set-point to a higher level of peace and well-being.

The discovery of the happiness set-point and our ability to change it turns everything we've all believed about being happy upside down. We spend our entire lives searching for happiness, yearning for it, trying to get the things we are sure will make us happy: wealth, beauty, relationships, career, and so on. But the truth is, to be truly happy, all you have to do is raise your happiness set-point.

I sure wish I'd known I was just one of those people who had a low happiness set-point before spending so much time and energy chasing after reasons to be happy. From my interviews,

I've come to see that genuinely happy people are Happy for No Reason.

Saturday, May 10, 2008

Floating Rate Funds

Floating rate fundsFloating rate funds (or floaters as they are called) are just as critical in an uncertain interest rate scenario. These funds invest in floating rate debt instruments wherein the coupon rate is revised at regular intervals. Uncertainty in interest rates does not significantly impact the prices of floating rate instruments, because the coupon rate is adjusted (either lower or higher depending on the interest rate scenario) in response to the market rates. Again, given that portfolios of floaters are largely comparable, lower expenses are crucial in clocking a competitive return. While floaters come in both variants (short-term and long-term), opt for short-term floaters, which allow investors to redeem any time without paying an exit load (long-term floaters usually have an exit load on premature redemptions).

FMP Simplified

FMP's are investment instruments that are to be bought in the month of march. Since banks invite funds for investment for a very short duration of time, say a week or even less than that, in case you are interested in investing in FMP's, keep your eyes and ears open when March starts :)

Following piece of text would give some insight to what's and how's of Fixed Maturity Plans.

Fixed maturity plans (FMPs) have become popular amongst investors mainly as a foil for uncertain interest rates. FMPs by staying invested in a portfolio of bonds/government securities till maturity offer a relatively certain return despite their market-linked nature. During periods of uncertainty, the certain return offered by FMPs assumes even more significance. While FMPs are launched with varying tenures, go for the short-term FMPs (less than a year). If the interest rate scenario appears uncertain even after the FMP matures, you can consider rolling over to the next issue (provided the fund house is offering another FMP with a similar tenure).

Risks involved in FMP's: Visit this link :- http://www.personalfn.com/detail.asp?date=3/27/2008&story=2

Compare FD with FMP :-
http://personalfn.com/detail.asp?date=4/29/2008&story=1

Happy Investing.

Wednesday, May 7, 2008

Why do we cry

Following link gives one possible explanation about tears and why do we cry.
http://www.gibbsmagazine.com/CryinLaughing.htm

Let me know if you know something different.

Your Opinion Matters

Thoughts




How old would you be if you didn't know how old you are? - Satchell Paige

When I hear somebody sigh, 'Life is hard,' I am always tempted to ask, 'Compared to what?'

Consistency is the last refuge of the unimaginative.


What you do speaks so loud that I cannot hear what you say. - Ralph Waldo Emerson


Coincidence is when God chooses to remain anonymous.
- Unknown


Believe those who seek the truth; doubt those who find it.
- Andre Gide


If you aren't going to go all the way, why go at all ??



Self-discipline is when your conscience tells you to do something and you don't talk back.
- W.K. Hope


When you get to the end of your rope, tie a knot and hang on.


- Franklin D. Roosevelt


Climb up on some hill at sunrise. Everybody needs perspective once in a while, and you'll find it there.


- Robb Sagendorph


You give 100 percent in the first half of the game, and if that isn't enough, in the second half you give what's left.


- Yogi Berra


If I have learned one thing in this life, it is that God will not tie my shoes without me.


- Doug Boyd




The first sight of maturity is the discovery that the volume knob also turns to the left.


- Chicago Tribune




Grief can take care of itself, but to get the full value of joy you must have somebody to divide it with.


- Mark Twain


The art of acceptance is the art of making someone who has just done you a small favor wish that he might have done you a greater one.


- Russell Lynes


Education is when you read the fine print. Experience is what you get if you don't.


- Pete Seeger

Happiness makes up in height for what it lacks in length.
- Robert Frost
Always do right. This will gratify some people, and astonish the rest.
- Mark Twain

We must remain as close to the flowers, the grass, and the butterflies as the child is who is not yet so much taller than they are.

-Friedrich Nietzsche

Never mistake knowledge for wisdom. One helps you make a living, the other helps you make a life.

-Sandra Carey


You can easily judge the character of a man by how he treats those who can do nothing for him.

- James D. Miles



There are no more hours in a bad day than in a good one!
-Unknown

If you want to be happy for a year, plant a garden; If you want to be happy for life, plant a tree.
- English Proverb

I like nonsense; it wakes up the brain cells.

- Dr. Seuss

Nearly all men can stand adversity, but if you want to test a man’s character, give him power.

- Abraham Lincoln

To be nobody but yourself, in a world which is doing its best, night and day, to make you everybody else means to fight the hardest battle that any human being can fight--and never stop fighting.


If you want to lift yourself up, lift up someone else.
- Booker T. Washington

Always be nice to people on the way up; because you'll meet the same people on the way down.
- Wilson Mizner

Never confuse a single defeat with a final defeat.

- F. Scott Fitzgerald

Don't wait for your ship to come in. Row out to meet it.


There are years that ask questions, and years that answer.
-Zora Neale Hurston

If a friend is in trouble, don't annoy him by asking if there is anything you can do. Think up something appropriate and do it.
-Edgar Watson Howe


Challenge is a dragon with a gift in its mouth... Tame the dragon and the gift is yours.
-Noela Evans

You cannot prevent the birds of sorrow from flying over your head, but you can prevent them from building nests in your hair.

-Chinese Proverb


If you don't have the time to do something right, where are you going to find the time to fix it?

-Stephen King

Do all the good you can, in all the ways you can, as long as ever you can.
-John Wesley


A candle loses nothing by lighting another candle.

-Erin Majors

When you are reluctant to change, think of the beauty of autumn.

Conditions are never just right. People who delay action until all factors are favorable are the kind who do nothing.

-William Feather

Kindly words, sympathizing attentions, watchfulness against wounding men's sensitiveness--these cost very little, but they are priceless in their value.

-F.W. Robertson

Don't regret growing older. It is a privilege denied to many.

-Unknown

You cannot do a kindness too soon, for you never know how soon it will be too late.

-Ralph Waldo Emerson

Never stand begging for that which you have the power to earn.


-Miguel De Cervantes

If you don't stand for something, you'll fall for anything.

-Steve Bartkowski

Hope is like a road in the country; there wasn't ever a road, but when many people walk on it, the road comes into existence.

-Lin Yutang

Don't measure a man's success by how high he climbs but how high he bounces when he hits bottom.
-- General George S. Patton

Real courage is when you know you’re licked before you begin, but you begin anyway.

-- Harper Lee

The true measure of a man is how he treats someone who can do him absolutely no good.

-Samuel Johnson Submitted By Lifthimup

Tough times never last, tough people do.

-Robert Schuller

To look at something as though we had never seen it before requires great courage.

-Henri Matisse

The truth of the matter is that you always know the right thing to do. The hard part is doing it.

-Gen. Norman Schwarzkoff


If you're not using your smile, you're like a man with a million dollars in the bank and no checkbook.


-Les Giblin


Man improves himself as he follows his path; if he stands still, waiting to improve before he makes a decision, he'll never move.

-Paulo Coelho


The farther a man knows himself to be free from perfection,
the nearer he is to it.

-Gerard Groote


Every child comes with the message that God is not yet discouraged of man.
- Rabindra Nath Tagore

Avoid the crowd. Do your own thinking independently. Be the chess player, not the chess piece.

-Ralph Charell

Maturity is the ability to do a job whether or not you are supervised, to carry money without spending it, and to bear an injustice without wanting to get even.


-Ann Landers


Ask yourself: Have you been kind today? Make kindness your daily modus operandi and change your world.

-Annie Lennox

A person without a sense of humor is like a wagon without springs --jolted by every pebble in the road.
-- Henry Ward Beecher

Aim at Heaven and you will get Earth thrown in. Aim at Earth and you get neither.
-- C.S. Lewis

































Values are like fingerprints. Nobody's are the same, but you leave 'em all over everything you do.

--Elvis Presley


It’s the things in common that make relationships enjoyable, but it’s the little differences that make them interesting.

-- -Todd Ruthman

Courage is not the towering oak that sees storms come and go; it is the fragile blossom that opens in the snow.
-- Alice Mackenzie Swaim

Aim for the moon...even if you miss you'll land amoungst the stars.
-- Unknown

Often God has to shut a door in our face so that He can subsequently open the door through which He wants us to go.
-- Catherine Marshall

I gain strength, courage and confidence by every experience in which I must stop and look fear in the face...I say to myself, I’ve lived through this and can take the next thing that comes along.
-- Eleanor Roosevelt

Don't worry that children never listen to you. Worry that they are always watching you.
-- Robert Fulghum

Don't prepare the path for the child, prepare the child for the path.
-- Unknown

Everything works out in the end. If it hasn't worked out, it's not the end.
-- Unknown

Life consists not in holding good cards, but in playing those you hold well.
-- Josh Billings

Who does not thank for little will not thank for much.
-- Estonian Proverb

If you don't run your own life, someone else will.
-- John Atkinson

To love oneself is the beginning of a lifelong romance.
-- Oscar Wilde

Praise and blame, gain and loss, pleasure and sorrow come and go like the wind. To be happy, rest like a giant tree in the midst of them all.
-- Buddha

Live so that when your children think of fairness, caring and integrity, they think of you.
-- H. Jackson Brown, Jr

Kind words can be short and easy to speak, but their echoes are truly endless.

-- Mother Teresa

To exist is to change, to change is to mature, to mature is to go on creating oneself endlessly.

-- Henri Bergson

Success is not the key to happiness. Happiness is the key to success. If you love what you are doing, you will be successful.

-- Albert Schweitzer

We have bigger houses, but smaller families.
More conveniences, but less time.
We have more knowledge, but less judgements;
more experts but more problems;
more medicines but less health.
We have been all the way to the moon and back, but have trouble crossing the street to meet the new neighbour.
We build more computers to hold more information, to produce more copies than ever, but have less communication.
We have become long on quantity but shot on quality.
These are times of fast foods, but slow digestion;
tall men but short character;
steep profits but shallow relationsihps.
It is a time
When there is much in the window, but nothing in the room.
--The Dalai Lama

Destiny is no matter of chance. It is a matter of choice. It is not a thing to be waited for, it is a thing to be achieved.
--William Jennings Bryan


I shall try to handle anything that life throws at me - I may not able to handle it well, or correctly, or gracefully, or with finesse or expediently - but I will handle it. Life may not be the party I hoped for, but while I am here, I might as well dance !!!



Making of a Good Human Being

Great occasions do not make heroes or cowards; they simply unveil them to the eyes. Silently and imperceptibly, as we wake or sleep, we grow strong or we grow weak, and at last some crisis shows us what we have become.
-Bishop Westcott

Here Mr. Westcott has rightly said that events do not make heros or devils, they just bring out their nature. Having said this, can we ensure that being as parents, we can make our children appropriate circumstances in order to bring out their talents and suppress their devils.

In case you have any comment on this, do share.

Your Opinion Matters