Is there a standard C++ class for arrays with fixed run-time-determined size?

Allocate the memory using an std::unique_ptr like you suggested, but to use it - construct an std::span (in C++20; gsl::span before C++20) from the raw pointer and the number of elements, and pass the span around (by value; spans are reference-types, sort of). The span will give you all the bells and whistles of a container: size, iterators, ranged-for, the works.

// or:
// #include 

int main() {

    // ... etc. ...

        size_t size = 10e5;
        auto uptr { std::make_unique(size) };
        do_stuff_with_the_doubles(std::span my_span { uptr.get(), size });

    // ... etc. ...