std::copy
cannot be used to insert into an empty container. To do that, you need to use an insert_iterator like so:
std::set<double> input;
input.insert(5);
input.insert(6);
std::vector<double> output;
std::copy(input.begin(), input.end(), inserter(output, output.begin()));