Welcome to Visual Calculator


 
generate/calc.jpg

Visual Calculator for SansGUI has been created to demonstrate some fundamental capabilities of the SansGUI Modeling and Simulation Environment. This calculator has some simple arithmetic operators and functions built in. It is different from a regular calculator in that the mathematical expressions in Visual Calculator are built by the users in visual diagrams. With this, the relationship of operators and operands can be visualized. In addition to having it as a fun project, our objectives are to introduce a few useful run-time facilities in SansGUI to simulation users and some basic implementation techniques to simulation developers. The Schema Definition and the calculation engine with full source code implemented independently in both Microsoft Visual C++ and Compaq Visual Fortran are included.

Version 1.1 Release Notes

A new class, Constant, is introduced in version 1.1. Similar to the Variable class, it has a Value attribute. The difference between the two is that the scope of the Value attribute is Input in class Constant, but is In/Out in class Variable. Therefore, when the user clears all the overriding values or clicks on the Reset Data button in the Run toolbar, the overriding values in the parts that are derived from class Variable will be wiped off; whereas those in class Constant derived parts will be kept intact. The examples have been modified to take advantage of the new Constant class.

The other enhancement in this version is the algorithm of generating damped sine waves in the SineGen class. The damping factor is linearly interpolated inside within circular cycle, rather than staying constant as in version 1.0. With this enhancement, the discontinuity of the curve at the joint of two adjacent cycles is eliminated.

Although Visual Calculator version 1.1 can work with SansGUI version 1.0, it is recommended that you upgrade SansGUI to version 1.1 to take advantage of the new features, including dynamic charting. Both Example 3 and Example 4 contain plotting of dynamic data values. The dynamic charting feature is available right away without any extra coding in Visual Calculator.

System Requirements

This program requires the SansGUI Run-Time Environment. The demonstration version of SansGUI (SGdemo, available from ProtoDesign's web site) can be used to run the pre-built project or create new ones of your own. With the SGdemo edition, however, you cannot save your work for future access. Optionally, the SansGUI Development Environment in the Professional Edition can be used to modify the Schema Definition and extend the calculator's capability. You are invited to make it a full-blown scientific calculator.

Installation

Before installing Visual Calculator for SansGUI version 1.1, you need to have the SansGUI Run-Time Environment installed on your computer. The Visual Calculator utility program is distributed in a self-extracting archive executable file in the SansGUI software distrubution CD and from ProtoDesign's web site. To install it, simply run the executable file and follow the instructions. An important note is that the files should be installed into the SansGUI directory structure. That is, during the installation process, it will ask you where to install Visual Calculator for SansGUI in an Unzip to folder: field. You need to indicate where your SansGUI installation directory is. If the shown directory matches the one you chose when you installed SansGUI, you can simply use the default value here; otherwise, click on the Browse... button to locate the SansGUI installation directory. The SansGUI installation directory is the one containing SansGUI Release.txt and License.txt files.

Visual Calculator for SansGUI Files

 

File

Description

lib\Calc_1_1.sgo

Visual Calculator Object Library

sim\Calc_1_1.dll

Visual Calculator main program DLL

doc\Calc\*.*

On-line documentation files

doc\Calc\Generate\*.*

Picture files for on-line documentation

samples\Calc\Calc.sgs

Schema Definition of Visual Calculator

samples\Calc\*.ico

Icon files for Visual Calculator classes

samples\Calc\Calc_1_1\*.*

Visual Calculator project for MSVC++

samples\Calc\Calc_1_1F\*.*

Visual Calculator project for CVF

samples\Calc\Calc_1_1_0_0\*.*

C/C++ and Fortran source files

samples\Calc\Simple.sgp

Example 1: A Simple Equation

samples\Calc\QuadRoot.sgp

Example 2: Roots of Quadratic Equations

samples\Calc\Cubic.sgp

Example 3: Curves of Cubic Equations

samples\Calc\SineTest.sgp

Example 4: Damped Sine Wave Generator

samples\Calc\Intro.sgp

Example Project Model from Introduction

Getting Started

Please go to the next section, titled Introduction, of this manual.

Technical Support

For technical assistance on SansGUI, please contact:

mailto:support@protodesign-inc.com

http://sansgui.com/support.htm or

http://protodesign-inc.com/support.htm

Phone: (630) 759-9930

Fax: (630)759-4759

Copyright and License

Copyright 2001-2003 ProtoDesign, Inc. All rights reserved.

The Visual Calculator for SansGUI utility program and its documentation are copyrighted by ProtoDesign, Inc. and are provided "AS-IS" without warranty of any kind, express or implied. Neither ProtoDesign, Inc. nor its distributors will be held liable for any damage caused or alleged to be caused either directly or indirectly by this software.

Redistribution of the utility program in its original form without modification is permitted. In addition, you are encouraged to create full-feature calculators based upon this demonstration program, using the SansGUI Modeling and Simulation Environment. You can distribute, commercially or non-commercially, your extended work provided that:

The SansGUI Software and its documentation, on-line and printed, are copyrighted by ProtoDesign, Inc. The use of these materials are restricted by the license agreement accepted by the user during the software installation process.

Trademarks

SansGUI and its logo is a registered trademark and ProtoDesign and its logo is a registered service mark of ProtoDesign, Inc. Microsoft Windows is a registered trademark of Microsoft Corporation. All other trademarks are owned by the respective companies.

 



Introduction

Visual Calculator for SansGUI Version 1.1

Copyright 2001-2003 ProtoDesign, Inc. All rights reserved.

http://protodesign-inc.com