FreeHEP API
Version current

hep.aida.ref.function
Class BaseModelFunction

java.lang.Object
  extended byhep.aida.ref.event.AIDAObservable
      extended byhep.aida.ref.ManagedObject
          extended byhep.aida.ref.function.BaseModelFunction
All Implemented Interfaces:
Connectable, FunctionDispatcher, hep.aida.dev.IDevManagedObject, hep.aida.IFunction, hep.aida.IManagedObject, hep.aida.IModelFunction
Direct Known Subclasses:
JELBaseModelFunction

public class BaseModelFunction
extends ManagedObject
implements hep.aida.IModelFunction, FunctionDispatcher

Author:
serbo
Source Code:
BaseModelFunction.java

Field Summary
protected  hep.aida.IAnnotation annotation
           
protected  String codeletString
           
protected  FunctionCore function
           
protected  FunctionCore functionNormalized
           
protected  FunctionCore functionNotNormalized
           
protected  String title
           
protected  String[] varNames
           
 
Fields inherited from class hep.aida.ref.ManagedObject
fillable
 
Fields inherited from class hep.aida.ref.event.AIDAObservable
connectionDidChange, isConnected, isValid
 
Constructor Summary
protected BaseModelFunction()
           
  BaseModelFunction(String name, String title, FunctionCore notNorm, FunctionCore norm)
           
  BaseModelFunction(String name, String tit, hep.aida.IFunction func)
           
 
Method Summary
 void addFunctionListener(FunctionListener listener)
           
 hep.aida.IAnnotation annotation()
           
 void calculateNormalizationAmplitude()
           
 String codeletString()
           
 FunctionCore core()
           
 int dimension()
           
 void excludeNormalizationAll()
           
 double functionValue(double[] var)
           
 RangeSet[] getRangeSet()
           
 double[] gradient(double[] x)
           
 void includeNormalizationAll()
           
 int indexOfParameter(String name)
           
protected  void init(String tit, FunctionCore notNorm, FunctionCore norm)
           
 boolean isEqual(hep.aida.IFunction f)
           
 boolean isNormalized()
           
 String normalizationParameter()
           
 hep.aida.IRangeSet normalizationRange(int iAxis)
           
 void normalize(boolean on)
           
 int numberOfParameters()
           
 double[] numericGradient(double[] x)
           
 double[] numericParameterGradient(double[] x)
           
 double parameter(String name)
           
 double[] parameterGradient(double[] x)
           
 String[] parameterNames()
           
 double[] parameters()
           
 boolean providesGradient()
           
 boolean providesNormalization()
           
 boolean providesParameterGradient()
           
 void removeFunctionListener(FunctionListener listener)
           
 void setCodeletString(String codelet)
           
 void setParameter(String name, double x)
           
 boolean setParameterNames(String[] params)
           
 void setParameters(double[] params)
           
 void setTitle(String t)
           
 String title()
           
 String toString()
           
 double value(double[] var)
           
 String variableName(int i)
           
 String[] variableNames()
           
 
Methods inherited from class hep.aida.ref.ManagedObject
isFillable, name, setFillable, setName, type
 
Methods inherited from class hep.aida.ref.event.AIDAObservable
addListener, createEvent, fireStateChanged, fireStateChanged, fireStateChanged, isConnected, removeAllListeners, removeListener, setConnected, setIsValidAfterNotify, setValid, setValidForAll
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface hep.aida.ref.event.Connectable
isConnected, setConnected
 

Field Detail

varNames

protected String[] varNames

annotation

protected hep.aida.IAnnotation annotation

codeletString

protected String codeletString

title

protected String title

function

protected FunctionCore function

functionNotNormalized

protected FunctionCore functionNotNormalized

functionNormalized

protected FunctionCore functionNormalized
Constructor Detail

BaseModelFunction

protected BaseModelFunction()

BaseModelFunction

public BaseModelFunction(String name,
                         String tit,
                         hep.aida.IFunction func)

BaseModelFunction

public BaseModelFunction(String name,
                         String title,
                         FunctionCore notNorm,
                         FunctionCore norm)
Method Detail

init

protected void init(String tit,
                    FunctionCore notNorm,
                    FunctionCore norm)

core

public FunctionCore core()

dimension

public int dimension()
Specified by:
dimension in interface hep.aida.IFunction

numberOfParameters

public int numberOfParameters()
Specified by:
numberOfParameters in interface hep.aida.IFunction

functionValue

public double functionValue(double[] var)

value

public final double value(double[] var)
Specified by:
value in interface hep.aida.IFunction

annotation

public hep.aida.IAnnotation annotation()
Specified by:
annotation in interface hep.aida.IFunction

variableName

public String variableName(int i)
Specified by:
variableName in interface hep.aida.IFunction

variableNames

public String[] variableNames()
Specified by:
variableNames in interface hep.aida.IFunction

parameterNames

public String[] parameterNames()
Specified by:
parameterNames in interface hep.aida.IFunction

indexOfParameter

public int indexOfParameter(String name)
Specified by:
indexOfParameter in interface hep.aida.IFunction

setParameters

public void setParameters(double[] params)
Specified by:
setParameters in interface hep.aida.IFunction

setParameter

public void setParameter(String name,
                         double x)
                  throws IllegalArgumentException
Specified by:
setParameter in interface hep.aida.IFunction
Throws:
IllegalArgumentException

parameters

public double[] parameters()
Specified by:
parameters in interface hep.aida.IFunction

parameter

public double parameter(String name)
Specified by:
parameter in interface hep.aida.IFunction

isEqual

public boolean isEqual(hep.aida.IFunction f)
Specified by:
isEqual in interface hep.aida.IFunction

providesGradient

public boolean providesGradient()
Specified by:
providesGradient in interface hep.aida.IFunction

gradient

public double[] gradient(double[] x)
Specified by:
gradient in interface hep.aida.IFunction

codeletString

public String codeletString()
Specified by:
codeletString in interface hep.aida.IFunction

setCodeletString

public void setCodeletString(String codelet)

normalizationParameter

public String normalizationParameter()
Specified by:
normalizationParameter in interface hep.aida.IFunction

providesNormalization

public boolean providesNormalization()
Specified by:
providesNormalization in interface hep.aida.IModelFunction

normalize

public void normalize(boolean on)
Specified by:
normalize in interface hep.aida.IModelFunction

isNormalized

public boolean isNormalized()
Specified by:
isNormalized in interface hep.aida.IModelFunction

parameterGradient

public double[] parameterGradient(double[] x)
Specified by:
parameterGradient in interface hep.aida.IModelFunction

providesParameterGradient

public boolean providesParameterGradient()
Specified by:
providesParameterGradient in interface hep.aida.IModelFunction

normalizationRange

public hep.aida.IRangeSet normalizationRange(int iAxis)
Specified by:
normalizationRange in interface hep.aida.IModelFunction

includeNormalizationAll

public void includeNormalizationAll()
Specified by:
includeNormalizationAll in interface hep.aida.IModelFunction

excludeNormalizationAll

public void excludeNormalizationAll()
Specified by:
excludeNormalizationAll in interface hep.aida.IModelFunction

calculateNormalizationAmplitude

public void calculateNormalizationAmplitude()

title

public String title()
Specified by:
title in interface hep.aida.IFunction

setTitle

public void setTitle(String t)
Specified by:
setTitle in interface hep.aida.IFunction

setParameterNames

public boolean setParameterNames(String[] params)

numericGradient

public double[] numericGradient(double[] x)

numericParameterGradient

public double[] numericParameterGradient(double[] x)

getRangeSet

public RangeSet[] getRangeSet()

toString

public String toString()

addFunctionListener

public void addFunctionListener(FunctionListener listener)
Specified by:
addFunctionListener in interface FunctionDispatcher

removeFunctionListener

public void removeFunctionListener(FunctionListener listener)
Specified by:
removeFunctionListener in interface FunctionDispatcher

FreeHEP API
Version current

Copyright © 2000-2004 FreeHEP, All Rights Reserved.