@@ -3166,6 +3166,26 @@ def objective_coefficients(self):
3166
3166
(10, 5)
3167
3167
"""
3168
3168
3169
+ @abstract_method
3170
+ def objective_name (self ):
3171
+ r"""
3172
+ Return the objective name of ``self``.
3173
+
3174
+ OUTPUT:
3175
+
3176
+ - a symbolic expression
3177
+
3178
+ EXAMPLES::
3179
+
3180
+ sage: A = ([1, 1], [3, 1])
3181
+ sage: b = (1000, 1500)
3182
+ sage: c = (10, 5)
3183
+ sage: P = InteractiveLPProblemStandardForm(A, b, c)
3184
+ sage: D = P.initial_dictionary()
3185
+ sage: D.objective_name()
3186
+ z
3187
+ """
3188
+
3169
3189
@abstract_method
3170
3190
def objective_value (self ):
3171
3191
r"""
@@ -3983,6 +4003,26 @@ def objective_coefficients(self):
3983
4003
"""
3984
4004
return self ._AbcvBNz [2 ]
3985
4005
4006
+ def objective_name (self ):
4007
+ r"""
4008
+ Return the objective name of ``self``.
4009
+
4010
+ OUTPUT:
4011
+
4012
+ - a symbolic expression
4013
+
4014
+ EXAMPLES::
4015
+
4016
+ sage: A = ([1, 1], [3, 1])
4017
+ sage: b = (1000, 1500)
4018
+ sage: c = (10, 5)
4019
+ sage: P = InteractiveLPProblemStandardForm(A, b, c)
4020
+ sage: D = P.initial_dictionary()
4021
+ sage: D.objective_name()
4022
+ z
4023
+ """
4024
+ return self ._AbcvBNz [6 ]
4025
+
3986
4026
def objective_value (self ):
3987
4027
r"""
3988
4028
Return the value of the objective at the
@@ -4932,6 +4972,26 @@ def objective_coefficients(self):
4932
4972
"""
4933
4973
return self .c_N () - self .y () * self .A_N ()
4934
4974
4975
+ def objective_name (self ):
4976
+ r"""
4977
+ Return the objective name of ``self``.
4978
+
4979
+ OUTPUT:
4980
+
4981
+ - a symbolic expression
4982
+
4983
+ EXAMPLES::
4984
+
4985
+ sage: A = ([1, 1], [3, 1])
4986
+ sage: b = (1000, 1500)
4987
+ sage: c = (10, 5)
4988
+ sage: P = InteractiveLPProblemStandardForm(A, b, c)
4989
+ sage: D = P.revised_dictionary()
4990
+ sage: D.objective_name()
4991
+ z
4992
+ """
4993
+ return self .problem ().objective_name ()
4994
+
4935
4995
def objective_value (self ):
4936
4996
r"""
4937
4997
Return the value of the objective at the basic solution of ``self``.
0 commit comments