Udy's engravings

Creating a new dimension …

How to join/merge mp4 files in ubuntu?

Posted by Udy on December 31, 2009

Do you have multiple .m4v files and is looking forward to join them?  Then, I hope this post will help you.

What is required?

ubuntu 9.10 Karmic
Install gpac packages to install MP4Box tools.
sudo apt-get install gpac

Once you’ve done it, you can use the Mp4Box command to concatenate the files together:

MP4Box -cat file_01.m4v -cat file_02.m4v -cat file_03.m4v -new final.m4v

This will create a merged m4v file ready do be used.

NOTE: MP4Box will be able to concatenate only 20 files at a time.

DISCLAIMER: The script helps in processing more files, which is handy.  However, note that I still find multiple tracks in the target (sporadically), which I presume is a bug in MP4Box.  Otherwise, most of the time, this script has helped me.

Here is the script

#!/bin/bash

##################################################################
# mergeM4V.sh
# Merges multiple m4v files
#
# USAGE: mergeM4V.sh -d "dir1 dir2"
#
# OUTPUT: final.m4v (override this with -o new_target_name.m4v)
#
# The tracks (audio and video) are processed separately,
# if you want to avoid this, use -i option to ignore such
# processing.
##################################################################

DIRS="."
OFILE=""
TARGET="final.m4v"
USE_PARAMS=1

while getopts "d:o:i" opt; do
 case $opt in
 d)
 DIRS=$OPTARG
 ;;

 o)
 TARGET=$OPTARG
 ;;

 i)
 USE_PARAMS=0
 ;;

 :)
 echo "USAGE: $0 -d dir_list [-o output_file] [-i]"
 exit 1
 ;;
 esac
done

MP4BOX_PARAMS=""
PARAMS_1="#1:fps=23.976"
PARAMS_2="#2"

MP4BOX_OPT=""

first=0
scale=4
page_size=10

listing=""
for dir in $DIRS; do
 listing="$listing $dir/*.m4v"
done

# convert to an array for easy access
count=1
for item in $listing; do
 array_listing[$count]=$item
 count=$((count + 1))
done

page_size=10
total_files=`echo $listing | wc -w`
page=1;
pages=$(($total_files / page_size))
last_items=$(($total_files % page_size))

# Work on the array
index=1

while [ $page -le $pages ]; do
 count=1
 mp4box_args=""
 while [ $count -le $page_size ]; do
 if [ $USE_PARAMS == 1 ]; then
 mp4box_args="$mp4box_args -cat ${array_listing[$index]}$PARAMS_1 -cat ${array_listing[$index]}$PARAMS_2"
 else
 mp4box_args="$mp4box_args -cat ${array_listing[$index]}"
 fi

 count=$((count + 1))
 index=$((index + 1))
 done

 OFILE="ofile_${page}.m4v"
 MP4Box $MP4BOX_PARAMS $mp4box_args -new $OFILE
 page=$((page + 1))
done

if [ $last_items -gt 0 ]; then
 count=1
 OFILE="ofile_${page}.m4v"
 mp4box_args=""

 while [ $count -le $last_items ]; do
 if [ $USE_PARAMS == 1 ]; then
 mp4box_args="$mp4box_args -cat ${array_listing[$index]}$PARAMS_1 -cat ${array_listing[$index]}$PARAMS_2"
 else
 mp4box_args="$mp4box_args -cat ${array_listing[$index]}"
 fi
 count=$((count + 1))
 index=$((index + 1))
 done

 MP4Box $MP4BOX_PARAMS $mp4box_args -new $OFILE
fi

mp4box_args=""
for ofile in `ls ofile*`; do
 if [ $USE_PARAMS == 1 ]; then
 mp4box_args="$mp4box_args -cat $ofile$PARAMS_1 -cat $ofile$PARAMS_2"
 else
 mp4box_args="$mp4box_args -cat $ofile"
 fi
done

MP4Box $MP4BOX_PARAMS $mp4box_args -new $TARGET
rm ofile*.m4v

exit 0

Posted in Linux | Tagged: , , | Leave a Comment »

5 Minutes on Java – Playing with XML and Java

Posted by Udy on November 26, 2009

Marshelling/unmarshelling of XML is very common.  JAXB and XStream come to my mind when ever I need to work with XML and Java.

Recently I had an interesting conversation with my colleague, he preferred JAXB over others for the following reasons

  • He wanted to use something that is as good as intrinsic of the language.
  • He did not mind the over head of using annotations.
  • nor did he want the dependency on a vendor or get into sustainability issues.

After having thought for a while, I realized software and bugs go hand in hand.  When it comes to delivering projects on schedule, reducing the coding time/complexity is good.  Thirdly, when a vendor has already done a good job of validating the concepts, why not use it in the given constraints.

XStream is equally powerful, in my experience (perhaps I’ve over simplified it), but for the purposes of the tasks I’ve used it for, it has really proven its metal.

The selling points from my point of view is:

  • I really don’t have to care about the XML schema/schema generation tools to work with.
  • When POJO’s are involved, I can marshall/unmarshall it as XML document using a single API call.
  • Once the Java objects are constructed, it can used as ever before.

Everything is good, except for the sustainability part, however, knowing the way Java has touched the lives of billions, sustainability is not a concern as of today.  Perhaps there is more of a organizational standard that forbids you from using XStream.

Check out the tutorial from http://xstream.codehaus.org/tutorial.html

Here is how I’ve used it to convert an XML stream to a Java object

@POST
@Consumes (“application/xml”)
@Produces (“application/xml”)
public Response postHandler(InputStream input){
String object = input.toString();

URI uri = uriInfo.getAbsolutePathBuilder().path(object).build();
logger.debug(“Received Object: ” + object);

StringBuffer buff = new StringBuffer();

XStream xstream = new XStream(new DomDriver());
xstream.alias(“data”, MyData.class);

MyData data = (MyData) xstream.fromXML(input);

}

Now sending a XML stream to user is as simple as creating it.

class MyData {

String toXML(){

XStream xstream = new XStream(new DomDriver());
xstream.alias(“data”, MyData.class);

return xstream.toXML(this);

}

}

Learning: if something can be done in few steps, let’s do in just those few steps :)

If there is something that you feel is better, please let me know.

Posted in Java | Tagged: , , , , , | Leave a Comment »

HISTORIC AUDIT ANALYSIS

Posted by Udy on November 23, 2009

Looking back in time can give us clues on things that were overlooked or neglected.  However, looking back in time is tough when there are no facilities to do so.

Imagine a scenario where you’re an escalations manager.  The bugs database records all information about incidents and records its intermittent states.

Having the transactional information, as a manager you wanted a root cause analysis done.  This process involves going back in time and finding out how much time was spent in each phase of an escalation process.

However, this posses a challenge when such a trace back mechanism does not exist in the system.  However, most systems will have audit trail recorded somewhere, which can be used to build a time travel to the past.

To fill this gap, a prototype from SAP Business Objects Innovation centre, Dublin can be used.  The tool is handy in scenario where you do not have a mechanism to go back in time, but want to use audit trail to look back.

You can find out more about this from our web-site – http://www.sdn.sap.com/irj/boc/innovation-center?rid=/webcontent/uuid/f00641ea-8ab2-2c10-d092-b9472eef434c

Please do give your feedback and let us know how useful this was for you.

Posted in SAP BusinessObjects | Tagged: , , , , | Leave a Comment »

ubuntu karmic koala and eclipse 3.5.1

Posted by Udy on November 5, 2009

Buying into the hype of ubuntu, recently I moved away from openSUSE 11.1 to ubuntu (on a urge to use Empathy as my default IM client).  Migrated most of the data and things seem to be going well so far.

What I liked?

  • gwibber client (can finally work in one console for twitter and Facebook)
  • Empathy (need not switch to Skype for voice chat, I can now talk to my Gmail contacts).   This was a failure on OpenSUSE, didn’t work as expected.  Hopefully this is fixed in 11.2 and I can move back soon.
  • SBackup (works well, so far data has not got corrupted)
  • Evolution (works fine as before)
  • VirtualBox (the latest release is very stable, the performance is good.  So far the virtual image works like a charm).

What needed to be added explictly?

Thinkpad fingerprint reader was not enabled, had to install libpam-thinkfinger (used synaptic package manager).  OpenSUSE is been good at this, the integration of fingerprint reader with authentication is a seamless experience.

Refer http://www.thinkwiki.org/wiki/Installing_Ubuntu_9.10_%28Karmic_Koala%29_on_a_ThinkPad_T61 to enable fingerprint reader.

What’s buggy and annoying?

The major glitch I found is with Eclipse, the buttons in most of the dialog boxes became unresponsive and was unable to find out what was going on for a while.  Did few experiments and then found that using open jdk messed up things a little – some of the contextual menu items seemed to be missing (for importing the projects and few of the import sources missed), and this prompted me to move to SUN JDK, which got back the lost context menu and import source items.  However, the glitch continued with buttons in most of the dialog boxes.

Solution:

  • Focus the button with a mouse and then hit the good old keyboards “Return/Enter Key”
  • Launch eclipse with GTK+ client side windows enabled.  This flag when set, will let GDK create all windows as native windows. This can help applications that make assumptions about 1-1 correspondence between GDK windows and X11 windows.  (This is better than the first proposal)
export GDK_NATIVE_WINDOWS=true
eclipse&

Eclipse installed from ubuntu repo and eclipse downloads has been tried with these solutions.

Configuration: IBM Thinkpad T60p, Dual Core, 3GB RAM, ubuntu karmic koala

Posted in Linux | Tagged: , , , , , , | Leave a Comment »

Twitter for Business Intelligence …

Posted by Udy on October 12, 2009

Few simple tools become so popular over time that it gains importance in everyday life.  One such tool is Twitter.

With respect to knowing the latest happenings around the globe, its tweets reach out faster than other ways.  Sometimes, tweets are much more efficient.  For instance, on demise of Michael Jackson, some search engines (like Google) became unresponsive due to overwhelming traffic on the subject.  However, the twitter served the community.  Not the best way, but it served the purpose.

With respect to businesses, it can improve customer service by using twitter.   When some bad thing has been said about its product, the customer service can proactively reach out to its customer and help them.  This becomes an opportunity for customer excellence and pride for the business.

The information is abundant and the possibility of what can be done with it is endless.

Thousands of tweets are happening every minute, and Twitter has this knowledge.  Businesses must just look for ways to analyze and explore possibilities.   Few of it can be useful for businesses to empower voice of customer, perform strategic marketing and sales and so forth.  Honestly, the possibilities are endless.

Twitter’s popularity has surged up certain services, some essential services for bringing intelligence are:

Search – http://search.twitter.com/

Monitter – http://monitter.com/

Tweetscan – http://tweetscan.com/

TweetVolume – http://tweetvolume.com/

Other tools – http://neoformix.com/

Opportunities in Twitter mining and intelligence are immense, which requires integration of businesses with twitter services for better growth prospectus.

Use Cases:

  1. Find out which products are bragged about around the sold regions.

One can determine the best selling and not so selling products.  This helps in preparing strategies and marketing plans, positioning sales.

  1. Find out about how satisfied customers are with products.

One can determine customer opinions and improve service quality.

Translating such business needs for twitter mining and incorporating analysis capabilities provides opportunities for business insights.  The concept is demonstrated by “TweetVolume”.

By searching key artefacts on twitter one can mine data.  The data from Twitter can then be processed by text analysis tools that allow categorization, processing and conversion of these data into some useful information.  The information generated is used for analysis and business intelligence.

Twitter_BI

Opportunities for SAP Business Objects:

  1. How to make the simple 140 characters data meaningful?
  2. Information Extraction is an area for Text Analysis tools.  The purpose of which is to analyze data from twitter mining, create useful artefacts that can be used for analysis.
  3. Garbage-in = Garbage-out: weeding out garbage data from the mined twitter data is an opportunity for data quality.
  4. Analysis and Reporting on extracted information.
  5. Continuous process of events using Live-Enterprise.  Instead of pulling data for information extraction, Live-Enterprise provides opportunity to push data.  This is excellent for real-time analysis and reporting.

Posted in Technology | Tagged: , , | Leave a Comment »

An ideal mutual fund portfolio (Indian market specific) – Revisited in Sep 2009

Posted by Udy on September 12, 2009

The Indian market is showing a sigh of relief and the time has come to say that it is good and book some profits or at least re-balance the portfolio.

Tactic 1:  Book profits

  • Switch from Mutual funds to Fixed Deposit (FD interest rates are low, at least provides cushion during tough times)
  • Invest interest earned from FD into mutual funds (at least quarterly)

Tactic 2: Re-balance portfolio

The new recommendations (unless otherwise stated, all funds are considered to be Growth Plan):  Based on August 2009 research.

My suggestion is to hold on to this folio for next 3 years and re-evaluate.

  • Equity Diversified: HDFC Top 200, Reliance Growth, IDFC Premier Equity Plan A, Reliance RSF – Equity
  • Balanced: HDFC Prudence
  • ELSS: Sundaram Tax Saver – Dividend Payout
  • Index: HDFC Index – Sensex Plus
  • Liquid: HDFC Cash management Fund

NOTE: All funds performance is evaluated on 5 year performance track period, also considering the slump period of 2007-2008.

Tactic 3: Look into different avenues

  • Real-estate is down by at least 20% enter there and stay for few years
  • Look for a business opportunity and invest into it, start or become a partner in a venture :)

Think big, go small by small.

Posted in Investments | Tagged: , | Leave a Comment »

Boosting performance of VMWare …

Posted by Udy on July 2, 2009

Virtualization provides benefits of running multiple OS, however sometimes raises challenges of performance depending on the resources available.  Here are some quick settings to boost performance.

Assumption:

Need to run VMware on a desktop with at least a Dual Core 2 configuration, 4GB RAM and ample diskspace for VMWare image.

Generic Practice, here is how to do.

Fit all virtual VMEM into reserved host.

Fit all memory into reserved host RAM

Disable Software Updates

Disable check for software updates

Disable automatic upgrade of VMWare tools

Disable automatic upgrade of VMWare tools

Remove unnecessary devices (like floppy, cdrom, and others)

Remove unnecessary devices

Disable memory page trimming

Disable memory page trimming

Finally add the below parameters into .vmx file

sched.mem.pshare.enable = “FALSE”

To learn more about which paramaters you may need,  visit http://www.sanbarrow.com/vmx.html

Hope this helps to improve the vmware a little :)

Posted in Technology | Tagged: , , , | Leave a Comment »

The Future of Information Systems in a nutshell

Posted by Udy on June 29, 2009

To understand how the future is let us start with current trends in hardware:

  1. Multi-Core and parallel computing technologies: Bringing the power of multi processors and parallel computing to the masses (which was only seen possible with high end mini/main/supercomputers in the past).
  2. Improvements to virtualization: Go full throtttle with multi-cores by using virtualization, systems are pushed to the maximum capacity by running more than one Operating Systems at a time.
  3. Improvements to network infrastructure: Gigabyte networks, perhaps pave ways to terabyte networks soon.
  4. Convergence of devices (phone, camera, gaming consoles, audio/video players, computer): Pushing electronics to do more than expected.
  5. Lower hardware costs (memory, processor and everything)

Followed by trends in software:

  1. Cloud/Grid: Do I really need to buy, install and manager operating systems or applications locally, when I can run them on a resourse somewhere?
  2. On Demand/Software as Service: I’ll pay only for the service I’ll use and depending on how often I’ll use.
  3. Social Networking: Focusing on collaborative applications.
  4. In memory content: Shrinking hardware costs and higher bandwidth will let softwares forget about memory or resource availability concerns.

The above two trends helps to drive the following business needs:

  1. Shrink costs (IT, Software, hardware, maintenance)
  2. Bring value (win customers loyalty with great services, technology is not a niche anymore)
  3. Synergy (one place is good for everything; too many stuff depreciates the value of the system.  I personally like the Google and Microsoft’s approach on collaborative tools)
  4. Speed (Be flexible and agile to add new services in demand)

While organizations push technologies to a space where software application will no longer run on a physical box, the limitations of current technologies will be forgotten soon.  Perhaps one can imagine a future where everything is on the network.  The Operating system is your browser on a net book; the applications will be served to you based on your subscriptions, and you will pay fees based on your usage.  All this seems cool and the solutions are coming up slowly, if not now, this could be the case 3-4 years from now.

What could be in demand (to name a few)?

  1. Cyber security and policing
  2. Information centric web (Windows Mesh, Google docs, Salesforce and alike)
  3. Collaborative Tools (Google wave)
  4. Parallel programming skills (we’re not using the 100% effectiveness of the resources one has today, not all applications are developed with this in mind)

Factors to consider:

  1. Bring end users to adopt this trend
  2. Make end users feel secure (don’t let Sky Net take over)
  3. Turn business monopoly to multi-organizational teams

Solutions can be found for the challenges with new technologies invented.  For all this to happen, we need people to make them happen, without the right people, all these are just dreams.

Summary:

Change with the wind and catch up with the technology, think business cloud, innovate and move forward.  What matters is what you contribute to the change and how you will be the change.

Posted in Technology | Tagged: , , , | Leave a Comment »

5 Minutes on Adobe Flex – A new collection …

Posted by Udy on June 24, 2009

A Name Value Pair associates a name with a value that is an attribute, which may be used to make a list country-capital pairing;

Name value pair becomes very useful when combined with associative arrays to perform lookup, eliminate duplicates and so forth.

Name                  Value
India                     Delhi
Afghanistan       Kabul
Argentina           Buenos Aires
Australia            Canberra
Bahrain               Manama

My requirement is to have the name value pair, with support for multiple values, a hobby-friends list such as the one below can be created …

Hobby          Friends
Painting        Sushma, Nitha, Prathiba
Sketching     Kumar, Naveen, George
Karate           Tony, Rakum, Gautam
Dancing        Nataraj, Ravi, Naveen
Cooking        Sampath, Lisa
Trekking      George, Kumar, Gautam

such a list can be built for classifying items.

source for class NameMultiValuePair.as is used to constructe a single Name Value Pair item

package
{
 public class NameMultiValuePair
 {
 private var key:Object;
 private var values:Array;

 public function NameMultiValuePair()
 {
 key = new Object();
 values = new Array();
 }

 public function setKey(k:Object):void
 {
 key = k;
 }

 public function add(v:Object):void
 {
 values.push(v);
 }

 public function getValues():Array
 {
 return(values);
 }

 public function getKey():Object
 {
 return(key);
 }
 }
}

You can create a collection using NameMultiValuePairSet.as which is listed below.

package
{
 public class NameMultiValuePairSet
 {
 private var entries:Array;

 public function NameMultiValuePairSet()
 {
 entries = new Array();
 }

 public function length():uint
 {
 return entries.length;
 }

 public function getKeys():Array
 {
 var keys:Array = new Array();
 var pair:NameMultiValuePair;

 for(var idx:uint = 0; idx < length(); idx++)
 {
 pair = entries[idx] as NameMultiValuePair;
 keys.push(pair.getKey());
 }

 return keys;
 }

 public function getKeyAt(idx:uint):Object
 {
 if(idx < 0 || idx > length())
 {
 return null;
 }

 var p:NameMultiValuePair = entries[idx];
 return p.getKey();
 }

 public function getItemAt(idx:uint):NameMultiValuePair
 {
 if(idx < 0 || idx > length())
 {
 return null;
 }

 return entries[idx];
 }

 public function contains(key:Object):Number
 {
 var pair:NameMultiValuePair;

 for(var idx:uint = 0; idx < length(); idx++)
 {
 pair = entries[idx] as NameMultiValuePair;
 if(pair.getKey() == key)
 {
 return idx;
 }
 }

 return -1;
 }

 public function getValues(key:Object):Array
 {
 var pair:NameMultiValuePair;

 for(var idx:uint = 0; idx < length(); idx++)
 {
 pair = entries[idx] as NameMultiValuePair;
 if(pair.getKey() == key)
 {
 return(pair.getValues());
 }
 }

 return null;
 }

 public function put(key:Object, value:Object):Boolean
 {
 var p:NameMultiValuePair;

 if(length() == 0)
 {
 p = new NameMultiValuePair();
 p.setKey(key);
 p.add(value);

 entries.push(p);
 return true;
 }

 var keyIdx:Number = contains(key);
 if(keyIdx > -1)
 {
 // key already exists, add new value to the exiting key
 p = getItemAt(keyIdx);
 p.add(value);

 return(true);
 }
 else
 {
 // key does not exist; you can add it as a new Pair
 p = new NameMultiValuePair();
 p.setKey(key);
 p.add(value);

 entries.push(p);
 return true;
 }

 return false;            
 }
 }

}

Suppose if you want to just have a name value pair with a single value then NameMultiValuePairSet.as can be tweaked a little as listed below to.

package
{
 public class NameValuePairSet
 {
 private var entries:NameMultiValuePairSet = null;

 public function NameValuePairSet()
 {
 entries = new NameMultiValuePairSet();
 }

 public function put(key:Object, values:Object):Boolean
 {
 if(entries.contains(key) == -1) {
 entries.put(key, values);
 return true;
 }

 return false;
 }

 public function getKeyAt(idx:uint):Object
 {
 return entries.getKeyAt(idx);
 }

 public function getKeys():Array
 {
 return(entries.getKeys());
 }

 public function getValues(key:Object):Array
 {
 return(entries.getValues(key));
 }

 public function length():uint
 {
 return(entries.length());
 }
 }
}

The entire source above is demonstrated using the code below:

package
{
 public class DS_Demo
 {
 public function DS_Demo()
 {
 nameMultiValuePairDemo();
 nameMultiValuePairSetDemo();
 nameValuePairSetDemo();
 }

 public function nameMultiValuePairDemo():void
 {
 var p:NameMultiValuePair = new NameMultiValuePair();
 p.setKey("Bingo");
 p.add("Hurray");
 p.add("Hip-Hip");
 p.add("Jingle Bells");

 trace(
 "key => " + p.getKey() +
 "\t\t" +
 "values => " + p.getValues().toString()
 );
 }

 public function nameMultiValuePairSetDemo():void
 {
 var hm:NameMultiValuePairSet = new NameMultiValuePairSet();

 hm.put("1", "A");
 hm.put("2", "B");
 hm.put("3", "C");
 hm.put("4", "D");
 hm.put("5", "E");

 hm.put("1", "L");
 hm.put("1", "M");
 hm.put("1", "N");

 hm.put("2", "I");
 hm.put("3", "J");
 hm.put("4", "K");

 for(var idx:uint = 0; idx < hm.length(); idx++)
 {
 var key:Object = hm.getKeyAt(idx);
 trace(
 "key => " +  key +
 "\t\t" +
 "values => " + hm.getValues(key).toString()
 );
 }
 }

 public function nameValuePairSetDemo():void
 {
 var hm:NameValuePairSet = new NameValuePairSet();

 hm.put("1", "A");
 hm.put("2", "B");
 hm.put("3", "C");
 hm.put("4", "D");
 hm.put("5", "E");

 hm.put("1", "L");
 hm.put("1", "M");
 hm.put("1", "N");

 hm.put("2", "I");
 hm.put("3", "J");
 hm.put("4", "K");

 for(var idx:uint = 0; idx < hm.length(); idx++)
 {
 var key:Object = hm.getKeyAt(idx);
 trace(
 "key => " +  key +
 "\t\t" +
 "values => " + hm.getValues(key).toString()
 );
 }
 }
 }
}

Posted in Adobe Flex | Tagged: , , , , | Leave a Comment »

Comprehensive plan for a healthy and wealthy family

Posted by Udy on June 16, 2009

We all aim to be successful, earn money and live the life without limitations, yet only a percentage of us can do it, this raises a couple of questions which can lead one to the answers.

  • Why is that?
  • What goes wrong?
  • What can be mended to set the course right?
  • Can we repeat somebody’s success?
  • Do you wonder if you can repeat success?
  • Did you ever

Dream: I want to be millionaire, leaving fortunes behind for generations …

Desire: I wish my parents left me a fortune so that I did not have to work …

Had anguish: When am I going to stop working for money?

Then I assume that we’re normal human beings trying to make our way in our lives … The belief “everything is possible” and the positive attitude is an essential ingredient … however, the time we begin amassing wealth changes the status quo on how much one can achieve. So, looking at various stories one can draw a blueprint and say, you can repeat the success stories and achieve some of it (if not entirely).

Here are some tactics that can work: I welcome readers to contribute so that this tactics becomes useful…

Financial Intelligence: Having information to make decisions is the corner stone to success.  Always maintain log of income, expenses, and investments to generate statements or reports of your net worth, balance sheets to evaluate your situation and plan.

It’s never too late: A percentage of earnings is set aside for savings.  Check out Power of investing early which demonstrates the fact that the persistence maintained is well paid.  No matter what, consider this amount written off until you retire.  Hard to do, but this becomes a foundation for the future.

Take one at a time: Must remember that can’t get everything on day one.  When it comes to everything, it directly translates to bad debts, instead hit small by small, one by one to move ahead.  Which can also get rid of debts in all forms?

Managing debts: The first five years of interest payments will drain you; ideally if you can clear those debts during the first 5 years, it’s wonderful.  Not in reality, but what I mean is, making 5 year plans is the right way to go.

Re-evaluating: Every 5 years, check the net worth, asset allocation.  Churn them around to make a difference.  For instance, after 5th year, when you’ve accumulated some money, use it to fund to buy real-estate, take a loan to fund the rest (this kind of churning is good).  But don’t stop the investments.  Sell it when essential, make profits, re-invest and keep moving forward.

Budgeting & Planning: Most important of all is the planning aspect, one will need a comprehensive plan for running a family; it takes a step to start and every step thereon leads to a better position, here is what a plan can look like (this is just a guideline, and it must be tweaked to suite the personal needs).  This section will serve has a functional instructions for a family to be run well by providing the best life by establishing good values, healthy living and frugal life style.

Objective:  Have a stated objective such as, “To provide the best life possible to family members, accumulate wealth and to contribute for a good cause of the family/community”.

Goals: Have a goal oriented approach, something like

  • Accumulate amount XXX,XXX for kids education in next 10 years
  • Accumulate amount Y,YYY for travel in next 3 years
  • Accumulate amount Y,YYY,YYY for retirement in next 20 years

Theory: Assuming after tax earnings as 100% one can split the earning into the following mandatory and optional pools, before we proceed talking about allocations, I like to add that frugality and understanding that being self-sufficient is a first step towards happiness.  In this materialistic world one forgets to live life within the provided means and tries to reach the luxuries quickly and with greed, which is where the whole world around us spins and halts.  Being successful does not mean that one should have the materials to substantiate it, in my opinion internal bliss and the sigh of fulfillment comes from within, in otherwise, being contempt within the provided means is the simplistic truth of being successful, and let this planning be the first step towards it.

Allocation at a glance

Allocation at a glance

Mandatory: 70% of the earnings are considered to be a mandatory portion, the 70% funds are allocated as per below mandate

60% – Investments: Driver for building wealth

60% – Equity-Debt: Allocation of Equity-Debt instruments is as stipulated below

100% Equity – Between ages 21-30

80%-20% - Between ages 31-40

60%-40% - Between ages 41-50

40%-60% – Between age 51-retirement

20%-80% - after retirement

The allocation in equity-debt must further be classified for a purpose as appropriate at every 5 years of life.

Education of children

Marriage of children

Retirement booty

Dream home project funding

High value assets

10% – Commodity: Assets like gold and sliver

This is essential, as it forms a good investment and also a good source of gift for family members.  Ideally, this 10% funds can be utilized to buy some ornaments on every anniversary, birthday or special occasion.

20% – Health & Life Insurance:

Ideally this is a risk cover component, and term cover insurance must be considered to help family survive a sudden demise.

10% – Emergency Fund:

The remaining funds should be kept in liquid form for emergencies, when this money accumulates to an amount which can help my family survive 6-12 months life without compromising lifestyle, it can be used to fund equity-debt investments.  This is ideal to manage a situation where a job loss can be sustained for at least few months.  The funds in buffer must be revisited every time a change in earning potential.

40% – Running Costs: The 40%  allocation towards runnings costs may not get consumed in the entire form, hence the following suggestions:

5% – Goodwill: Good to do this; be it family, friend, environment or a good cause, doing something here is a great achievement in itself.

15% – Education/Travel: Funding higher education, taking a trip should be done with this allocation.

The reminder 80% of the funds will be used to fuel family running costs which must ideally be at a level covering purchase of groceries, appliances, utility, transportation, education, paying rent and other house hold chores.  This way, the family runs the way it should meeting it’s demands and constantly builds wealth.

Optional: 30% of the remaining earnings are considered as optional allocation,which is allocated towards smart-credit as per below suggestions, smart credit is considered a good policy, where the funds are used to accumulate assets in long run.

80% – Mortgage: of which can be used for paying EMI towards home loans or other property loans essentially for buying assets.

20% – Auto: Purchase of auto must be made with at least 70% of auto cost towards down payment; the remaining 30% can be funded by credit, without exceeding the 20% cap on credit allocation towards auto.

Strategy or policy:

Family first: If  the immidiate family can’t survive, I do not think one will be able to support any good cause, so build the family to level of confidence such that even if the family is not survived by the bread winner, the family can be run as a self-sufficient entity, once this is attained, goodwill and charity will fall in place automatically.

Smart credit: Good credit is fine, bad credit is not allowed – Paying of credit cards, personal loans is the first priority.  In case of mortgage or good loans (funded to buy assets), ideally must be paid back in 5 years from the date of loan.  This avoids paying a huge sum towards interest and increases credit rating as well.  Where interest rates on credit availed is less than the rate of return on investments, it makes sense to stay invested, and in situations, where the interest rates are higher, it makes sense to pay them back at the earliest.

Investment: Review of investments every 5 years is a must, this ensures that the family goals can be reviewed and funds can be re-shuffled to meet the ever changing demands.

Key Responsibilities

Joint Account: Ensure accounts are jointly held or at least have nominations (Important ones: banks, investments, and real-estate).

Will: A will must be in force at all times, and must be reviewed when ever a major change occurs in family or any one of the above objectives change.

Finally, one thought about the whole context is being smart, the way funds are managed, and moved from one source to another based on timing, family conditions, market trends is the the key.  Once one gets a hold of the basics of budgeting and planning the rest is just about execution.

Posted in Investments | Tagged: , , , , , , , | 5 Comments »