Hombre, puestos a usar métodos predefinidos puedes usar la función sort (sí, es standar):
#include <algorithm>
#include <vector>
#include <iostream>
using namespace std;
int main(){
vector<double> v(7);
v[0] = 2; v[1] = 4; v[2] = 7; v[3] = 7; v[4] = 8; v[5] = 9; v[6] = 5;
// v == {2,4,7,7,8,9,5}
for(int y=0; y<(int)v.size(); y++) cout << v[y];
cout << endl;
sort(v.begin(), v.end());
// v == {2,4,5,7,7,8,9}
for(int x=0; x<(int)v.size(); x++) cout << v[x];
cout << endl;
return 0;
}
Si no quieres usar la funcion sort, hazlo con las funciones que te da la clase vector, esta es tu función pero echa por mi:
void insereix(vector <double>& v){
int x;
for(x=0; x<(int)v.size(); x++) if(v[x] >= v[v.size()-1]) break; //para cuando encuentra un valor mas grande que v[v.size()-1]
v.insert(v.begin()+x, v[v.size()-1]); //lo inserta en x
v.erase(v.end()-1); //borra el ultimo valor
}
PD: En tu función v nunca cambia porque usas un vector auxiliar y la funcion es de tipo void, añade swap(v, vi); al final de tu función y #include <algorithm> al principio del archivo y verás que de todas formas no haces bien el ordenamiento.