Friday, 23 May 2014

Phil Daintree and kwamoja.org

This page is written in response to the lies that +Phil Daintree  has written about me, and spread on the internet. Despite years of searching he has been unable to find anything I have written that is untrue, and he has had to resort to vague generalities, faked emails, and badly fabricated screenshots (you can see the joins if you zoom in using any bit mapped image editor). +Phil Daintree is welcome to make any comments to these pages, as he has done in the past. If I agree with what he says I will amend my writings, if I do not agree I have allowed his comments to stand next to mine so that people can make their own judgements. I have every confidence in the intelligence of readers to make a sensible judgement based on the facts. +Phil Daintree will not allow me the right of reply to any of the lies he has told about me. It seems to me significant that he realises that if people see both sides of the argument they will see through his lies.

Ever since +Phil Daintree  fell out with me over keeping a history of purchase orders on the system I have grown used to the torrent of lies and abuse he has thrown at me, in an attempt to stop me developing webERP and KwaMoja. I have a thick skin, and anybody who knows me can see through his lies easily enough, so it hasn't unduly bothered me. He is after all well known for his lies and his bullying behaviour.

However his constant attacks on my African colleagues and our African projects do annoy me. His hijacking of the kwamoja.org domain name in order to push his personal vendetta is typical of him. I was not even involved in the project when he purchased the domain. The full details of this pathetic saga can be read in a post by Martha here.

He has told my African colleagues on the project he does not believe they are real Africans as the work is too good for them to have done it. I have offered Phil their phone numbers so he can tell them in person that they don't exist, but curiously enough he doesn't want to do this!

Persuading African friends to work on open source projects has been a struggle, as I have documented elsewhere. When they do help on open source they shouldn't have to face attacks from people such as +Phil Daintree 

When he first tried to ban me from the webERP project I set up a separate webERP repository so that I could continue to make my code available to others as the license requires. +Phil Daintree launched numerous public attacks on me for this, and said I should call my branch something else. When I then started committing code to the KwaMoja repository he launched numerous public attacks on me for donating code to a "rival project". There is no such thing as rival projects in the open source world, all projects can take code from each other. Open source is about collaboration not rivalry. So Phil is basically going to attack me whatever I do. That is fine as I have said, but I would ask him to leave off our African projects and my African colleagues.

Tuesday, 6 May 2014

Looking for KwaMoja consultants in the Arusha area

I have the need to recruit several ERP consultants in the Arusha area. This will entail working closely with a Christian faith based organisation and applicants need to be sensitive to that.

Preferably some or all of the following would be nice:
1 An understanding and experience with ERP systems.
2 A Knowledge of bookkeeping and accountancy
3 Some knowledge of programming PHP/mysql
4 A desire to learn and to work hard to create a career in the ERP industry

If you feel you would qualify and are interested in working in the Arusha area then please send your resume/CV to tim@weberpafrica.com with the words KwaMoja Consultant in the subject line of the email.

Tim

Sunday, 20 April 2014

Filing a bug report in KwaMoja

It appears from above that the administrator of webERP is shutting the project to new contributors, so it seems like a good time to run a series of articles on how to contribute to KwaMoja. Here is the first in that series:

image02Many people are nervous about reporting problems with open source projects. They fear that the developers will see it as a criticism. However all developers know that there is no such thing as "bug free" software. Any help they can get in tracking down and fixing these bugs is always appreciated.
KwaMoja uses a system called the bug genie to track any bugs in the software. We thought it waould be useful to write this short guide to filing bugs in KwaMoja using the bug genie.
Ok, so let's imagine that we have found a problem that we think may be a bug in the General Ledger Journal functionality (this will be an imaginary bug, I am not aware of any at the moment). The first thing we will need to do is to create an account for ourselves on the bug tracker. This is necessary firstly as it prevents spammers, secondly it enables you to track your bug, and for the developers to discuss the issue with you, enabling a dialog between you. Click here to enter the bug reporting section. You should see something like this:
If you already have a login, or you want to use one of the openid methods then
you can login from here. If you wish to create a new account then click on the tab marked "Register new account". You should now see a screen looking something like the one on the left.
image02Filling out this information and submitting it should give you a new randomised password. You should now login with the user and password combination that you have. You should consider changing the password at this point to one that you will remember.
You should now be taken to your dashboard page, giving you a summary of all your activity on bug genie. Obviously at the moment there won't be much on it!! If you are not taken to your dashboard, then click on your name in the top right hand corner and you should be taken there.
You should now see a menu bar at the top of the window looking like the picture
on the right. To enter a bug report select the "Bug Report" option and you will be taken to the main bug reporting screen. This has been kept deliberately simple. There are just three sections that you need to fill in.
  • Short Description
  • Description
  • Reproduction Steps
The short description should be brief but sufficient so that a developer browsing a list can quickly identify what it is about. Compare "KwaMoja doesn't work properly" with "General Ledger Journal gives the wrong total amount". Clearly the second is going to be easier for a developer to immediately understand the issue being reported.
The main description should contain as much information as you can about the issue being reported. You should include what version of KwaMoja you are using, what operating system and version you are using, a description of your server, and what browser you are using to view KwaMoja. Include any further information that you feel may be of use to the developers.
Finally there is the steps to reproduce the issue. Make sure you put everything no matter how obvious it may seem to you. Also include the results of what happens for each step.
Once you have submitted the report you should keep an eye out for feedback from the developer. It is likely you will get asked for more info, or be given a fix to test. Please reply to this feedback to help improve KwaMoja.

Tuesday, 15 April 2014

Med-e-Tel in Luxembourg

Thanks to the sponsorship of Advanz of Luxembourg we had a great time at Med-e-Tel 2014.
The major aim of our presence was to promote the use of our open source solutions in developing countries. It was great to see other open source health systems present as well to help promote the concept of open source in hospitals.

There was  stand devoted to open source solutions, which was very well attended all week.

We had a lot of interest all week from all corners of the globe. We presented a paper on an implementation of Care2x in a large tertiary hospital. You can read the full paper here.


The presentation was part of the open source in health care session of the conference, and was very well attended with much interest in the various open source solutions for health care being presented.

I came away from the conference with the belief that we are on the right track with our solutions, and that open source really is the future for ICT in health care.

I have come away with renewed vigour to push forward with Project Mtuha and KwaMoja/Care2x solutions, despite the attempts by some to wreck the projects.

Again, much thanks to Advanz for their sponsorship and support without which our presence at the conference would not have been possible.

Friday, 21 March 2014

Some properties of Automorphic numbers

This post is a complete change from my usual subjects.

Many years ago a man named Mike Mudge wrote a monthly column for Personal Computer World called "Numbers Count". There seems to be very little about him on the web, except for other fans like me. One such column inspired the following paper written jointly by my father[1] and I.

This work has just come to light during a recent house move that caused me to search through old papers, and despite it being 20 years ago, a quick search of the web shows that it still contains some original stuff, so I thought it would be interesting to publish it here. I am publishing it here unaltered, though obviously computing power has improved a lot over the years. I have tried to reproduce it exactly, but I may have made some transcribing errors, and if you see any please let me know.

Nb 20 years ago this work was unique to the best of our knowledge, but I can't promise that is still so.

Some properties of Automorphic numbers

Abstract: 

An automorphic number is is a number whose square ends in the same digits as number itself. Automorphic numbers form two series ending respectively in the digits 5 and 6. Successive members of each series have the same sequence of trailing digits and are formed simply by appending a new leading digit to their predecessor. Corresponding numbers in the two series bear a simple numerical relation to one another and are co-prime. Consequently, the sequence of one series uniquely determines the sequence of the other series. Some properties of automorphic numbers are discussed and these properties used to develop rapid and efficient methods for the generation of automorphic numbers. One such method generates numbers of up to 32,000 digits in length in a run time of 75 minutes[2]. n-Automorphic numbers to bases other than 10 are briefly discussed.

Introduction:

The computer generation of automorphic numbers using a simple trial and error process soon indicates that there are only three n-digit automorphic numbers for any value of n. One of these consists of the digit 1 with a string of leading zeros and may be regarded as trivial. In the case of the other two, it is found that with the exception of the leading digit, each n-digit automorphic number is identical with the corresponding n-1-digit number, and it is therefore only necessary to determine the leading digit for any n-digit  automorphic number. The following describes some properties of automorphic numbers and which lead to more efficient methods for their generation.

Methods

The generation of automorphic numbers was carried out with a Packard-Bell 445 elite 486Ssx running at 33mHz using programmes implemented in turbo pascal.

Results

Theorem 1 : 
For any value of n, there exists only two n-digit automorphic numbers and these end in the digits 5 or 6.
Proof: Let n= 10a+b represent a two digit number. If n is automorphic then 
 n^2=100a^2+20ab+b^2=1000z+100y+10a+b   .............................  (1)
and b^2=b+10x
where x is an integer. Only b=5 or b=6 satisfy this condition and therefore all 2 digit automorphic numbers must end in 5 or 6.

Substituting b=5 in equation (1) above gives
100a^2+90a=1000z+100y-20
90a must end in the digits 80 and therefore a=2 and n=25.
Substituting b=6 in equation (1) above gives
100a^2+110a=1000z+100y-30
110a must end in the digits 70 and therefore a=7 and n=76.

Let n=100a+10b+c represent a 3 digit number. If n is automorphic then 
n^2=10^4*a^2+2ab*10^3+b^2*10^2+2ac*10^2+20bc+c^2=10^5z+10^4y+10^3x+100a+10b+c ........ (2)
and c^2=c+10j where j is an integer, therefore the digit c must be either 5 or 6.
Substituting c=5 in equation (2) gives us 
10^4*a^2+2ab*10^3+b^2*10^2+10^3a+10^2b+25=10^5*z+10^4*y+10^3*x+100a+10b+5 ...... (3)
and 90b must end in the digits 80, therefore b must have the value 2.
By the same procedure substituting b=2 into equation (3) gives the value a=6. Substitution of c=6 in equation (2) and repetition of the same procedure gives values of 7 and 3 for b and a respectively.
Therefore to digit automorphic numbers can only be 25 and 76, and 3 digit automorphic numbers can only be 625 and 376.

Conjecture A

If p and q are any pair of n-digit automorphic numbers then p+q=10^n+1

Conjecture B

If p and q are any pair of n-digit automorphic numbers then p and q are co-prime.

Theorem 2

If p is an n-digit automorphic number and q=p-1 then pq=100s where s is an integer.
Proof: Let pq=1000a+100b+10c +d and p^2=1000f+100g+p
Then p^2-pq=1000f+100g+p-1000a-100b-10c-e=p
1000f+100g=1000a+100b+10c+e
Therefore c and d must be zero, and a=f, b=g, and pq=100s where s is an integer.

Theorem 3

If p is an n-digit automorphic number and 10^nA+p is the corresponding n+1-digit automorphic number, then A(2p-1)+x=k*10^n-1 where k is an integer and 100x=p^2-p
Proof: Let p=10a+b. If p is automorphic then 
p^2=1000l+100m+10a+b=100(10l+m)+p
Let x=10l+m then p^2=100x+p and 100x=p^2-p
Let the 3 digit number be 100A+p, then if this number is automorphic
10^4A^2+200pA+p^2=10^5*z+10^4*y+10^3*x+100A+p and 200pA-100A=p-p^2+1000k
Therefore A(2p-1)+x=10k
By the same procedure it can be shown that for the 4-digit number 1000B+100A+10a+b the leading digit B is given by the expression
B(2p-1)+j=k*10^2 where p=100A+10a+b, j*10^3=p^2-p, and k is an integer.

Theorem 4

If k is the square of an n-digit automorphic number j ending with the digit 6, then the le4ading digit in the corresponding (n+1)-digit automorphic number is 10-m where m is the coefficient of 10^n in k. For the corresponding n-digit number ending with the digit 5, the leading digit in the corresponding (n+1)-digit number is m where m is the coefficient of 10^n.
Proof: Let p=10a+b where p is a 2-digit automorphic number, then p^2=1000l+100m+10a+b
Let the corresponding 3-digit automorphic number 100A+p
From Theorem 3 above we know
A(2p-1)+10l+m=10k where k is an integer
Substituting p=76 we get 151A+10l+m=10k and A*l+m=10
Therefore A=10-m
Substituting p=25 we get 49A+10l+m=10k and A*9+m=10k
Therefore A=m

Theorem 5

For any value of n there exists only three-n-digit tri-automorphic numbers and these end in the digits 2, 5 or 7.
Proof: Let n=10a+b then 3n^2=300a^2+60ab+3b^2
If n is tri-automorphic then:
300a^2+60ab+3b^2=1000z+100y+10a+b  ..................  (4)
and 3b^2-b=10x   ............................  (5)
where x is an integer. This condition is only satisfied by b=2, b=5, or b=7
Substituting b=2 in equation (4), it follows that a=9
Substituting b=5 in equation (4), it follows that a=7
Substituting b=7 in equation (4), it follows that a=6
Corollary: 
For di-automorphic numbers, equation (5) becomes
2b^2-b=10x and b=8
For tetra-automorphic numbers, equation (5) becomes
4b^2-b=10x and b=4
For penta-automorphic numbers, equation (5) becomes
5b^2-b=10x and b=5

Discussion

Initial computer studies were carried out by testing numbers in sequence for automorphic character. The programme listing is shown in Appendix 1 [3]. As might be expected run times were very long and only 16 automorphic numbers were generated in a run time of 3 hours [4]. These studies did however demonstrate two important properties of automorphic numbers.
1. Only two n-digit automorphic numbers exist for each value of n
2. Such numbers form two series in which successive members differ from their predecessors only in the leading digit.

The first 8 members are shown for example below
Series 1525625062590625890625289062512890625
Series 2676376937609376109376710937687109376
Total11101100110001100001100000110000001100000001
In order to convert an n-digit automorphic number into the corresponding (n+1)-digit automorphic number it is necessary only to test the digits 0 to 9 for suitability as the leading digit of the next number. This obviously facilitates the computer generation of automorphic numbers. Furthermore it appears from the above table that the sum of a pair of n-digit automorphic numbers is equal to 10^n+1 (see Conjecture A above), and therefore a sequence of automorphic numbers is uniquely determined by the corresponding pairing sequence.
Theorem 3 allows the calculation of the leading digit of the next automorphic number in the series. If for example p=625 then A*1249+390=10k implies A=0 giving 0625 as the next automorphic number in the sequence. If p=0625 then A*1249+39=10k gives A=9 making the next automorphic number in the sequence 90625.
Theorem 4 provides a simple alternative method for the calculation of the next leading digit in automorphic numbers terminating in the digit 6. If p=376 then p^2=141376 and m, the coefficient of 10^3 is equal to 1. Therefore A=10-1=9 giving 9376 as the 4 digit number.If p=9376 then p^2=87909376 and m the coefficient of 10^4 is equal to zero. Therefore A=10-0=10 giving 09376 as the 5-digit number. If p=625 then p^2=390625 and m, the coefficient of 10^3 is equal to zero giving 0625 as the 4-digit number.The same procedure gives 90625 as the 5-digit number in the sequence.

The programme listing for this procedure is shown in Appendix 2 [5]. Using this procedure, the series of automorphic numbers up to 20,000 digits in length was generated in a run time of 54 minutes. Repetition of the procedure using an AST 486DX running at 50Mhz generated automorphic numbers of up to 32,000 digits in length in a run time of 75 minutes. As a point of interest it may be noted that the leading ten digits and the trailing ten digits of the two 32,000-digit automorphic numbers are as follows:
6351634399..............................................................................8212890625
3648365600..............................................................................1787109376


Appendix 3 lists all the n-automorphic numbers to base b where b=2 to 10 and n=1 to b-1 [6]. The following points may be noted:
1. No base 2 automorphic numbers are apparent.
2. It is conjectured that an (n+1)-automorphic number to the base (n+2) is of the form:
.......nnn(n+1). For the cases n=5, b=6 and n=9, b=10 there are two accompanying numbers while single numbers only occur for all the other cases.

[1] http://www.google.com/patents/US4877732

      http://www.google.com/patents/US3636037
      http://www.google.com/patents/US4249015
      http://www.google.com/patents/US3701779
      and others................... 
[2] Note the timings given in this paper were from the initial work carried out approximately 20 years ago, and obviously would be very different if repeated these days.
[3] Unfortunately this appendix has been lost, if I find it I will add it here later for the sake of completeness.
[4] I have just run a very simple python script and using a brute force method it generated the first 16 in 128.222 seconds!
[5] Again this programme listing was not found, sparing people from seeing my lack of coding skills from 20 years ago!!
[6] The loss of this appendix is a great shame as this gives some interesting information. I will try to recreate this data at some time.

Thursday, 6 February 2014

KwaMoja version 14.02 is released

 KwaMoja version 14.02


This is a brand new version of KwaMoja with many additional features, and many enhancements from webERP.

There is a completely rewritten installer giving an option of 27 different charts of account donated by contributors from around the world. Users have the choice to upload some demo data, or to go through the entire hand holding procedure to set up a new blank company.

Internal stock requests can now be edited or cancelled on a per line or per request basis.

When making a payment to suppliers, the invoices can be chosen from within the payments screen, and all allocations are performed automatically.

Inventory can now be analysed on an ABC basis, to identify fast/slow moving items. This analysis can be done using different bases, and multiple analyses kept.

KwaMoja has a dashboard that enables multiple views of the status of orders/inventory/banks etc. to be shown on one screen. This is configurable on a per user basis.

There is a new and more intuitive user interface for those using it for whom English is not the first language.

Shipments can now be entered with a start date before today's date thus enabling a more sensible ETA date to be entered.

The code has been simplified and smartened up in line with the coding guidelines.

Numerous bug fixes have been applied.

Form as are now verified at client side, and better error dialogs are shown.

The full change log can be viewed here: https://github.com/timschofield/KwaMoja/blob/release_1402/doc/Change.log

The state of resource planning in African Industry

A proper history of ERP would be beyond the scope of this article so what below is a radical précis of the facts, simplifying occasionally for the sake of brevity.

In the nineteen seventies a new approach to manufacturing systems started to spread outwards from Japan. Generally credited as starting at Toyota where it had evolved over a period of years. This approach had several names JIT (Just In Time), stockless production, and Material requirements planning (MRP).

What was happening was that the capabilities of computers was being utilised to plan the resources being used in manufacturing to dramatically reduce the cost of holding and handling these resources. It became possible to plan exactly what resources were going to be needed and when. Then correct management of the supply chain meant that these resources could be in the right place at exactly the right time. Better planning and efficient use of resources produced better quality finished goods.

This revolutionary approach began to move through western businesses during the eighties with such companies as Hewlett Packard leading the way. Through the eighties and into the nineties most western companies adopted at least some of this new manufacturing philosophy, the most successful at implementing this became the most competitive, and survived the recessions of those years.

Computer software to help this approach was developed, at first in house, and then by ISV's. This was called MRP, then MRP II also CRP (Capacity Requirements Planning) eventually evolving into one integrated solution ERP (Enterprise Resource Planning).

Like most new market places there was an initial explosion in the eighties of many vendors supplying this software, followed up as the market matured in the nineties by a consolidation into a small number of vendors.

Then came the open source revolution of the new century, when there was again an explosion of new products onto the market place.

So, first Asian businesses, then American and European businesses adopted this new philosophy their products became highly competitive in the world market. Where did this leave Africa?

I first began to get involved with African businesses in the second half of the last decade and was horrified at just how few companies had adopted this approach to manufacturing. Too often the approach was "Labour is cheap, if we have a problem we throw more cheap labour at it". This approach comes with many problems. Most obviously quality falls when you employ cheap temporary labour, but there is also the social aspect of this. The small amount of planning that seemed to be done was done by hand or spreadsheet. The resource planning revolution had not reached Africa.

Poor control of resources also meant that businesses were losing a great amount of stock through theft. This had a double affect on the business, there was the loss of money that had to be used to replenish the stock, but also the failure to meet customer orders was costing them dearly.

This meant that African goods just couldn't compete with western companies that used sophisticated tools to keep quality high, and costs low.

It would be nice to say that African business owners took to ERP very quickly, but as it was in the early days in the west it was a struggle, but more and more businesses are now seeing the benefits of good planning.

The only software that has been available to African businesses has been produced in the west. This was one of our motivations in producing KwaMoja. We wanted to produce some thing that would benefit African businesses, and something that was produced in Africa, and something that African consultants can sell services around.

We are happy to announce that a new version of KwaMoja is ready and hitting the mirrors already. This is version 14.02 and you can download this version from here.