Skip to main content

A Python package for signal generation and operations

Project description

signal_ICT_AhujaSlock_92400133041

A Python package for generating and operating on signals, demonstrating fundamental concepts of Signals and Systems.

Installation

From Source

  1. Clone the repository:

    git clone https://github.com/yourusername/signal_ICT_AhujaSlock_92400133041.git
    cd signal_ICT_AhujaSlock_92400133041
    
  2. Install the package:

    pip install .
    

From Wheel

  1. Download the .whl file from the dist/ folder.
  2. Install using pip:
    pip install signal_ICT_AhujaSlock_92400133041-1.0.0-py3-none-any.whl
    

From TestPyPI

pip install -i https://test.pypi.org/simple/ signal_ICT_AhujaSlock_92400133041

Usage

Importing the Package

from signal_ICT_AhujaSlock_92400133041 import unit_step, unit_impulse, ramp_signal
from signal_ICT_AhujaSlock_92400133041 import sine_wave, cosine_wave, exponential_signal
from signal_ICT_AhujaSlock_92400133041 import time_shift, time_scale, signal_addition, signal_multiplication

Example Usage

import numpy as np
import matplotlib.pyplot as plt

# Generate unit step signal
step = unit_step(20)

# Generate sine wave
t = np.linspace(0, 1, 500)
sine = sine_wave(A=2, f=5, phi=0, t=t)

# Time shift
shifted = time_shift(sine, 5)

# Addition
ramp = ramp_signal(20)
added = signal_addition(step, ramp)

# Multiplication
cosine = cosine_wave(A=2, f=5, phi=0, t=t)
multiplied = signal_multiplication(sine, cosine)

Modules

unitary_signals.py

  • unit_step(n): Generates a unit step signal of length n.
  • unit_impulse(n): Generates a unit impulse signal of length n.
  • ramp_signal(n): Generates a ramp signal of length n.

trigonometric_signals.py

  • sine_wave(A, f, phi, t): Generates a sine wave with amplitude A, frequency f, phase phi, over time vector t.
  • cosine_wave(A, f, phi, t): Generates a cosine wave.
  • exponential_signal(A, a, t): Generates an exponential signal.

operations.py

  • time_shift(signal, k): Shifts the signal by k units.
  • time_scale(signal, k): Scales the time axis by factor k.
  • signal_addition(signal1, signal2): Adds two signals.
  • signal_multiplication(signal1, signal2): Multiplies two signals point-wise.

Dependencies

  • numpy
  • matplotlib

License

MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

signal_ict_ahujaslock_92400133041-1.0.0.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file signal_ict_ahujaslock_92400133041-1.0.0.tar.gz.

File metadata

File hashes

Hashes for signal_ict_ahujaslock_92400133041-1.0.0.tar.gz
Algorithm Hash digest
SHA256 14526d246dbdd3398c13b77bcaecc0c5c2ecb590baf8712aa2c8a16520f9694c
MD5 f5eac74a5833e1d75b011404cdcad59f
BLAKE2b-256 d8ad2f13927a8957c6c3437a2485f7b5502f182f8c6a21e04a2a1b46bee0d063

See more details on using hashes here.

File details

Details for the file signal_ict_ahujaslock_92400133041-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for signal_ict_ahujaslock_92400133041-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 18f2c7287cff9c30493ea41c4f77ad0207f4da458dc34ff8072bd86abf6676fd
MD5 1d15dfe20ad9136bed11b527d141134a
BLAKE2b-256 4025cd6fcc7c5b7fc0c53b8c754af17a28784fd59406ec841b48d8be88a19e10

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page