pub fn pcscalar<F: Field>(name: &str) -> Amplitude<F>
Expand description
Creates a named PolarComplexScalar
.
This is a convenience method to generate an Amplitude
which represents a complex
value determined by two parameters, real
and imag
.
ยงExamples
Basic usage:
use rustitude_core::prelude::*;
let my_pcscalar: Amplitude<f64> = pcscalar("MyPolarComplexScalar");
assert_eq!(my_pcscalar.parameters, vec!["mag".to_string(), "phi".to_string()]);