Showing
6 changed files
with
25 additions
and
0 deletions
constellation/constellation.sdf
0 → 100644
No preview for this file type
constellation/constellation.v12.suo
0 → 100644
No preview for this file type
constellation/constellation/channel.cpp
0 → 100644
| 1 | +#include "channel.h" | ||
| 2 | +void Cchannel::AWGN() { | ||
| 3 | + std::default_random_engine generator; | ||
| 4 | + std::normal_distribution<double> distribution(0.0, No); | ||
| 5 | + | ||
| 6 | + int NN = Nbits / Nbitspersymbol * Nsamplespersymbol; | ||
| 7 | + for (int i = 0; i < NN; i++) { | ||
| 8 | + r[i] = s[i] + distribution(generator); | ||
| 9 | + } | ||
| 10 | +} | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| ... | @@ -110,7 +110,9 @@ | ... | @@ -110,7 +110,9 @@ |
| 110 | </Link> | 110 | </Link> |
| 111 | </ItemDefinitionGroup> | 111 | </ItemDefinitionGroup> |
| 112 | <ItemGroup> | 112 | <ItemGroup> |
| 113 | + <ClCompile Include="channel.cpp" /> | ||
| 113 | <ClCompile Include="constellation_main.cpp" /> | 114 | <ClCompile Include="constellation_main.cpp" /> |
| 115 | + <ClCompile Include="evaluate.cpp" /> | ||
| 114 | <ClCompile Include="myMatrix.cpp" /> | 116 | <ClCompile Include="myMatrix.cpp" /> |
| 115 | <ClCompile Include="receiver.cpp" /> | 117 | <ClCompile Include="receiver.cpp" /> |
| 116 | </ItemGroup> | 118 | </ItemGroup> | ... | ... |
| ... | @@ -21,7 +21,14 @@ | ... | @@ -21,7 +21,14 @@ |
| 21 | <ClCompile Include="myMatrix.cpp"> | 21 | <ClCompile Include="myMatrix.cpp"> |
| 22 | <Filter>소스 파일</Filter> | 22 | <Filter>소스 파일</Filter> |
| 23 | </ClCompile> | 23 | </ClCompile> |
| 24 | + | ||
| 24 | <ClCompile Include="receiver.cpp"> | 25 | <ClCompile Include="receiver.cpp"> |
| 26 | + | ||
| 27 | + <ClCompile Include="channel.cpp"> | ||
| 28 | + <Filter>소스 파일</Filter> | ||
| 29 | + </ClCompile> | ||
| 30 | + <ClCompile Include="evaluate.cpp"> | ||
| 31 | + | ||
| 25 | <Filter>소스 파일</Filter> | 32 | <Filter>소스 파일</Filter> |
| 26 | </ClCompile> | 33 | </ClCompile> |
| 27 | </ItemGroup> | 34 | </ItemGroup> | ... | ... |
constellation/constellation/evaluate.cpp
0 → 100644
-
Please register or login to post a comment