Be the first to rate this file! 119 downloads (last 30 days) File Size: 11.63 KB File ID: #18018

Continuous Phase Oscillator in Simulink

by Rick Rosson

 

14 Dec 2007 (Updated 03 Jun 2009)

Code covered by BSD License  

Generate a simple cosine wave in Simulink

Download Now | Watch this File

File Information
Description

A Simulink model that generates and displays a simple cosine wave. The model computes the cosine function using the continuous phase method, which is based on Euler's formula for the complex exponential. The cosine generator is provided as a subsystem, which the user can copy-and-paste into other models. The subsystem's mask allows the user to control two parameters: the oscillation frequency 'Fc', and the sampling rate 'Fs'.

The model includes three versions of the oscillator sub-system:
1. Floating-point (double-precision).
2. Fixed-point with no magnitude stabilization
3. Fixed-point with magnitude stabilization

All three outputs are plotted using a Time Domain Scope. In addition, the first and third outputs are also plotted in the Frequency Domain using the Spectrum Scope.

Required Products Signal Processing Blockset
Signal Processing Toolbox
Simulink
Simulink Fixed Point
MATLAB release MATLAB 7.8 (R2009a)
Zip File Content  
Other Files license.txt,
Oscillator_01.mdl
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Please login to add a comment or rating.
Updates
18 Dec 2007

Fix the keywords, and clean-up the description.

20 Dec 2007

Minor improvements to the .mdl file and the screenshot.

10 Jan 2008

Added more detail to the description

10 Jan 2008

Fixed typo in description, and clarified 'grow' to 'grow without bound'.

03 Jun 2009

Major update to incorporate fixed-point and magnitude stabilization.

Tag Activity for this File
Tag Applied By Date/Time
oscillator Rick Rosson 26 Jan 2009 15:07:43
sine Rick Rosson 26 Jan 2009 15:07:43
cosine Rick Rosson 26 Jan 2009 15:07:43
example Rick Rosson 26 Jan 2009 15:07:43
demo Rick Rosson 26 Jan 2009 15:07:43
simulink Rick Rosson 26 Jan 2009 15:07:43
complex exponential Rick Rosson 26 Jan 2009 15:07:52
signal processing Rick Rosson 26 Jan 2009 15:08:27
communications Rick Rosson 26 Jan 2009 15:08:34
spc Rick Rosson 12 Feb 2009 13:30:53
continuous phase Rick Rosson 12 Feb 2009 13:31:17
sinusoidal Rick Rosson 12 Feb 2009 13:31:31
wave Rick Rosson 12 Feb 2009 13:31:40
euler Rick Rosson 11 Jun 2009 11:10:05
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com