ing approaches can be used achieving a good trade-off I. Picallo et al. between accuracy and time. In this work, an in-house three-dimensional ray- launching technique has been used to characterize the radio channel of the proposed environments. The algorithm is based on geometrical optics (GO) and the uniform theory of diffraction (UTD). It is worth noting that owing to the geometric-stochastic nature of the proposed algorithm, it consider any potential type of link for the whole 3D volume of the scenario under analysis (i.e., LOS, NLOS, or partial NLOS). The transmitted and reflected waves are modeled by Fresnel equations. For a given interface of two mediums 1 and 2, where equivalent ray interaction occurs, the reflection coefficient and the transmission coefficient TH for the parallel and perpendicular polarization are obtained by the following expressions: (8.1) (8.2) (8.3) n2cos(vi)+n1cos(v1) (8.4) = Er2 are the relative permittivity of the mediums 1 and 2 and Vi, Vr, and Vt are the incident, reflected, and transmitted angles, respectively. In the same way, diffraction phenomenon is taken into account by considering wedge diffraction, where new diffracted rays are generated. In the case of finite conductivity bidimensional wedge conditions, the calculation of diffracted components is characterized by detecting the corresponding object edges and applying the following diffraction coefficients [33]: (8.5) where NT is the wedge angle, F the line source model, L the distance parameter (variable as a function of the propagating wave), a+ the diffraction angle-dependent coefficient, R0,n the reflection coefficients as a function of the corresponding material layer interfaces, and O2 and 01 the angles to the observation points before and after the diffraction wedge [34]. The resulting total E-field components are given by: Implementation of Context-Aware Environments with Massive IoT Systems (8.6) (8.7) 120 S2. Prad is the radiated power of the transmitter antenna, whereas Dt (At, Dt) is the directivity considerin