Scicos Block
fr - eng


Electrical AC voltage source

\epsfig{file=VsourceAC.eps,width=90.00pt}

Contents

Description

This component is an AC voltage source with sinosoid output voltage. The amplitude and the frequency of the output voltage is set by the user. The ohmic resistance of this block is zero.

Dialog box

Set voltage source parameter  
Amplitude (Volt) 220
Frequency (Hz) 50

Default properties

Interfacing function

VsourceAC.sci

Modelica model


class VsourceAC "Sin-wave voltage source"
	Pin p, n;
	Real v;
	parameter Real VA = 220 "Amplitude";
	parameter Real f = 50 "Frequency";
	parameter Real PI=3.141592653589793;
equation
	v = VA*Modelica.Math.sin(2*PI*f*time);
	v = p.v - n.v;
	0 = p.i + n.i;
end VsourceAC;