淘宝官方店     推荐课程     在线工具     联系方式     关于我们  
 
 

微波射频仿真设计   Ansoft Designer 中文培训教程   |   HFSS视频培训教程套装

 

Agilent ADS 视频培训教程   |   CST微波工作室视频教程   |   AWR Microwave Office

          首页 >> Ansoft Designer >> Ansoft Designer在线帮助文档


Ansoft Designer / Ansys Designer 在线帮助文档:


Nexxim Simulator >
Nexsys Discrete Time Domain Analysis >
   Nexsys MATLAB User Defined Models >
       The Nexsys MATLAB Model File >
           Global Variables for Timestep and Center Frequency               


Global Variables for Timestep and Center Frequency

The MATLAB model can access and change the timestep and center frequency on a port-by-port basis using MATLAB global variables TS_IN, TS_OUT, CF_IN, and CF_OUT.

•  TS_IN is a vector containing the time steps associated with all input signals. TS_IN(j) is the time step associated with the signal of the jth input port.

•  TS_OUT is a vector containing the time steps associated with all output signals. TS_OUT(j) is the time step associated with the signal of the jth output port.

•  CF_IN is a vector containing the center (carrier) frequencies associated with all input signals. CF_IN(j) is the center frequency associated with the signal of the jth input port.

•  CF_OUT is a vector containing the center (carrier) frequencies associated with all output signals. CF_OUT(j) is the center frequency associated with the signal of the jth output port.

The global Statement

To access these Nexsys global variables during simulation, the model includes a global statement on the line after the function declaration, listing the global variables to be accessed. For example, the statement

global TS_IN TS_OUT

allows users to access the global input and output time steps.

Acessing and Changing the Time Step

To access or set the time step for output signals the model reads and writes the global vectors TS_IN and TS_OUT. For example, the statement

TS_OUT(2) = 2 * TS_IN(1)

sets the time step of the second output port to be twice the time step of the first input port. If the time step for the output ports (TS_OUT) of a functional SOURCE UDM is not set explicitly in the code, the engine will assign 1/sample_rate to each of them. If TS_OUT is not set by a functional I/O model, the program will assume the output sample rates are equal to the first input sample rate.

Accessing and Changing the Center Frequency

Setting up the center frequencies for output signals can be done by accessing the vectors CF_IN and CF_OUT. For example, the statement

CF_OUT(2) = 2 * CF_IN(1)

sets the center frequency of the second output port to be twice the center frequency of the first input port. If CF_OUT is not set by a MATLAB functional UDM, all output port frequencies will assume the center frequency of the first input port for an I/O model and a zero center frequency for a SOURCE model.

 




HFSS视频教学培训教程 ADS2011视频培训教程 CST微波工作室教程 Ansoft Designer 教程

                HFSS视频教程                                      ADS视频教程                               CST视频教程                           Ansoft Designer 中文教程


 

      Copyright © 2006 - 2013   微波EDA网, All Rights Reserved    业务联系:mweda@163.com