Class Optimizer

    • Field Detail

      • particles

        public TypedIOPort particles
        Particles input that accepts an array of record tokens. One field of the record must be labeled as "weight". Other fields will be resolved to state variables.
      • locations

        public PortParameter locations
        An Array of record tokens.
      • covariance

        public Parameter covariance
        The coveariance.
      • speedLimit

        public Parameter speedLimit
        The speed limit.
      • rhoBeg

        public Parameter rhoBeg
        The beginning of rho.
      • rhoEnd

        public Parameter rhoEnd
        The end of rho.
    • Constructor Detail

      • Optimizer

        public Optimizer​(Workspace workspace)
        Construct an Optimizer in the specified workspace with no container and an empty string as a name. You can then change the name with setName(). If the workspace argument is null, then use the default workspace.
        Parameters:
        workspace - The workspace that will list the actor.
    • Method Detail

      • attributeChanged

        public void attributeChanged​(Attribute attribute)
                              throws IllegalActionException
        Description copied from class: NamedObj
        React to a change in an attribute. This method is called by a contained attribute when its value changes. In this base class, the method does nothing. In derived classes, this method may throw an exception, indicating that the new attribute value is invalid. It is up to the caller to restore the attribute to a valid value if an exception is thrown.
        Overrides:
        attributeChanged in class NamedObj
        Parameters:
        attribute - The attribute that changed.
        Throws:
        IllegalActionException - If the change is not acceptable to this container (not thrown in this base class).
      • postfire

        public boolean postfire()
                         throws IllegalActionException
        Description copied from class: AtomicActor
        Return true, unless stop() has been called, in which case, return false. Derived classes override this method to define operations to be performed at the end of every iteration of its execution, after one invocation of the prefire() method and any number of invocations of the fire() method. This method typically wraps up an iteration, which may involve updating local state. In derived classes, this method returns false to indicate that this actor should not be fired again.
        Specified by:
        postfire in interface Executable
        Overrides:
        postfire in class AtomicActor<TypedIOPort>
        Returns:
        True if execution can continue into the next iteration.
        Throws:
        IllegalActionException - Not thrown in this base class.