关键词 > C代写
C Programming: Coursework Assignment (2022)
发布时间:2022-05-09
Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit
Department of Electrical and Electronic Engineering
C Programming: Coursework Assignment (2022)
OBJECTIVE
• To applyyour
C
programming
knowledge
and
skills
gained from
the unit lectures and
laboratory
classes to interpret
and analyse
a
real-world electrical
engineering dataset.
INTRODUCTION
THE DATASET
Theglobal
science
and
engineering
safety
company, Underwriters
Laboratories, has published a dataset [1] from
their investigations
into repeated
battery cycling and
the effects
it
has
on cell current
carrying
capacity
and
total
energy
capacity. The
battery under investigation
in
this
dataset is
of a
lithium
nickel
cobalt
aluminium chemistry and housed
in
a cylindrical
cell
18650 formfactor (Figure 1) with
a 3400
mAh current capacity.
LITHIUM BATTERY CELL UNDER INVESTIGATION
• NominalCapacity
=
3400
mAh
• Graphite/
NCA
• 18650Cell
Thistype
of
cell is
identical
to
those found in
a
Tesla
Model
S
battery pack.
Figure 1: |
Figure 2: |
The measurementscontained
within this
dataset involved
cycling this 18650 battery cell
from0-100%
discharge at
a
constant
current of 0.5 cell capacity = (3.4 Ah
*
0.5
= 1.6 A), and at
a constant
temperature
of
23°C while recording the
following parameters:
• Minand
max
current (A)
• Minand
max voltage (VDC)
• Chargeand
discharge
capacity
(Ah)
• Chargeand
discharge
energy
(Wh)
Thelarger dataset [1] contains 20
other tests
measuring
at
different currents, temperatures, and
rates
of
discharge.
Tests
like these are
useful
for
assessing
the expected
lifetime of
batteries when
subjected
to
different
environments,
as
well
as for assessing
their safety
profiles.
Inthis
folder you
will
find
a
reduced version
of
the
original
dataset (dataset.txt) showing
only
the
results
from
the following
columns:
Column |
Column |
Column |
The reduced dataset is formattedin
CSV
format
(comma
separated
variable)
and contains a
total
of 319 results.
TASKS
Yourtask
is
to write
a
C
program to
perform some preliminary data
analysis
on 100 selected results from
this
reduced
dataset and then output your findings onto
the terminal in
a pre-specified format
(see
below).
Inthis
folder
you
will
find a
C
program
that
is designed
to
help
you
get
started
reading
in values
from
the
CSV
file.
This
program uses
the
fscanf
function
to
read
in
3
values which it
then
stores
in simple
arrays.
Yourtask is
to
extend
this code so
that
it utilises
3 pre-specified data
structures (see below) in place of the arrays for
storing
the test
results.
You
then
are
required
to write the necessary
algorithms
for
analysing the
data
(see
below) and to construct
the printf statements
required
for
presenting
your
findings in
a
pre-specified
format (see
below).
Step 1: Setup data structures for storing your results
Yourprogram
should define
3
types of data
structures for
holding
the results:
Structure1: Name
= BatteryTest
Member |
Type |
Notes |
n |
int |
For |
ch_capacity |
float |
For |
ch_energy |
float |
For storing |
Yourprogram
should initialise
an
array
of
319
BatteryTest
structs.