How do you compute for fc and t in modulating an I and Q component
The answer is: it depends on the pulse shape.

A 16-QAM baseband signal can be written as $$s_{BB}=\sum_{k=0}^{N-1} a_k p(t-kT_p),$$ where $a_k$ is a complex symbol taken from your 16-QAM constellation, $R_p=1/T_p$ is the pulse rate (how many pulses per second you transmit), and $p(t)$ is the pulse shape (ideally, $p(t)$ is a Nyquist pulse).

The bandwidth of $s_{BB}(t)$ is the same as the bandwidth of $p(t)$ (assuming you're transmitting uncorrelated data). Assume this bandwidth is $B$. Then, after mixing with the carrier, the passband signal's maximum frequency is $f_c+B$, and you need a sampling frequency $f_s&gt;2(f_c+B)$ to satisfy Nyquist.

If you don't know what the pulse shape is, then you're probably transmitting rectangular, non-overlapping pulses. As a rule of thumb, I define the bandwidth of a rectangular pulse as five times the pulse rate: $B=5R_p$. Note that many textbook authors, such as Stallings, use $B=R_p$. I prefer to be conservative and define a larger bandwidth.

Then, your sampling frequency is $f_s&gt;2(f_c+5R_p)$.

As an example, let's say that you want to transmit 1000 pulses per second, with a carrier frequency of 1 MHz, and rectangular pulses. Then,

fs = 2*(1e6+5*1000);  % or larger
t = 0:1/fs:Tend       % Tend depends on how many pulses you transmit