Function1D

一个参数的函数。

JSON 表示法
{

  // Union field function can be only one of the following:
  "constant": number,
  "pwl": {
    object (PieceWiseAffineFunction)
  }
  // End of list of possible types for union field function.
}
字段
联合字段 function。该函数的参数的统一性应为:- 如果重量为 kg - 如果是时间:min - 如果托盘数为:1 function 只能为以下之一:
constant

number

该函数是一个常量。

pwl

object (PieceWiseAffineFunction)

该函数为分段线性函数。

PieceWiseAffineFunction

逐段线性函数,限于一个参数。设计类似于 https://github.com/google/or-tools/blob/stable/ortools/util/piecewise_linear_function.h

JSON 表示法
{
  "segments": [
    {
      object (PieceWiseAffineSegment)
    }
  ]
}
字段
segments[]

object (PieceWiseAffineSegment)

函数的线性细分。

PieceWiseAffineSegment

分段线性函数的一段。

JSON 表示法
{
  "startX": number,
  "startY": number,
  "endX": number,
  "endY": number
}
字段
startX

number

细分的开头:x。

startY

number

片段的开头:y。

endX

number

片段结束:x。

endY

number

细分的终点:y。