Idea Contributions
Everett George expatiates on...

Coding Improvements

As my article, Computer Chips Demystified states,

"In a computer, the complicated is reduced to the very simple & repeated billions of times over!"
-- Everett George

Computer Ethics - An Example

Gerrymandering - "the political manipulation of electoral district boundaries with the intent to create undue advantage for a party."
-- Wikipedia.org
If the ideas are simple, programmers can tell a computer what to rapidly think about in a near infinite loop:
  • consider a billion ways to redraw a state's districts for US House of Representative reapportionment.
  • assess each redraw to "optimize" a party's win through evaluation of voters.
  • report the "best" redraws to the coder after overnight number-crunching.

A computer's "chip power" can "rig" a 230-year-old system so a politician almost never loses an election! What damage can a nerd who codes do to a democracy? Alot!

"Neutron Bombs & Mustard Gas … Just because you can doesn't mean you should!" The key is feedback. If a computer solution is realized to be detrimental, the implementors should recognize that & seek other solutions.

A programmer documents code for maintenance by posterity. A "happy medium" exist between too much & too few comments in code. However comments are important:

"Programs must be written for people to read and only incidentally for machines to execute."
-- Hal Abelson

These ideas are still being developed. However, I will try to outline how to write code that instructs best, in my opinion.

JavaScript Apps: The following applets are written in JavaScript, the programming language designed for web browsers. I developed the applets to support my knowledge cards:

Lorentz Force Equation eduLForce.pdfEE/Phy
Newton’s Laws of Motion eduNewton.pdfME/Phy

My code has drawn from oPhysics models. However, my applets use only html / css / JavaScript W3C code. The html pages will probably work on a browser for many decades. I took a course in Flash years ago, all the bells & whistles of embedded graphics until hackers made it unsafe & obsolete.

Of the many designs, only a few programming languages have seen heavy applications. Below is listed the timeline & knowledge flow of JavaScript that runs on many web browsers. Several listed computer languages are still in use. Notice the incremental advances made with each language.

  • source file 🡆 compiler 🡆 computer specific executable
  • FORTRAN was created by IBM
  • abbreviation for FORmula TRANslation
  • 1969: put the US on the Moon
  • used in high-performance computers for STEM
  • current: Fortran 2023 is from ISO/IEC 1539-1
  • source file 🡆 compiler 🡆 computer specific executable
  • SmallTalk was created by Xerox
  • uses OOP (Object Oriented Programming)
  • coding uses defined objects that interact
  • current: SmallTalk 1998 has limited use
  • source file 🡆 compiler 🡆 computer specific executable
  • C++ was created by Bjarne Stroustrup
  • much direct memory control (inherited from C)
  • extension of C programming language
  • "class" keyword is subset of "struct"
  • current: C++20 is ISO/IEC 14882
-- Wikipedia.org

JavaScript Modeling w/Numerical Analysis

My idea came from the sliding block app @ oPhysics.com. Educators would embed JavaScript Apps in their teaching tools. The JavaScript code would be well documented using Doxygen (free) with technical references. Just as important, the js source code becomes a teaching tool just as the applet. For file data, all of the style parameters would be in a css file, all of the javascript in a js file w/Doxygen comments.

Numerical Analysis code would duplicate that of GeoGebra.org. Mini-library classes would be utilized for these apps: Runge-Kutta, Transformation Matrices & 2D vectors.

API documentation of the classes would be ZIP file assessible for student exposure & use. Unfortunately, Doxygen does not specifically support JavaScript. A 3rd party script would be developed for JavaScript support.

In the future, web browsers will access the Ubiquitous Web via laptops, tablets, smart phones ... practically any electronic device. Most browsers have JavaScript engines. In time, the best applications of Jupyter & other software should be incorporated into a JavaScript / STEM package. My JavaScript proposal brings Numerical Analysis to browsers. This addition should give free & greater access of these tools to the public.

In my opinion, my coding proposal is a step into the inevitable destiny of JavaScript & Numerical Analysis pairing. Let's get started!

Preliminary

Sliding Block on an Inclined Plane
Sorry, your browser does not support canvas.

Preliminary

Dipole Electrostatic Field Lines
Sorry, your browser does not support canvas.
   
0 nm    5 nm 10 nm

Preliminary

Solenoid Magnetostatic Field Lines
Sorry, your browser does not support canvas.
 
0 cm    5 cm 10 cm

The Calculation Library of Templates (CalcLib) Applications Programming Interface (API) is a collection of mathematical calculation classes & class templates.

These templates can be used with other source code to solve problems in numerical analysis. Numerical analyses include differentiation, integration, differential equation approximations, matrix algebra, regression analyses & curve-fits.

The classes are written in the C++ programming language. The files carry the Lesser GNU License, which allows for derived software sales.

For most CalcLib classes, documented examples are included. The source code is supported through an API specific Doxygen annotated C++ source format. Select examples use test scenarios & demonstrate:

Calc::Cheb Chebyshev curve-fit implementing calculus.
Calc::Intg definite integral of test function.
Calc::Mtx least squares polynomial of test data.
Calc::Ode 3-axis Runge-Kutta (full C++: odeSRel.zip).

The documentation at the following links provide Version 1 data for the CalcLib API. This download of the CalcLib ZIP file with software is dated 07/19/2006.

CalcLib.html  Documentation (existing)
CalcLib.zipTemplate Files (07/19/2006)

The documentation at the following link provides Version 2 (proposed) data for the CalcLib API.

CalcLib.html     Documentation (proposed)

The improvements would implement the following:

  • Incorporate std::complex template class in examples.
  • Incorporate 3-Axis Runge-Kutta of Special Relativity in the calc::Ode example using a variable mass rocket.
  • Incorporate contour integration in the calc::NIntg example to prove calculus of residues. Consider sin(1/z)/(z²+a²) with poles @ z=0,ia,-ia. (ref: Arfken)
  • Remove calc::OptIntp interpolator optimization class.
  • Rename calc::Base class to calc::Calc.
  • Add calc::Rombo and calc::Carpo to calc::Ode incorporating the Romberg method of extrapolating to zero.
  • Collapse inherited classes of calc::NIntp into the parent calc::NIntp class through a call back function using calc::Intp offspring.
  • Collapse inherited classes of calc::Cheb into the parent calc::Cheb class.
  • Put the inherited classes of calc::Intp under an intermediate calc::Data class. Place calc::Cheb & calc::Data under a calc::Intp parent class.
  • Allow calc::Intg to accept yType dependent arrays along with functions.

Note: For external software accessed on this webpage:
$20/yr - Doxygen code documentation maker.
$50/yr - GNU Licenses for free software.
$25/yr - W3 Consortium character standards.
$70/yr - Wikipedia online encyclopedia.
Please make a modest donation if you find any above software useful. (full list @ lstFreeware.pdf)