Need help with my mini project!!

The program compiles properly and it evaluates properly but when uploaded upon a an arduino board it fails to work when a surfed over the web i ended up stating 2 different solutions first is that a serial buffer is to be added and the second solution is that to try a different method than using serial software serial and another problem is that the functions aren’t placed properly so ideas are invited to place the functions wherever required.
Thanks in advance

#include <SoftwareSerial.h>
#include <TinyGPS.h>

SoftwareSerial Sim900Serial(2, 3);


int gsmsheildpin = 13;           /*gsm sheild      choose the pin for the sheild*/
int inpin1 = 7;                  /*airbag          choosen the input pin (for a pushbutton)(airbag)*/
int inpin2 = 8;                  /*emergency       choosen the input pin (for a pushbutton)(emergency)*/
int tempPin = 1;                 /*thermal         variable for thermal sensor*/
float temp=0;
boolean v1=LOW;          /*       boolean variable for */
boolean v2=LOW;




SoftwareSerial GPS(4, 5);
TinyGPS gps;
unsigned long fix_age;
long lat, lon;
float LAT, LON;
void gpsdump(TinyGPS &gps);
bool feedgps();
void getGPS();
void SIM900power();
int airbag();
int emergency();
int thermal();

void setup()
{
   Serial.begin(19200); // for serial monitor
  Sim900Serial.begin(19200);  // for GSM shield
  SIM900power();  // turn on shield
  delay(25000);

  Sim900Serial.begin(19200);     // the SIM900 baud rate
  GPS.begin(9600);                   // GPS module baud rate  
  Serial.begin(9600);                  // the Serial port of Arduino baud rate.
  delay(25000);
 SIM900power();
  Sim900_Inti();
}
 
void loop()
{
  int k,l,n;                                   //note no buffer found
   k=airbag();
   l=thermal();
   n=emergency();
 
     if((k==1)||(k==1)||(n==1))          
    Cmd_Read_Act();                              
 
    
}


void SIM900power()
// software equivalent of pressing the GSM shield "power" button
{
  digitalWrite(9, HIGH);
  delay(1000);
  digitalWrite(9, LOW);
  delay(7000);
}




void Sim900_Inti(void)
{
  Sim900Serial.println("AT CMGF=1");    // Set GSM shield to sms mode
  Serial.println("AT CMGF=1");
  delay(500);
  Sim900Serial.println("AT CNMI=2,2");
  Serial.println("AT CMGF=1");
  delay(500);
}

void Cmd_Read_Act(void)                       //Function reads the SMS sent to SIM900 shield.
{ 
  
 
      Serial.println("Sending  SMS. ");
      
      SendTextMessage();               
  
  
}




int airbag()               //airbag
  {
   v1 = digitalRead(inpin1);  // read input value
   if (v1 == HIGH)       // check if the input is HIGH (button released)  //if condtion not working change the if statment to send sms 
   {
    return 1;
   }
  }
  
  int emergency()                                                          //emergency
{ 

  v2 = digitalRead(inpin2);          // read input value
 
  if (v2 == HIGH)                    // check if the input is HIGH (button released)     
   
   {
     return 1;  
 }

}


int thermal() //thermal part
{

  temp = analogRead(tempPin);
  temp = temp * 0.48828125;
  Serial.print("TEMPRATURE = ");
    Serial.print(temp);
    Serial.print("*C");                   //this code is for temperature display
 
  if(temp>35)
   {
    return 1;
   }
}





// func to send message
void SendTextMessage()
{
  
  
Sim900Serial.print("AT CMGF=1\r");    //Sending the SMS in text mode
delay(100);
Sim900Serial.println("AT CMGS = \"919789815407\"");//The predefined phone number
delay(100);
Sim900Serial.println("Please wait while Module calculates position");//the content of the message
delay(100);
Sim900Serial.println((char)26);//the ASCII code of the ctrl z is 26
delay(100);
Sim900Serial.println();
int counter=0;
GPS.listen();


for (;;)
{
   long lat, lon;
   unsigned long fix_age, time, date, speed, course;
   unsigned long chars;
   unsigned short sentences, failed_checksum;
   long Latitude, Longitude;
    
   // retrieves /- lat/long in 100000ths of a degree
   gps.get_position(&lat, &lon, &fix_age);
   getGPS();
   Serial.print("Latitude : ");
   Serial.print(LAT/1000000,7);
   Serial.print(" :: Longitude : ");
   Serial.println(LON/1000000,7);
   if (LAT == 0 && LON == 0)
  {
    continue;    
  } 
  counter ;
  if (counter<30)
  {
    continue;    
  }
  
  Sim900Serial.print("AT CMGF=1\r");    //Sending the SMS in text mode
  delay(100);
  Sim900Serial.println("AT CMGS = \"919789815407\"");//The predefined phone number
  delay(100);
  Sim900Serial.print("Latitude : ");
  Sim900Serial.print(LAT/1000000,7);
  Sim900Serial.print(" :: Longitude : ");
  Sim900Serial.println(LON/1000000,7);//the content of the message
  delay(100);
  Sim900Serial.println((char)26);//the ASCII code of the ctrl z is 26
  delay(100);
  Sim900Serial.println();
  counter=0;
  break;
 }      
}


// get the latitude and longitude

void getGPS()
{
   bool newdata = false;
   unsigned long start = millis();
   while (millis() - start < 1000)
   {
      if (feedgps ())
      {
         newdata = true;
       }
     }
     if (newdata)
   {
      gpsdump(gps);
    }
}
bool feedgps()
{
   while (GPS.available())
 {
      if (gps.encode(GPS.read()))
        return true;
      }return 0;
}

void gpsdump(TinyGPS &gps)
{
   gps.get_position(&lat, &lon);
   LAT = lat;
   LON = lon;
   {
      feedgps();' 
    }
  }

You will not be any more successful than the dozens of other people who have tried to use multiple instances of SoftwareSerial. Give it up, and get a Mega.