Complex Multiplier (complex_multiplier_xf)
Multiplies two complex values together.
Design
The mathematical representation of the implementation is given in (120).
In (120):
\(x[n]\) and math:y[n] are the input values.
\(y[n]\) is the output values.
A block diagram representation of the implementation is given in Figure 400:.
Figure 400: Complex multiplier implementation
Interface
<?xml version="1.0"?>
<componentspec>
<port name="input_1" producer="false" protocol="complex_float_timed_sample-prot"/>
<port name="input_2" producer="false" protocol="complex_float_timed_sample-prot"/>
<port name="output" producer="true" protocol="complex_float_timed_sample-prot"/>
</componentspec>
Ports
Inputs:
input_1: Input samples port.Protocol:
complex_float_timed_sample-protOptional:
False
input_2: Input samples port.Protocol:
complex_float_timed_sample-protOptional:
False
Outputs:
output: Primary output samples port.Protocol:
complex_float_timed_sample-protOptional:
False
Opcode Handling
Multiplication is only applied to data in sample opcode messages. All other opcode messages received on input_1 are passed through this component without any effect. All messages with a non-sample opcode received on input_2 are discarded.
Sample message lengths received on input_1 are persevered on the output. Sample message lengths received on input_2 are ignored.
Properties
None.
Implementations
complex_multiplier_xf(RCC)
Example Application
<?xml version="1.0"?>
<application done="file_write">
<instance component="ocpi.core.file_read" connect="complex_multiplier_xf" to="input_1">
<property name="filename" value="input_1.bin"/>
</instance>
<instance component="ocpi.core.file_read" connect="complex_multiplier_xf" to="input_2">
<property name="filename" value="input_2.bin"/>
</instance>
<instance component="ocpi.comp.sdr.math.complex_multiplier_xf" connect="file_write"/>
<instance component="ocpi.core.file_write">
<property name="filename" value="output.bin"/>
</instance>
</application>
Dependencies
The dependencies to other elements in OpenCPI are:
None.
There is also a dependency on:
None.
Limitations
Limitations of complex_multiplier_xf are:
If any intermediate value of the calculation of the output value exceeds the supported range of a single precision floating point number, the output will be a floating point special value (
+inf,-inforNaN), even if the ‘correct’ value would be within the supported single precision floating point range. For example, if \(x = a + jb\) is to be multiplied by \(y = c +jd\), then \(xy = (ac - bd) + j(ad + bc)\) will contain a floating point special value, if any of \(ac\), \(bd\), \(ad\) or \(bc\) are outside of the supported range of a single prevision floating point number. Even if \(ac - bd\) or \(ad + bc\) calculated directly are within the supported range of a single precision floating point number.
Testing
Tested platforms: None
Component testing not completed.