Nevron .NET Vision
Nevron.Diagram.Layout Namespace / NDesiredDistanceForce Class
Members


In This Topic
    NDesiredDistanceForce Class
    In This Topic
    The NDesiredDistanceForce is a force, which couples an attraction force (edge force), and a repulsion force (vertex force). The two forces balance each other when the distance between connected vertices is equal to the specified desired distance.
    Object Model
    NDesiredDistanceForce Class
    Syntax
    'Declaration
     
    
    <System.ComponentModel.TypeConverterAttribute(Nevron.Internal.jrhE)>
    Public Class NDesiredDistanceForce 
       Inherits NForce
       Implements Nevron.Dom.INAttribute, Nevron.Dom.INHistoryCallback, Nevron.INReferenceHolder, Nevron.INReferenceProvider 
    'Usage
     
    
    Dim instance As NDesiredDistanceForce
    [System.ComponentModel.TypeConverter(Nevron.Internal.jrhE)]
    public class NDesiredDistanceForce : NForce, Nevron.Dom.INAttribute, Nevron.Dom.INHistoryCallback, Nevron.INReferenceHolder, Nevron.INReferenceProvider  
    Remarks
    The attraction force magnitute is computed by the following formula:

    AttractionCoefficient * Math.Pow(distance, 2) / Math.Pow(DesiredDistance, 2)

    The repulsion force magnitute is computed by the following formula:

    RepulsionCoefficient * Math.Pow(DesiredDistance, 2) / Math.Pow(distance, 2)

    Provided that the RepulsionCoefficient and AttractionCoefficient are equal, the two forces balance each other at DesiredDistance.

    Inheritance Hierarchy

    System.Object
       Nevron.Dom.NAttribute
          Nevron.Diagram.Layout.NForce
             Nevron.Diagram.Layout.NDesiredDistanceForce

    Requirements

    Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

    See Also