Opened 7 years ago

Last modified 7 years ago

#4801 new defect

Possible display unit are handled differently for variables and outputs (and inputs)

Reported by: Christian Kral <dr.christian.kral@…> Owned by: Adeel Asghar
Priority: high Milestone: Future
Component: OMEdit Version: v1.13.0-dev-nightly
Keywords: Cc:

Description

Please consider the following example, which is triggered by investigations related with https://github.com/modelica/Modelica/issues/2488:

package TestAngle
  block AngleBlock
    parameter Modelica.SIunits.Angle phi = 0.1 "Angle";
    extends Modelica.Blocks.Interfaces.SO(y(unit="rad"));
  equation
    y=phi;
  end AngleBlock;
  model TestAngleBlock
    AngleBlock angleBlock 
      annotation (Placement(transformation(extent={{-10,-10},{10,10}})));
  end TestAngleBlock;
  annotation (uses(Modelica(version="3.2.2")));
end TestAngle;

When simulating the example TestAngleBlock two variables can be plotted:

  • angleBlock.phi: when plotted, displayUnit = "deg" but can be switched to "rad" as well
  • angleBlock.: the only available displayUnit is "rad"

So when both variables are plotted, only one can be displayed in "deg". I think both variables should have the option to be shown in "deg".

Change History (1)

comment:1 by Christian Kral <dr.christian.kral@…>, 7 years ago

Component: *unknown*OMEdit
Owner: changed from somebody to Adeel Asghar
Version: v1.13.0-dev-nightly
Note: See TracTickets for help on using tickets.