Inductor

model Inductor "Ideal linear electrical inductor"
    extends Interfaces.OnePort(i(start = 0));

    parameter SI.Inductance L(start = 1) "Inductance";
equation
    L * der(i) = v;

    annotation (
        Documentation(
            info = "<html>\n<p>The linear inductor connects the branch voltage <em>v</em> with the branch current <em>i</em> by <em>v = L * di/dt</em>. The Inductance <em>L</em> is allowed to be positive, or zero.</p>\n\n</html>",
            revisions = "<html>\n<ul>\n<li><em> 1998   </em>\n       by Christoph Clauss<br> initially implemented<br>\n       </li>\n</ul>\n</html>"),
        Icon(
            coordinateSystem(
                preserveAspectRatio = true,
                extent = {
                    {-100, -100}, 
                    {100, 100}}),
            graphics = {
                Line(
                    points = {
                        {60, 0}, 
                        {90, 0}},
                    color = {0, 0, 255}), 
                Line(
                    points = {
                        {-90, 0}, 
                        {-60, 0}},
                    color = {0, 0, 255}), 
                Text(
                    extent = {
                        {-150, -40}, 
                        {150, -80}},
                    textString = "L=%L"), 
                Line(
                    points = {
                        {-60, 0}, 
                        {-59, 6}, 
                        {-52, 14}, 
                        {-38, 14}, 
                        {-31, 6}, 
                        {-30, 0}},
                    color = {0, 0, 255},
                    smooth = Smooth.Bezier), 
                Line(
                    points = {
                        {-30, 0}, 
                        {-29, 6}, 
                        {-22, 14}, 
                        {-8, 14}, 
                        {-1, 6}, 
                        {0, 0}},
                    color = {0, 0, 255},
                    smooth = Smooth.Bezier), 
                Line(
                    points = {
                        {0, 0}, 
                        {1, 6}, 
                        {8, 14}, 
                        {22, 14}, 
                        {29, 6}, 
                        {30, 0}},
                    color = {0, 0, 255},
                    smooth = Smooth.Bezier), 
                Line(
                    points = {
                        {30, 0}, 
                        {31, 6}, 
                        {38, 14}, 
                        {52, 14}, 
                        {59, 6}, 
                        {60, 0}},
                    color = {0, 0, 255},
                    smooth = Smooth.Bezier), 
                Text(
                    extent = {
                        {-150, 90}, 
                        {150, 50}},
                    textString = "%name",
                    lineColor = {0, 0, 255})}));
end Inductor;