/[drupal]/contributions/modules/carbon/carbon_calculate.inc
ViewVC logotype

Log of /contributions/modules/carbon/carbon_calculate.inc

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Links to HEAD: (view) (download) (as text) (annotate)
Sticky Tag:

Revision 1.43 - (view) (download) (as text) (annotate) - [select for diffs]
Sun Jul 5 10:47:40 2009 UTC (4 months, 3 weeks ago) by johnackers
Branch: MAIN
CVS Tags: HEAD
Changes since 1.42: +32 -45 lines
Diff to previous 1.42
bug fix for sharing/adjustment changes in the middle of accounting period

Revision 1.42 - (view) (download) (as text) (annotate) - [select for diffs]
Fri Jul 3 12:21:29 2009 UTC (4 months, 3 weeks ago) by johnackers
Branch: MAIN
Changes since 1.41: +93 -30 lines
Diff to previous 1.41
Create estimated readings even if required before all or after all available meter readings.  For example, we calculate emissions from Jan 1 even if 1st meter reading was taken on Jan 20th. This is the way the old algorithm worked.

Revision 1.41 - (view) (download) (as text) (annotate) - [select for diffs]
Sat May 9 15:24:02 2009 UTC (6 months, 2 weeks ago) by johnackers
Branch: MAIN
CVS Tags: DRUPAL-6--1-0
Changes since 1.40: +98 -104 lines
Diff to previous 1.40
changed meter algorithm to create estimated meter readings at the start and end of the accounting periods. This alogorithm ensures that over several years, as long as you have some real meter readings on the start/end dates, the overall CO2 / energy calculations are precise; not true about old algorithm.

Revision 1.40 - (view) (download) (as text) (annotate) - [select for diffs]
Tue May 5 13:24:18 2009 UTC (6 months, 3 weeks ago) by johnackers
Branch: MAIN
Changes since 1.39: +6 -6 lines
Diff to previous 1.39
enhanced handling of energy fields

Revision 1.39 - (view) (download) (as text) (annotate) - [select for diffs]
Tue May 5 09:18:40 2009 UTC (6 months, 3 weeks ago) by johnackers
Branch: MAIN
Changes since 1.38: +2 -5 lines
Diff to previous 1.38
remove title

Revision 1.38 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Apr 29 21:00:31 2009 UTC (6 months, 4 weeks ago) by johnackers
Branch: MAIN
Changes since 1.37: +13 -14 lines
Diff to previous 1.37
show meter reading errors, fix problems with start and end dates

Revision 1.37 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Apr 28 17:08:12 2009 UTC (6 months, 4 weeks ago) by johnackers
Branch: MAIN
Changes since 1.36: +5 -5 lines
Diff to previous 1.36
more careful handling of dates

Revision 1.36 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Apr 28 14:44:34 2009 UTC (6 months, 4 weeks ago) by johnackers
Branch: MAIN
Changes since 1.35: +4 -4 lines
Diff to previous 1.35
change default period for repeating stamps to annual.

Revision 1.35 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Apr 28 11:06:41 2009 UTC (6 months, 4 weeks ago) by johnackers
Branch: MAIN
Changes since 1.34: +12 -12 lines
Diff to previous 1.34
make date handling consistent and use format specified by drupal admin

Revision 1.34 - (view) (download) (as text) (annotate) - [select for diffs]
Mon Apr 27 08:19:17 2009 UTC (7 months ago) by johnackers
Branch: MAIN
Changes since 1.33: +8 -8 lines
Diff to previous 1.33
correctly set start of year to Jan 1.

Revision 1.33 - (view) (download) (as text) (annotate) - [select for diffs]
Sun Apr 26 10:59:37 2009 UTC (7 months ago) by johnackers
Branch: MAIN
Changes since 1.32: +16 -4 lines
Diff to previous 1.32
wrap error messages with t() when carbon source not or no longer present

Revision 1.32 - (view) (download) (as text) (annotate) - [select for diffs]
Fri Apr 24 11:06:39 2009 UTC (7 months ago) by johnackers
Branch: MAIN
Changes since 1.31: +2 -2 lines
Diff to previous 1.31
fix bug with _format_float()

Revision 1.31 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Apr 21 18:45:16 2009 UTC (7 months ago) by johnackers
Branch: MAIN
Changes since 1.30: +23 -8 lines
Diff to previous 1.30
print numbers with 2 significant digits

Revision 1.30 - (view) (download) (as text) (annotate) - [select for diffs]
Mon Apr 20 22:35:20 2009 UTC (7 months, 1 week ago) by johnackers
Branch: MAIN
Changes since 1.29: +2 -19 lines
Diff to previous 1.29
restore _class_map

Revision 1.29 - (view) (download) (as text) (annotate) - [select for diffs]
Mon Apr 20 14:28:24 2009 UTC (7 months, 1 week ago) by johnackers
Branch: MAIN
Changes since 1.28: +60 -71 lines
Diff to previous 1.28
row editing using ajax and related changes

Revision 1.28 - (view) (download) (as text) (annotate) - [select for diffs]
Mon Mar 23 15:06:34 2009 UTC (8 months ago) by johnackers
Branch: MAIN
Changes since 1.27: +71 -38 lines
Diff to previous 1.27
using old variable $results,  C02 etc not displayed.

Revision 1.27 - (view) (download) (as text) (annotate) - [select for diffs]
Sat Jan 10 15:46:14 2009 UTC (10 months, 2 weeks ago) by johnackers
Branch: MAIN
Changes since 1.26: +2 -3 lines
Diff to previous 1.26
first pass at drupal-6 version. gui also in transition.

Revision 1.26 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Jan 6 22:19:26 2009 UTC (10 months, 2 weeks ago) by johnackers
Branch: MAIN
CVS Tags: DRUPAL-5--0-2
Changes since 1.25: +20 -20 lines
Diff to previous 1.25
Replaced calls to drupal's format_date() with direct calls to date() routine that uses the same timezone as other php routines like strtotime().

Revision 1.25 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Jan 6 17:36:30 2009 UTC (10 months, 2 weeks ago) by johnackers
Branch: MAIN
Changes since 1.24: +538 -526 lines
Diff to previous 1.24
removed the tabs that crept in there, other minor changes

Revision 1.24 - (view) (download) (as text) (annotate) - [select for diffs]
Mon Jan 5 13:12:27 2009 UTC (10 months, 3 weeks ago) by johnackers
Branch: MAIN
Changes since 1.23: +107 -62 lines
Diff to previous 1.23
calculate emissions between all meter readings so that 'adjustments' can have effect in the middle of the accounting period (e.g. number of people sharing house change) .

Revision 1.23 - (view) (download) (as text) (annotate) - [select for diffs]
Sun Jan 4 18:37:43 2009 UTC (10 months, 3 weeks ago) by johnackers
Branch: MAIN
Changes since 1.22: +41 -33 lines
Diff to previous 1.22
Allow the 'adjustment' to be changed on each carbon stamp in a sequence.

Revision 1.22 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Jul 2 13:37:36 2008 UTC (16 months, 3 weeks ago) by johnackers
Branch: MAIN
Changes since 1.21: +4 -4 lines
Diff to previous 1.21
work in progress

Revision 1.21 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Jul 2 12:53:08 2008 UTC (16 months, 3 weeks ago) by johnackers
Branch: MAIN
Changes since 1.20: +305 -200 lines
Diff to previous 1.20
branch DRUPAL-5 merged in

Revision 1.20.2.5 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Feb 19 09:23:57 2008 UTC (21 months, 1 week ago) by johnackers
Branch: DRUPAL-5
Changes since 1.20.2.4: +263 -184 lines
Diff to previous 1.20.2.4 , to branch point 1.20 , to next main 1.43
carbon purchases, transfers added. Report, calculation functions cleaned up.

Revision 1.20.2.4 - (view) (download) (as text) (annotate) - [select for diffs]
Thu Jun 14 17:51:22 2007 UTC (2 years, 5 months ago) by johnackers
Branch: DRUPAL-5
Changes since 1.20.2.3: +5 -8 lines
Diff to previous 1.20.2.3 , to branch point 1.20
links improved, protection granularity sharpened. Other cosmetic changes.

Revision 1.20.2.3 - (view) (download) (as text) (annotate) - [select for diffs]
Mon Jun 11 10:11:44 2007 UTC (2 years, 5 months ago) by johnackers
Branch: DRUPAL-5
Changes since 1.20.2.2: +56 -29 lines
Diff to previous 1.20.2.2 , to branch point 1.20
In results include carbon stamps that have 0 kg (e.g. for a green energy tariff) or have a carbon source code that is no longer valid or not published. Think bug 125961 is slightly different.

Revision 1.20.2.2 - (view) (download) (as text) (annotate) - [select for diffs]
Thu May 10 22:03:43 2007 UTC (2 years, 6 months ago) by johnackers
Branch: DRUPAL-5
Changes since 1.20.2.1: +4 -2 lines
Diff to previous 1.20.2.1 , to branch point 1.20
don't show model in tables

Revision 1.20.2.1 - (view) (download) (as text) (annotate) - [select for diffs]
Thu May 3 09:43:57 2007 UTC (2 years, 6 months ago) by johnackers
Branch: DRUPAL-5
Changes since 1.20: +2 -2 lines
Diff to previous 1.20
Tweaks. Help users install carbon sources if none present. Generate h1 tags if  footprint or source tables have zero rows to avoid format problem with bluebreeze.

Revision 1.19.2.1 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Mar 21 10:20:53 2007 UTC (2 years, 8 months ago) by johnackers
Branch: DRUPAL-4-7
Changes since 1.19: +10 -1 lines
Diff to previous 1.19 , to next main 1.43
add fn carbon_calculate_empty_table

Revision 1.20 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Mar 20 19:25:38 2007 UTC (2 years, 8 months ago) by johnackers
Branch: MAIN
CVS Tags: DRUPAL-5--0-1
Branch point for: DRUPAL-5
Changes since 1.19: +10 -1 lines
Diff to previous 1.19
second version of drupal 5 port

Revision 1.19 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Mar 7 14:03:59 2007 UTC (2 years, 8 months ago) by johnackers
Branch: MAIN
CVS Tags: DRUPAL-4-7--0-7
Branch point for: DRUPAL-4-7
Changes since 1.18: +38 -19 lines
Diff to previous 1.18
added second KwH column to carbon footprints, involves schema changes, database update required, see request http://drupal.org/node/122830

Revision 1.18 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Mar 7 11:41:24 2007 UTC (2 years, 8 months ago) by johnackers
Branch: MAIN
Changes since 1.17: +36 -28 lines
Diff to previous 1.17
display kwh column only when enabled in carbon footprint

Revision 1.17 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Mar 6 23:59:21 2007 UTC (2 years, 8 months ago) by johnackers
Branch: MAIN
Changes since 1.16: +3 -3 lines
Diff to previous 1.16
ignore start date on carbon_stamps if user sets it to be the same as the end date.

Revision 1.16 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Mar 6 21:44:22 2007 UTC (2 years, 8 months ago) by johnackers
Branch: MAIN
Changes since 1.15: +113 -44 lines
Diff to previous 1.15
Fix assorted bugs in the calcalution of emissions from all types of carbon_stamps including inabaility to handle meter readings that fall on the start of a reporting period, and emissions from repeating stamps not calculated correctly.

Revision 1.15 - (view) (download) (as text) (annotate) - [select for diffs]
Sun Mar 4 18:58:43 2007 UTC (2 years, 8 months ago) by johnackers
Branch: MAIN
Changes since 1.14: +25 -25 lines
Diff to previous 1.14
fix bug that caused carbon emissions to be incorrectly apportioned whenever a start date is set

Revision 1.14 - (view) (download) (as text) (annotate) - [select for diffs]
Sun Feb 25 23:33:12 2007 UTC (2 years, 9 months ago) by johnackers
Branch: MAIN
Changes since 1.13: +4 -3 lines
Diff to previous 1.13
Don't print double same dates on carbon footprint node.

Revision 1.13 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Feb 14 14:47:50 2007 UTC (2 years, 9 months ago) by johnackers
Branch: MAIN
Changes since 1.12: +38 -14 lines
Diff to previous 1.12
reformat display of footprint calculations

Revision 1.12 - (view) (download) (as text) (annotate) - [select for diffs]
Thu Feb 1 12:41:38 2007 UTC (2 years, 9 months ago) by johnackers
Branch: MAIN
CVS Tags: DRUPAL-4-7--0-6
Changes since 1.11: +2 -2 lines
Diff to previous 1.11
Display KwH field as integer, no decimal part.

Revision 1.11 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Jan 31 15:53:06 2007 UTC (2 years, 9 months ago) by johnackers
Branch: MAIN
Changes since 1.10: +13 -10 lines
Diff to previous 1.10
suppress KwH values if not enabled in preferences (and most likely right now) they are going to be wrong.

Revision 1.10 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Jan 31 15:14:17 2007 UTC (2 years, 9 months ago) by johnackers
Branch: MAIN
Changes since 1.9: +9 -9 lines
Diff to previous 1.9
fix bug in calculating emisions for scope 1 (meter readings), introduced in previous version.

Revision 1.9 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Jan 30 20:21:09 2007 UTC (2 years, 9 months ago) by johnackers
Branch: MAIN
Changes since 1.8: +152 -112 lines
Diff to previous 1.8
calculate kwh as well as co2 (aviation models wont work)

Revision 1.8 - (view) (download) (as text) (annotate) - [select for diffs]
Mon Jan 22 23:53:35 2007 UTC (2 years, 10 months ago) by johnackers
Branch: MAIN
Changes since 1.7: +97 -53 lines
Diff to previous 1.7
refactored so that emissions can be calculated without printing a table

Revision 1.7 - (view) (download) (as text) (annotate) - [select for diffs]
Thu Dec 21 14:31:01 2006 UTC (2 years, 11 months ago) by johnackers
Branch: MAIN
CVS Tags: DRUPAL-4-7--0-3-1, DRUPAL-4-7--0-4, DRUPAL-4-7--0-5
Changes since 1.6: +21 -15 lines
Diff to previous 1.6
Put calculation notes on the correct row. Make air travel notes complete.

Revision 1.6 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Dec 20 13:36:50 2006 UTC (2 years, 11 months ago) by johnackers
Branch: MAIN
CVS Tags: DRUPAL-4-7--0-3
Changes since 1.5: +21 -12 lines
Diff to previous 1.5
check carbon_stamp access before creating a link for it.

Revision 1.5 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Dec 19 15:22:36 2006 UTC (2 years, 11 months ago) by johnackers
Branch: MAIN
Changes since 1.4: +159 -40 lines
Diff to previous 1.4
introduce the climate care model, fix errors with choose climate model, change messages given with meter readings.

Revision 1.4 - (view) (download) (as text) (annotate) - [select for diffs]
Fri Dec 15 11:19:39 2006 UTC (2 years, 11 months ago) by johnackers
Branch: MAIN
CVS Tags: DRUPAL-4-7--0-1, DRUPAL-4-7--0-2
Changes since 1.3: +88 -37 lines
Diff to previous 1.3
add notes to bottom of footprint

Revision 1.3 - (view) (download) (as text) (annotate) - [select for diffs]
Tue Dec 12 13:32:44 2006 UTC (2 years, 11 months ago) by johnackers
Branch: MAIN
Changes since 1.2: +24 -13 lines
Diff to previous 1.2
calculation bug fixes

Revision 1.2 - (view) (download) (as text) (annotate) - [select for diffs]
Fri Dec 1 21:43:25 2006 UTC (2 years, 11 months ago) by johnackers
Branch: MAIN
Changes since 1.1: +61 -26 lines
Diff to previous 1.1
bug fixing, improve integration with user module

Revision 1.1 - (view) (download) (as text) (annotate) - [select for diffs]
Wed Nov 29 15:28:38 2006 UTC (2 years, 11 months ago) by johnackers
Branch: MAIN
first rough version that just works

This form allows you to request diffs between any two revisions of this file. For each of the two "sides" of the diff, select a symbolic revision name using the selection box, or choose 'Use Text Field' and enter a numeric revision.

  Diffs between and
  Type of Diff should be a

Sort log by:

  ViewVC Help
Powered by ViewVC 1.1.2