Starting from:

$25

Soft Computing-Assignment 2 Function Classes and Call Display Member Functions Solved

(1)   Analyze the data structure of the functions defined in the last assignment. Wrap up each function with a C# class. Define parameters as a private array of double type. In addition, define the list of

parameter names as a public static array of string type. Note that the t() is a Triangle function, g() is a Gaussian function, and b() is a Bell function. Therefore, name parameter names of each class meaningful names; e.g., Left, Peak, Right for parameters a, b, c of the TriangularFunction.

(2)   Define a public function (method) for each class to return the function value for a given value of x. E.g., public double GetFunctionValue( double x );

(3)   Define a constructor for each class to let user initialize the parameters.

(4)   A ListBox object lists the type names of the implemented function classes to let user to select a

function type to dynamically create and display a function object. Alternatively, a number of RadioButton objects can serve the same functionalities. When a target type is selected, the UI controls should be updated (hide or show) for the user to specify parameter values.

(5)   Change the code in button-click event handling function to create a function object and display its line by calling the GetFunctionValue() method of each object of function class. When a function object is new-ed, a series object is run-time added to the chart object (via its Series property). Since objects of these functions are dynamically created, how can we change their parameter values and update their line displays?  

(6)    In addition, add a new function class to deal with the following function (Sigmoidal function): sig(x a c; , )=

 

(7)   Prepare a folder named as <your ID<your nameAss02 to put your source code in it. Compress the folder of your source code into an RAR or a ZIP file and submit to COOL. Remember to add as many comments as possible in your source code.

 

Notes:

1  Exercise the uses of the following controls (primary properties and events):

NumericalUpDown, TrackBar, ComboBox, ListBox

2  Think about how to specify the title, range, and resolution of the x-axis as a class to serve for these function objects.

3  Think about how to deal with the line charts (object of Series), which of them seems belong to each object of the function class.

More products