Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
Forest Monitoring
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
GPSE
Promo2025
Forest Monitoring
Commits
3f367e13
Commit
3f367e13
authored
Apr 27, 2024
by
Quentin Chabanne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Upload New File
parent
6d7535ef
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
0 deletions
+37
-0
import_math.py
Tecnhical Document (by the 2022 team)/import_math.py
+37
-0
No files found.
Tecnhical Document (by the 2022 team)/import_math.py
0 → 100644
View file @
3f367e13
import
math
"Consider a 8-PSK (Phase Shift Keying) modulation with the following parameters:"
#carrier frequency (normalized) : 0.15
#symbol duration (normalized): 40 samples
def
modulation_frequency_band
(
f_carrier
,
T_symbol
):
f_low
=
f_carrier
-
1
/
(
2
*
T_symbol
)
f_high
=
f_carrier
+
1
/
(
2
*
T_symbol
)
return
f_low
,
f_high
def
main
():
f_carrier
=
0.15
T_symbol
=
40
modulation_order
=
8
# Number of symbols
num_symbols
=
modulation_order
print
(
f
"Number of symbols: {num_symbols}"
)
# Bits per symbol
bits_per_symbol
=
int
(
math
.
log2
(
modulation_order
))
print
(
f
"Bits per symbol: {bits_per_symbol}"
)
# Distinct amplitudes for I and Q components
distinct_amplitudes
=
int
(
math
.
sqrt
(
modulation_order
))
print
(
f
"Distinct amplitudes for the in-phase (I) component: {distinct_amplitudes}"
)
print
(
f
"Distinct amplitudes for the quadrature (Q) component: {distinct_amplitudes}"
)
# Low and high frequencies of the modulation frequency band
f_low
,
f_high
=
modulation_frequency_band
(
f_carrier
,
T_symbol
)
print
(
f
"Normalized low frequency of the modulation frequency band: {f_low}"
)
print
(
f
"Normalized high frequency of the modulation frequency band: {f_high}"
)
if
__name__
==
"__main__"
:
main
()
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment