5#ifndef OAKFIELD_COMPLEX_MATH_H
6#define OAKFIELD_COMPLEX_MATH_H
SimComplexMathPhaseWrap
Phase wrap policy for phase outputs.
Definition complex_math.h:66
@ SIM_COMPLEX_MATH_PHASE_UNIT
Definition complex_math.h:70
@ SIM_COMPLEX_MATH_PHASE_UNSIGNED
Definition complex_math.h:69
@ SIM_COMPLEX_MATH_PHASE_SIGNED
Definition complex_math.h:68
@ SIM_COMPLEX_MATH_PHASE_NONE
Definition complex_math.h:67
SimComplexMathMode
Elementwise complex math operation.
Definition complex_math.h:22
@ SIM_COMPLEX_MATH_COSH
Definition complex_math.h:34
@ SIM_COMPLEX_MATH_CONJ
Definition complex_math.h:37
@ SIM_COMPLEX_MATH_SQRT
Definition complex_math.h:36
@ SIM_COMPLEX_MATH_DIV
Definition complex_math.h:26
@ SIM_COMPLEX_MATH_TAN
Definition complex_math.h:32
@ SIM_COMPLEX_MATH_NEG
Definition complex_math.h:42
@ SIM_COMPLEX_MATH_EXP
Definition complex_math.h:28
@ SIM_COMPLEX_MATH_POW
Definition complex_math.h:27
@ SIM_COMPLEX_MATH_ADD
Definition complex_math.h:23
@ SIM_COMPLEX_MATH_SINH
Definition complex_math.h:33
@ SIM_COMPLEX_MATH_ABS
Definition complex_math.h:38
@ SIM_COMPLEX_MATH_SUB
Definition complex_math.h:24
@ SIM_COMPLEX_MATH_ARG
Definition complex_math.h:39
@ SIM_COMPLEX_MATH_REAL
Definition complex_math.h:40
@ SIM_COMPLEX_MATH_COS
Definition complex_math.h:31
@ SIM_COMPLEX_MATH_SIN
Definition complex_math.h:30
@ SIM_COMPLEX_MATH_TANH
Definition complex_math.h:35
@ SIM_COMPLEX_MATH_MUL
Definition complex_math.h:25
@ SIM_COMPLEX_MATH_IMAG
Definition complex_math.h:41
@ SIM_COMPLEX_MATH_LOG
Definition complex_math.h:29
SimResult sim_add_complex_math_operator(struct SimContext *context, const SimComplexMathOperatorConfig *config, size_t *out_index)
Register a complex math operator with the provided configuration.
SimComplexMathRhsSource
Right-hand side source for binary ops.
Definition complex_math.h:48
@ SIM_COMPLEX_MATH_RHS_CONSTANT
Definition complex_math.h:50
@ SIM_COMPLEX_MATH_RHS_FIELD
Definition complex_math.h:49
SimComplexMathOutputComponent
Output component selection when writing into real fields.
Definition complex_math.h:56
@ SIM_COMPLEX_MATH_OUTPUT_MAGNITUDE
Definition complex_math.h:59
@ SIM_COMPLEX_MATH_OUTPUT_REAL
Definition complex_math.h:57
@ SIM_COMPLEX_MATH_OUTPUT_PHASE
Definition complex_math.h:60
@ SIM_COMPLEX_MATH_OUTPUT_IMAG
Definition complex_math.h:58
SimResult sim_complex_math_update(struct SimContext *context, size_t operator_index, const SimComplexMathOperatorConfig *config)
Update an existing complex math operator in-place.
SimResult sim_complex_math_config(struct SimContext *context, size_t operator_index, SimComplexMathOperatorConfig *out_config)
Retrieve the configuration currently bound to a complex math operator.
SimResult
Return codes shared by libsimcore modules.
Definition field.h:29
Declarative complex-first operator splitting (substep expansion at plan time).
Configuration for the complex math operator.
Definition complex_math.h:76
SimComplexMathOutputComponent output_component
Definition complex_math.h:91
double lhs_scale_im
Definition complex_math.h:85
SimComplexMathRhsSource rhs_source
Definition complex_math.h:81
size_t lhs_field
Definition complex_math.h:77
bool scale_by_dt
Definition complex_math.h:94
SimComplexMathPhaseWrap phase_wrap
Definition complex_math.h:92
double bias_im
Definition complex_math.h:89
double lhs_scale_re
Definition complex_math.h:84
double rhs_scale_re
Definition complex_math.h:86
double rhs_constant_re
Definition complex_math.h:82
double rhs_constant_im
Definition complex_math.h:83
double bias_re
Definition complex_math.h:88
SimComplexMathMode mode
Definition complex_math.h:80
size_t rhs_field
Definition complex_math.h:78
size_t output_field
Definition complex_math.h:79
bool accumulate
Definition complex_math.h:93
double epsilon
Definition complex_math.h:90
double rhs_scale_im
Definition complex_math.h:87
Simulation runtime state.
Definition sim_context.h:70