how to write these two equations

Respuestas (1)

David Hill
David Hill el 24 de Mzo. de 2020
Not sure what Tj means in the equation.
for k=1:K
for j=1:K
if j~=K
R(j,k)=B/2*log2(1+(h(k)*a(j))^2/(sum((h(k)*a(j+1:K)).^2)+e*sum((h(k)*a(1:j-1)).^2)+1/rho));
else
R(j,k)=B/2*log2(1+(h(K)*a(K))^2/(e*sum((h(K)*a(1:j-1)).^2)+1/rho));
end
end
end

12 comentarios

Sultan Al Harthy
Sultan Al Harthy el 24 de Mzo. de 2020
hello david hill, thanks for you answer and Tj is
T j denotes the targeted data rate satisfying the j t h user’s QoSrequirements,ρ=γ2·TSNR,TSNR=Pelec/N0B denotes the transmitted signal-to-noise ratio (TSNR)
would that change anything in the equation??
thanks
David Hill
David Hill el 24 de Mzo. de 2020
I don't know. What should R be assigned if the above expression is not >=Tj? Also be advised, I did not know if j and k should start at 0 or 1. I chose to start at 1 due to the ease in matlab indexing, but it could be easily changed.
Sultan Al Harthy
Sultan Al Harthy el 24 de Mzo. de 2020
thank you man, appreciate it
Sultan Al Harthy
Sultan Al Harthy el 30 de Mzo. de 2020
hello david,
i am still trying to figure out, why do you have k=1:K, and j=1:K
i am trying to understand whether the equation you wrote is similar to the one provided,
thanks
David Hill
David Hill el 30 de Mzo. de 2020
Show me your arrays (h and a). The equations I coded match those you provided. I assumed the length of array (h) was K (indexing from 1 to K) and the length of array (a) was also K. The first loop is for indexing into array (h). The second loop is for array (a).
Sultan Al Harthy
Sultan Al Harthy el 31 de Mzo. de 2020
Sultan Al Harthy
Sultan Al Harthy el 31 de Mzo. de 2020
yes david,
this is the information that has been given to me, and i have to write down all the equations and to calculate there values
id appreciate your help
thanks
Sultan Al Harthy
Sultan Al Harthy el 31 de Mzo. de 2020
any idea?
thanks
David Hill
David Hill el 31 de Mzo. de 2020
I can help with Matlab if you have any other specific questions. I believe the equations are correct but you will have to provide the correct inputs.
Sultan Al Harthy
Sultan Al Harthy el 31 de Mzo. de 2020
i have added the required parameters, yet for some reason it doesnt work and this is my first time using matlab,
if there's somewhere youd recommend me to look online, i will study the concept behind it,
or i can email you what exactly im trying to do, so we can be on the same page
thanks
I assume you are trying to get numeric solutions; therefore, your arrays of (h) and (a) need to be numeric and you need to assign a values to B, K, e, and rho before the above loops can be entered. Additionally, you will want to preallocate R:
R=zeroes(K,K);
Sultan Al Harthy
Sultan Al Harthy el 3 de Abr. de 2020
i am confused

Iniciar sesión para comentar.

Categorías

Preguntada:

el 24 de Mzo. de 2020

Comentada:

el 3 de Abr. de 2020

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by