Specify the function being optimized
@param function Function to optimize
@param funcMinValue Minimum possible function value. E.g. 0 for least squares.
550281
public void setFunction( GradientLineFunction function , double funcMinValue ) {
		this.function = function;
		this.funcMinValue = funcMinValue;

		lineSearch.setFunction(function,funcMinValue);
		N = function.getN();

		B = new DMatrixRMaj(N,N);
		searchVector = new DMatrixRMaj(N,1);
		g = new DMatrixRMaj(N,1);
		s = new DMatrixRMaj(N,1);
		y = new DMatrixRMaj(N,1);
		x = new DMatrixRMaj(N,1);

		temp0_Nx1 = new DMatrixRMaj(N,1);
		temp1_Nx1 = new DMatrixRMaj(N,1);
	}
1190119
@SuppressWarnings("static-method")
	protected boolean isDefaultValuedParameterFunction(XtendFunction function) {
		for (final XtendParameter parameter : function.getParameters()) {
			if (parameter instanceof SarlFormalParameter) {
				final SarlFormalParameter sarlParameter = (SarlFormalParameter) parameter;
				if (sarlParameter.getDefaultValue() != null) {
					return true;
				}
			}
		}
		return false;
	}
921647
public static <T, R> Supplier<R> curry(Function<T, R> function, T value) {
        dbc.precondition(function != null, "cannot bind parameter of a null function");
        return () -> function.apply(value);
    }
252943
public void setValue(float value, boolean animation){
        value = Math.min(mMaxValue, Math.max(value, mMinValue));
        setPosition((value - mMinValue) / (mMaxValue - mMinValue), animation);
    }
761549
private void setNormalizedMinValue(double value) {
        normalizedMinValue = Math.max(0d, Math.min(1d, Math.min(value, normalizedMaxValue)));
        invalidate();
    }
1027692
public void setPreventResponseFlush(String configValue) {

        OpenCms.getSystemInfo().getServletContainerSettings().setPreventResponseFlush(
            Boolean.valueOf(configValue).booleanValue());
    }
1214657
public final value_function_return value_function() throws RecognitionException {
        value_function_return retval = new value_function_return();
        retval.start = input.LT(1);


        CommonTree root_0 = null;

        equality_value_function_return equality_value_function85 =null;

        compariable_value_function_return compariable_value_function86 =null;



        try {
            // MessageFilter.g:169:2: ( equality_value_function | compariable_value_function )
            int alt12=2;
            int LA12_0 = input.LA(1);

            if ( (LA12_0==FALSE||LA12_0==NULL||LA12_0==STRING||LA12_0==TRUE||LA12_0==XPATH_FUN_NAME) ) {
                alt12=1;
            }
            else if ( (LA12_0==EOF||LA12_0==AND||LA12_0==NUMBER||LA12_0==OR||(LA12_0 >= TIME_MILLIS_FUN_NAME && LA12_0 <= TIME_STRING_FUN_NAME)||(LA12_0 >= 34 && LA12_0 <= 35)) ) {
                alt12=2;
            }
            else {
                NoViableAltException nvae =
                    new NoViableAltException("", 12, 0, input);

                throw nvae;

            }
            switch (alt12) {
                case 1 :
                    // MessageFilter.g:169:4: equality_value_function
                    {
                    root_0 = (CommonTree)adaptor.nil();


                    pushFollow(FOLLOW_equality_value_function_in_value_function1022);
                    equality_value_function85=equality_value_function();

                    state._fsp--;

                    adaptor.addChild(root_0, equality_value_function85.getTree());

                    }
                    break;
                case 2 :
                    // MessageFilter.g:169:30: compariable_value_function
                    {
                    root_0 = (CommonTree)adaptor.nil();


                    pushFollow(FOLLOW_compariable_value_function_in_value_function1026);
                    compariable_value_function86=compariable_value_function();

                    state._fsp--;

                    adaptor.addChild(root_0, compariable_value_function86.getTree());

                    }
                    break;

            }
            retval.stop = input.LT(-1);


            retval.tree = (CommonTree)adaptor.rulePostProcessing(root_0);
            adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
    	retval.tree = (CommonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);

        }

        finally {
        	// do for sure before leaving
        }
        return retval;
    }
975137
private int handleSpecialFunctions()
    {

        boolean needsSpecialAttention = false;
        outer: for (UpdateClause c : kunderaQuery.getUpdateClauseQueue())
        {
            for (int i = 0; i < FUNCTION_KEYWORDS.length; i++)
            {
                if (c.getValue() instanceof String)
                {
                    String func = c.getValue().toString();
                    func = func.replaceAll(" ", "");
                    if (func.toUpperCase().matches(FUNCTION_KEYWORDS[i]))
                    {
                        needsSpecialAttention = true;
                        c.setValue(func);
                        break outer;
                    }
                }
            }
        }

        if (!needsSpecialAttention)
            return -1;

        EntityMetadata m = getEntityMetadata();
        Metamodel metaModel = kunderaMetadata.getApplicationMetadata().getMetamodel(m.getPersistenceUnit());
        Queue filterClauseQueue = kunderaQuery.getFilterClauseQueue();
        BasicDBObject query = createMongoQuery(m, filterClauseQueue);

        BasicDBObject update = new BasicDBObject();
        for (UpdateClause c : kunderaQuery.getUpdateClauseQueue())
        {
            String columName = getColumnName(m, metaModel.entity(m.getEntityClazz()), c.getProperty());
            boolean isSpecialFunction = false;
            for (int i = 0; i < FUNCTION_KEYWORDS.length; i++)
            {

                if (c.getValue() instanceof String
                        && c.getValue().toString().toUpperCase().matches(FUNCTION_KEYWORDS[i]))
                {
                    isSpecialFunction = true;

                    if (c.getValue().toString().toUpperCase().startsWith("INCREMENT("))
                    {
                        String val = c.getValue().toString().toUpperCase();
                        val = val.substring(10, val.indexOf(")"));
                        update.put("$inc", new BasicDBObject(columName, Integer.valueOf(val)));
                    }
                    else if (c.getValue().toString().toUpperCase().startsWith("DECREMENT("))
                    {
                        String val = c.getValue().toString().toUpperCase();
                        val = val.substring(10, val.indexOf(")"));
                        update.put("$inc", new BasicDBObject(columName, -Integer.valueOf(val)));
                    }
                }
            }
            if (!isSpecialFunction)
            {
                update.put(columName, c.getValue());
            }
        }

        Client client = persistenceDelegeator.getClient(m);
        return ((MongoDBClient) client).handleUpdateFunctions(query, update, m.getTableName());
    }
181211
static
	public void putFunction(String name, Function function){
		FunctionRegistry.functions.put(Objects.requireNonNull(name), function);
	}
62340
public static DefaultValueFunction defaultValue(Function function, Object defaultValue) {

		Assert.notNull(function, "Function must not be 'null' for default value operation.");
		Assert.notNull(defaultValue, "DefaultValue must not be 'null'.");

		return new DefaultValueFunction(function, defaultValue);
	}
177837
@ForOverride
  protected SoyValue computeFunctionHelper(
      SoyJavaSourceFunction fn, List<SoyValue> args, final FunctionNode fnNode) {
    try {
      return new TofuValueFactory(fnNode, pluginInstances).computeForJava(fn, args, context);
    } catch (Exception e) {
      throw RenderException.create(
          "While computing function \"" + fnNode.toSourceString() + "\": " + e.getMessage(), e);
    }
  }
61282
public final CALC function(Class<? extends Function> function, Object... values) {
        Function fn = CacheExtension.getFunction(function);
        FunctionData fd = new FunctionData(fn, values);
        this.infix.addFunction(fd);

        return getThis();
    }
972828
public static void mixin(final String funcName, final Function<String, String> func) {
        FUNCTIONS.put(funcName, func);
    }
18902
@Override
    public void init(DifferentiableBatchFunction function) {
        gradSumSquares = new double[function.getNumDimensions()];
        Arrays.fill(gradSumSquares, prm.initialSumSquares);
    }
450618
public void setFunction(String prefix, String localName, Method method) {
		if (functions == null) {
			functions = new Functions();
		}
		functions.setFunction(prefix, localName, method);
	}
12445
function ComputedProperty(func, opts) {
  this.func = func;

  this._cacheable = (opts && opts.cacheable !== undefined) ? opts.cacheable : true;
  this._dependentKeys = opts && opts.dependentKeys;
  this._readOnly = opts && (opts.readOnly !== undefined || !!opts.readOnly);
}
1327699
public void updateAt(int i, int j, MatrixFunction function) {
        set(i, j, function.evaluate(i, j, get(i, j)));
    }