set_trace_math
Configure a spectrum analyzer trace's math operation to combine two operand traces for power difference/sum or log difference/offset, apply an optional dB offset, or turn math off.
Instructions
Set trace math for a trace (:CALCulate:MATH): result trace <- operand_a (op) operand_b. Operations: off, power_difference, power_sum, log_difference, log_offset; offset_db (-100..100) applies only to the two log operations. The instrument has no query for the math setting, so it cannot be read back (check the trace data). Enabling math switches the trace on (update and display); turning it off does not switch it off again.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"trace": "<trace>",
"operation": "<operation>"
},
"name": "set_trace_math"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| trace | Yes | Trace (1-6) the operation is applied to | |
| offset_db | No | Offset in dB, only for log_difference and log_offset (default 0) | |
| operand_a | No | Operand A trace (1-6); required unless operation is off | |
| operand_b | No | Operand B trace (1-6); required unless operation is off | |
| operation | Yes | Math operation | |
| instrument | No | Which instrument to use (a name from list_instruments). Default: the `default` instrument, or the only one configured |