Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change units of potential quantities in connectors to potential units #2560

Closed
christiankral opened this issue May 29, 2018 · 9 comments
Closed
Assignees
Labels
enhancement New feature or enhancement L: Electrical.Analog Issue addresses Modelica.Electrical.Analog L: Electrical.QuasiStationary Issue addresses Modelica.Electrical.QuasiStationary L: Magnetic.FundamentalWave Issue addresses Modelica.Magnetic.FundamentalWave
Milestone

Comments

@christiankral
Copy link
Contributor

christiankral commented May 29, 2018

The electrical and magnetic potentials of some connector definition use a potential difference in the connector definitions. This seems

  1. awkward, since it the potential quantities shall be defined using a potential definition,
  2. not necessary, since potential and potential difference definitions are identical

The change is fully backwards compatible and shall be applied to the upcoming MSL 3.2.3.

Modelica.Electrical.Analog

connector Pin "Pin of an electrical component"
  SI.Voltage v "Potential at the pin"; 
end Pin;

shall be changed to:

connector Pin "Pin of an electrical component"
  SI.ElectricPotential v "Potential at the pin"; 
end Pin;

justified by the following defintions of Modelica.SIunits:

  type ElectricPotential = Real (final quantity="ElectricPotential", final unit="V");
  type Voltage = ElectricPotential;
  type PotentialDifference = ElectricPotential;

Modelica.Electrical.QuasiStationary.SinglePhase

connector Pin "Basic connector"
  Modelica.SIunits.ComplexVoltage v "Complex potential at the node";
  flow Modelica.SIunits.ComplexCurrent i "Complex current flowing into the pin";
end Pin;

shall be changed to:

  connector Pin "Basic connector"
  Modelica.SIunits.ComplexElectricPotential v "Complex potential at the node";
  flow Modelica.SIunits.ComplexCurrent i "Complex current flowing into the pin";
end Pin;

justified by the following defintions of Modelica.SIunits:

  operator record ComplexElectricPotential =
    Complex(redeclare Modelica.SIunits.ElectricPotential re "Imaginary part of complex electric potential",
            redeclare Modelica.SIunits.ElectricPotential im "Real part of complex electrical potential")
    "Complex electric potential";
  operator record ComplexPotentialDifference =
    Complex(redeclare Modelica.SIunits.PotentialDifference re "Real part of complex potential difference",
            redeclare Modelica.SIunits.PotentialDifference im "Imaginary part of complex potential difference")
    "Complex electric potential difference";
  operator record ComplexVoltage =
    Complex(redeclare Modelica.SIunits.Voltage re "Imaginary part of complex voltage",
            redeclare Modelica.SIunits.Voltage im "Real part of complex voltage")
    "Complex electrical voltage";

Modelica.Magnetic.FundamentalWave

connector MagneticPort "Complex magnetic port"
  Modelica.SIunits.ComplexMagneticPotentialDifference V_m
    "Complex magnetic potential difference";
  flow Modelica.SIunits.ComplexMagneticFlux Phi "Complex magnetic flux";
end MagneticPort;

shall be changed to:

connector MagneticPort "Complex magnetic port"
  Modelica.SIunits.ComplexMagneticPotential V_m
    "Complex magnetic potential difference";
  flow Modelica.SIunits.ComplexMagneticFlux Phi "Complex magnetic flux";
end MagneticPort;

justified by the following defintions of Modelica.SIunits:

  operator record ComplexMagneticPotential =
    Complex(redeclare Modelica.SIunits.MagneticPotential re "Real part of complex magnetic potential",
            redeclare Modelica.SIunits.MagneticPotential im "Imaginary part of complex magnetic potential")
    "Complex magnetic potential";
  operator record ComplexMagneticPotentialDifference =
    Complex(redeclare Modelica.SIunits.MagneticPotentialDifference re "Real part of complex magnetic potential difference",
            redeclare Modelica.SIunits.MagneticPotentialDifference im "Imaginary part of complex magnetic potential difference")
    "Complex magnetic potential difference";

and

  type MagneticPotential = Real (final quantity="MagneticPotential", final unit="A");
  type MagneticPotentialDifference = Real (final quantity=
          "MagneticPotential", final unit="A");
@christiankral christiankral added enhancement New feature or enhancement L: Electrical.Analog Issue addresses Modelica.Electrical.Analog L: Electrical.QuasiStationary Issue addresses Modelica.Electrical.QuasiStationary L: Magnetic.FundamentalWave Issue addresses Modelica.Magnetic.FundamentalWave V: 3.2.2 Issue originates in MSL v3.2.2 (and is not present in earlier releases) labels May 29, 2018
@christiankral christiankral added this to the MSL3.2.3 milestone May 29, 2018
@christiankral christiankral self-assigned this May 29, 2018
@christiankral christiankral changed the title Change units of potential quanities to potential units Change units of potential quanities in connectors to potential units May 29, 2018
AHaumer added a commit that referenced this issue May 29, 2018
Refs #2560: Change units of potential variables of connectors
@beutlich beutlich removed the V: 3.2.2 Issue originates in MSL v3.2.2 (and is not present in earlier releases) label May 29, 2018
@christiankral
Copy link
Contributor Author

What is the better wording of a connector definition?

  1. Potential at the pin (currently used)
  2. Potential of pin
  3. Potential of the pin (better grammar, possibly)

I think it makes sense to unify the wording of the electrical and magnetic connectors -- as they appear all so different...

@dietmarw
Copy link
Member

dietmarw commented Jun 5, 2018

My vote would be "3.".

@harmanpa
Copy link
Member

harmanpa commented Jun 5, 2018

My vote would be "1"

@HansOlsson
Copy link
Contributor

I tried to look and "potential of the" can risk confusion with another use of this - e.g. "potential of the field generated by a point source" (which is quite different).

"potential at the pin" avoid that problem (proposal 1).

@dietmarw
Copy link
Member

dietmarw commented Jun 5, 2018

...but "1." would be also fine for me. :-)

@christiankral
Copy link
Contributor Author

Thanks, I'll go for 1. 👍

@christiankral
Copy link
Contributor Author

What is the correct spelling of quasi-static?

  1. quasistatic
  2. quasi static
  3. quasi-static (provided by http://www.electropedia.org/iev/iev.nsf/display?openform&ievref=113-04-08)

@harmanpa you please help here?

@harmanpa
Copy link
Member

harmanpa commented Jun 5, 2018

I've done a quick poll of those sat near me and we say "quasi-static"

@christiankral
Copy link
Contributor Author

Thanks a lot. I will use quasi-static then.

@beutlich beutlich changed the title Change units of potential quanities in connectors to potential units Change units of potential quantities in connectors to potential units Jun 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or enhancement L: Electrical.Analog Issue addresses Modelica.Electrical.Analog L: Electrical.QuasiStationary Issue addresses Modelica.Electrical.QuasiStationary L: Magnetic.FundamentalWave Issue addresses Modelica.Magnetic.FundamentalWave
Projects
None yet
Development

No branches or pull requests

5 participants