The aim of this study was a didactic presentation of the Shannon entropy in the quantum theory context, followed by application to the case of a one-dimensional harmonic oscillator in its ground state, both in the free case and confined case. The study of these systems allows us to highlight notions such as location or delocation of a particle, a possible interpretation that the Shannon entropy can adopt. The Shannon entropy in position (Sx) and momentum (Sp) spaces were calculated for both systems, beyond the entropic sum (St = Sx + Sp). With this procedure it was possible to identify trends in the behavior of the Shannon entropy (Sx and Sp) and test the compliance of the entropic uncertainty relation (St = Sx + Sp ≥ n(1 + ln(π)))