179 if (componentNorm > norm) norm = componentNorm;
182 componentNorm = (fQ_abs.
Abs()).
Max();
183 if (componentNorm > norm) norm = componentNorm;
186 if (componentNorm > norm) norm = componentNorm;
189 componentNorm = (fA_abs.
Abs()).
Max();
190 if (componentNorm > norm) norm = componentNorm;
193 componentNorm = (fC_abs.
Abs()).
Max();
194 if (componentNorm > norm) norm = componentNorm;
198 if (componentNorm > norm) norm = componentNorm;
202 if (componentNorm > norm) norm = componentNorm;
206 if (componentNorm > norm) norm = componentNorm;
210 if (componentNorm > norm) norm = componentNorm;
289 this->
Qmult(1.0,tmp,0.5,vars->
fX);
338 if (
this != &source) {
virtual void Qmult(Double_t beta, TVectorD &y, Double_t alpha, const TVectorD &x)
calculate y = beta*y + alpha*(fQ*x)
TVectorT< Element > & ResizeTo(Int_t lwb, Int_t upb)
Resize the vector to [lwb:upb] .
TQpDataBase & operator=(const TQpDataBase &source)
Assignment operator.
void Add(THist< DIMENSION, PRECISIONA > &to, THist< DIMENSION, PRECISIONB > &from)
virtual TMatrixTBase< Element > & ResizeTo(Int_t nrows, Int_t ncols, Int_t=-1)
Set size of the matrix to nrows x ncols New dynamic elements are created, the overlapping part of the...
TMatrixTSym< Element > & Use(Int_t row_lwb, Int_t row_upb, Element *data)
virtual void Print(Option_t *opt="") const
Print all class members.
virtual void PutQIntoAt(TMatrixDBase &M, Int_t row, Int_t col)
Insert the Hessian Q into the matrix M at index (row,col) for the fundamental linear system...
Int_t GetNoElements() const
Short_t Min(Short_t a, Short_t b)
ClassImp(TQpDataDens) TQpDataDens
Constructor.
virtual TMatrixTBase< Element > & ResizeTo(Int_t nrows, Int_t ncols, Int_t=-1)
Set size of the matrix to nrows x ncols New dynamic elements are created, the overlapping part of the...
double beta(double x, double y)
Calculates the beta function.
virtual void Cmult(Double_t beta, TVectorD &y, Double_t alpha, const TVectorD &x)
calculate y = beta*y + alpha*(fC*x)
virtual void PutCIntoAt(TMatrixDBase &M, Int_t row, Int_t col)
Insert the constraint matrix C into the matrix M at index (row,col) for the fundamental linear system...
void Randomize(Element alpha, Element beta, Double_t &seed)
randomize vector elements value
virtual void Amult(Double_t beta, TVectorD &y, Double_t alpha, const TVectorD &x)
calculate y = beta*y + alpha*(fA*x)
virtual Double_t ObjectiveValue(TQpVar *vars)
Return value of the objective function.
virtual void CTransmult(Double_t beta, TVectorD &y, Double_t alpha, const TVectorD &x)
calculate y = beta*y + alpha*(fC^T*x)
virtual void PutAIntoAt(TMatrixDBase &M, Int_t row, Int_t col)
Insert the constraint matrix A into the matrix M at index (row,col) for the fundamental linear system...
virtual void DataRandom(TVectorD &x, TVectorD &y, TVectorD &z, TVectorD &s)
Choose randomly a QP problem.
TMatrixT< Double_t > TMatrixD
void Print(Option_t *name="") const
Print the matrix as a table of elements.
void Print(Option_t *option="") const
Print the vector as a list of elements.
TQpDataDens & operator=(const TQpDataDens &source)
Assignment operator.
virtual void GetDiagonalOfQ(TVectorD &dQ)
Return in vector dq the diagonal of matrix fQ (Quadratic part of Objective function) ...
Element NormInf() const
Compute the infinity-norm of the vector MAX{ |v[i]| }.
virtual TMatrixTBase< Element > & SetSub(Int_t row_lwb, Int_t col_lwb, const TMatrixTBase< Element > &source)=0
virtual TMatrixTBase< Element > & Randomize(Element alpha, Element beta, Double_t &seed)
Randomize matrix element values.
TMatrixTDiag< Double_t > TMatrixDDiag
virtual void ATransmult(Double_t beta, TVectorD &y, Double_t alpha, const TVectorD &x)
calculate y = beta*y + alpha*(fA^T*x)
TVectorT< Element > & SelectNonZeros(const TVectorT< Element > &select)
Keep only element as selected through array select non-zero.
virtual Double_t DataNorm()
Return the largest component of several vectors in the data class.
virtual TMatrixTSym< Element > & RandomizePD(Element alpha, Element beta, Double_t &seed)
randomize matrix element values but keep matrix symmetric positive definite
static void RandomlyChooseBoundedVariables(TVectorD &x, TVectorD &dualx, TVectorD &blx, TVectorD &ixlow, TVectorD &bux, TVectorD &ixupp, Double_t &ix, Double_t percentLowerOnly, Double_t percentUpperOnly, Double_t percentBound)
Randomly choose x and its boundaries.
TMatrixT< Element > & Use(Int_t row_lwb, Int_t row_upb, Int_t col_lwb, Int_t col_upb, Element *data)
Use the array data to fill the matrix ([row_lwb..row_upb] x [col_lwb..col_upb])
Short_t Max(Short_t a, Short_t b)
Bool_t MatchesNonZeroPattern(const TVectorT< Element > &select)
Check if vector elements as selected through array select are non-zero.
double norm(double *x, double *p)
virtual TMatrixTBase< Element > & Abs()
Take an absolute value of a matrix, i.e. apply Abs() to each element.