예제 #1
0
파일: DC.cs 프로젝트: slicol/SpiceSharp
        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="name">The name of the simulation</param>
        /// <param name="source">The name of the swept source</param>
        /// <param name="start">The starting value</param>
        /// <param name="stop">The stopping value</param>
        /// <param name="step">The step value</param>
        public DC(Identifier name, Identifier source, double start, double stop, double step) : base(name)
        {
            var config           = new DcConfiguration();
            SweepConfiguration s = new SweepConfiguration(source, start, stop, step);

            config.Sweeps.Add(s);
            ParameterSets.Add(config);
        }
예제 #2
0
파일: DC.cs 프로젝트: slicol/SpiceSharp
        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="name">Name</param>
        /// <param name="sweeps">Sweeps</param>
        public DC(Identifier name, IEnumerable <SweepConfiguration> sweeps) : base(name)
        {
            if (sweeps == null)
            {
                throw new ArgumentNullException(nameof(sweeps));
            }

            var dcconfig = new DcConfiguration();

            foreach (var sweep in sweeps)
            {
                dcconfig.Sweeps.Add(sweep);
            }
            ParameterSets.Add(dcconfig);
        }
예제 #3
0
파일: DC.cs 프로젝트: slicol/SpiceSharp
        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="name">The simulation name</param>
        public DC(Identifier name) : base(name)
        {
            var config = new DcConfiguration();

            ParameterSets.Add(config);
        }