Monday, 30 July 2012

Polynomial equations in excel

Polynomial equations in excel: Download Polynomial Formula Excel

You all must be thinking what a topic for a software professional.
After a long time I had put a depth efforts to build one excel formula to get polynomial equation value.


I have taken following reference Material:
3rd Order Polynomial Trendline
     Equation: y = (c3 * x^3) + (c2 * x^2) + (c1 * x^1) + b
     c3: =INDEX(LINEST(y,x^{1,2,3}),1)
     c2: =INDEX(LINEST(y,x^{1,2,3}),1,2)
     C1: =INDEX(LINEST(y,x^{1,2,3}),1,3)
     b: =INDEX(LINEST(y,x^{1,2,3}),1,4)

     http://office.microsoft.com/en-us/excel-help/linest-HP005209155.aspx

Based on the above I have created a 6th order Polynomial trend-line.
Assuming:
1) B2:B9 is x axis
2) C2:C9 is y axis
3) A2 is x

=(INDEX(LINEST(C2:C9,B2:B9^{1,2,3,4,5,6}),1)*A2^6)+(INDEX(LINEST(C2:C9,B2:B9^{1,2,3,4,5,6}),1,2)*A2^5)+(INDEX(LINEST(C2:C9,B2:B9^{1,2,3,4,5,6}),1,3)*A2^4)+(INDEX(LINEST(C2:C9,B2:B9^{1,2,3,4,5,6}),1,4)*A2^3)+(INDEX(LINEST(C2:C9,B2:B9^{1,2,3,4,5,6}),1,5)*A2^2)+(INDEX(LINEST(C2:C9,B2:B9^{1,2,3,4,5,6}),1,6)*A2^1)+INDEX(LINEST(C2:C9,B2:B9^{1,2,3,4,5,6}),1,7)

Share your feedback for sure.

Regards,
Sagar

Monday, 21 May 2012

WPF Architecture


Hi Friends,
Today I would  like to discuss some  core part of WPF architecutre. in  WPF ,Presentation Framework, Core Presentation and Media Integration Layer (milcore) Are The Three Major components of WPF architecture. These Are the Major portions of the WPF code. Milcore is cash en Unmanaged Code in order to enable tight integration with DirectX. DirectX engine is responsible for all display in WPF, allowing for efficient hardware and software rendering. CLR Provides fine control over the memory and execution. The composition engine in milcore is Extremely sensitive performance, and required giving up Many advantages of the CLR to gain performance.
Details


To know more about the WPF, one must have a clear idea about the architecture of WPF. The architecture of WPF is Actually multilayered architecture. It spans across Three layers - Managed Code and Unmanaged Code Core operating system, we can call thesis set of layers have built up assemblies That The Entire framework. The major components of WPF are illustrated in Figure below

Managed Layer: - The public API is only Exposed via this layer. Majority of WPF is in managed code.
1)   PresentationFramework.dll: - It Holds the top level WPF elements, Including Those That Represents Windows, panels, controls, styles etc.. It implements the aussi end-user presentation features Including time-dependent, story-based animations and data binding.
2)   PresentationCore.dll: - Presentation Core Provides a managed wrapper for MIL and implements the core services for WPF UI Element Such as visual and from Which all shapes and controls derived inPresentationFramework.dll.
3)   WindowsBase.dll: - Holds more basic Elements Which are able To Be Reused outside environment like the WPF Dispatcher Dependency objects and objects.
Unmanaged Layer
1)   milCore.dll: - While the Majority of WPF is managed in layer, the composition engine Which renders the WPF implementation is a native component. It Is Called as Media Integration Layer (MIL) and Resides InmilCore.dll. The purpose of the milcore Directly interface is to provide statement with DirectX and basic medium for 2D and 3D surface. It is the hand of WPF rendering engine and interface is Between DirectX and CLR.
2)   WindowsCodecs.dll: - WindowsCodecs is Another low level API Which is Used For imaging medium in WPF applications like image processing, image displaying and scaling etc.. It comprised of a number of codecs Which encode / decoded image vector graphics Into That Would Be Into WPF rendered screen.
Core Operating System Layer (kernel):
1)   DirectX - DirectX is the low level API-through Which WPF renders all graphics.
2)   User32: - It the primary core Every Which API implementation uses.Actually user32 memory marriages and separation process.

All WPF applications start with Two threads - one for managing the UI and Another background thread for handling the rendering and repainting.Rendering and repainting is managed by WPF and so it does not require Any developer intervention.