65925 – Need help on python assignmentSimulate Soil ConsolidationSimulate

SOLUTION AT Australian Expert Writers

Need help on python assignmentSimulate Soil ConsolidationSimulate Soil ConsolidationDue date 11:59PM Friday 28 May April 2021 (local Sydney time)You are tasked to write the parts needed for the simulation of soil consolidation.Changes to descriptionThis document is being updated:Students should refer to the Ed website for any clarications, or changes to being made to the assignment description. https://edstem.org/courses/5268/lessons/11409/edit/slides/82475 A brief list of changes is documented here.9 May 2021CLAY_COMPRESSIBILITY_RATE is 0.001. It is a constant dening water units moved per 1kN per hour (no longer 100kN)A message to all students about Academic IntegrityThis is an assignment and sta are not permitted to give specic guidance on your code, or how to solve the specic problem. That is the purpose of the assessment that you are required to perform to achieve the grade.You may ask clarication questions about the assignment description. This is often necessary to implement functionality that is otherwise ambiguous.The assignment description is not intended to be complete and you can conrm your assumptions in a form of a question. In asking the question you should be quoting the description you are asking about.If you have a question to ask on Ed please search before asking. However, remember that you should not be posting any assignment code publicly, as this would constitute academic dishonesty.Also, do not wait too long before starting. This assignment needs time and sustained eort.BackgroundConsolidation is the gradual changes in volume of a partly or fully saturated soil when subject to a sustained load. The changes are mainly due to the removal of gases, uids and organic matter from the soil. We simplify our model to consider this matter as water.A sample of soil shows the particles arranged with voids between them.Soil can be composed of many minerals, primary silica, but clay, sand, shale, rock. Some of these have more water content than others. Water is present within soil and we can assume water is an incompressible uid, where any pressure applied will cause the water to move to a lower pressure. The water is eectively squeezed out of the soil very slowly.Soil consolidation has a huge impact on the planning and construction of buildings throughout history. The leaning tower of Pisa is a great example to showcase the importance of soil consolidation [https://www.geoengineer.org/education/web-class-projects/ce-179-geosystems-engineeringdesign/assignments/the-tilt-of-the-tower-of-pisa-why-and-how ].https://www.youtube.com/watch?v=nK4oDD-4CeE The purpose of the simulation is to determine:how long consolidation will take for a given load and placement over a soil conguration how much water is displaced during consolidation what are the changes in height of the soil after consolidationSimulation Input and Outputfunctionality for le input/output provided for youThe simulation will require information about the nature of the soil, the load, and the parameters used to simulate. These are read from a le using the three command line arguments.$ simulate.py simulation parameters file path soil data file path output file pat hYour program will read in a le for the simulation parameters from argument 1Your program will read in a le for the soil geometry and composition from argument 2 Your program will write to a le for the results of the simulation from argument 3For example:$ simulate.py tests/params_example1.in tests/soil_example1.in sim_results_p1_s1.txtModelling of the problemThe modelling of soil consolidation in this assignment makes the following assumptions:soil particles have no airsoil particles initially have a capacity to hold water and is considered full for example, if clay can hold 40% water, then at the beginning of the simulation, the clay particle holds 40% water.water is an incompressible uid water moving out of a particle will cause the particle to compress any amount of water removed from a particle cannot be reintroducedsoil particle categorisation is limited to Clay and Shale and only relevant to the initial conditions bedrock is an incompressible particle and will always provide an equal and opposite reactive forceThe void particle is a simple characterisation of representing a lower pressure area and it is assume to have no volume or capacity. A sand column could be represented as a lower pressure region, but as a void it has no capacity.We model a particle of soil.soil consists of a mixture of solid matter (aggregate) and water.soil particle has a capacity to hold water. This is dictated by the soil type and the water capacity value [0,1] soil particle has pressure acting on it.Initially the soil particle is at a rest state, in equilibrium with its neighbours.adding force to the soil will cause change in pressure and result in a movement of water assume a particle is 1 unit wide and 1 unit deep (square) We model the movement of water.water is an incompressible uid. the entire soil mass is considered as a body of uid where the pressure is even throughout. water reaching a void in the soil will cause it to leak out (sink). Void are explicitly dened in every simulation.pressure acting on the soil will cause the equivalent water mass to leave the exit points of the soil.There should always be a leak point, place for water to be displaced.If soil has no leak points, the pressure will continue to rise and no water movement is possible until there is a break in those soil barriers such as bedrock. This building of pressure and breaking is not considered in the model or the simulation.water can move up into a void, against gravity. This is to reduce complexity of the assignment.We model the rate at which water moves out of soil:if there is 0.04 water in a particle of clay, and 100kN is applied over one hour.Water moved is 100,000 x 0.001 = 0.1 . 0.1 0.04 , and we expect the particle of clay will have 0.00 units of water.File formatsApplicable to parse_sim_parameters and parse_soil_dataCommentsComments can appear after or before a label/value(s) pair.Labels and ValuesA label is the text used to identify the parameter. e.g. Load weight . A value is information for thatOnce a label has been identied, the value(s) are always in next lines that follow. A blank line is used to separate denitions of labels and their values.Labels can appear at any point within the le. There is no specic ordering.Label matching and identicationEach le format has a well dene set of labels.All label matching is case insensitive.Duplicate labelsLabels appearing more than once are permitted, however, only the last value is used.For example:During the reading of the le, the program should print a message to the console stderr Warning label Load weight defined twice. Using last value of 800Simulation Parameters le formatApplicable to parse_sim_parametersFormat detailsLoad location, width2 integers, representing columns starting and how many columns wide comma separatedmust each be positive integers from 0 to 100Load weight1 integer representing kilonewtons of weight must be a positive integer between 0 and 1,000,000Load type1 string – Constant or Linear or Custom Optional, default is Constant . Load timing1 integer representing the number of hours the load will apply for Linearnot used for Constant or Custom Load types must be a positive integer between 0 and 1,000,000Load custom data pairs of integer values representing the weight of the load at the given timeComma separated in the order hour , load weight Used when Custom Load type is dened. Otherwise ignored. Must have an even number of values (a whole number of pairs) denes zero and positive integers time values dened incrementally no duplicate time valuesExample leSoil data le formatThe keys describe a symbol to use for a particular soil category. The width of the symbol is 1 character.The key description is a string of any sizeExampleHHCCCCCCHHHHHHHHHHHHHCCCCHHHHHHHHHHHHHHHHHHHCCCCHHHHHHHHHHHHHHCCCCCCCCCCCCCCCCCCCHHHHHHHHHHHHHHHVVHHHCCCCCCCCCCCCCCCCHHHHHHHHHHHHHHHHHHVVVHHHHHHHHVHHHHHCCCCCCCCCCCCCCCCCCCHHHHHVHHHHHHHHHHHHHHCCCCCCCCCCCCCCCCHHHHHHHHCCCCCCCHHHHHHHCCCCCCCCHHHCCCCCCCCCHHHHHCCCCHHHHHCCCCCCHHHHHHCCCCCCCHHHHHHHCCCCCCCCHHHCCCCCCCCCHHHHHCCCCHHHHHCCCCCCCHHCCCVVVCCCCCCCCCCCCCHHHHHHHHHCCCCCCCCCHHHHHCCCCHHHHHCCCCCCCBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBA special particle is the void. Void is represented by a V . It represents a space which will allows water to move to (lower pressure).Format detailsApplicable to parse_soil_dataSoil width, depth2 integers representing the number of columns and the number of layers (rows) of soil data to follow comma separatedmust each be positive integers from 0 to 10,000Soil keys pairs of character,string for representing a soil particle type by a single character comma separatedmust have an even number of values must dene single character followed by a string no duplicate values (key or description)Soil datastring(s)must have the appropriate number of columns and rows previously dened must be characters dened in the Soil keys all rows are equal length all columns are equal lengthSimulation parametersApplicable to check_simulation_data, calculate_applicable_load, calculate_current_load, simulation_startLoad location, widthWhere and how wide the load is placed.The location is the column integer, where 0 is the left most column. The width is the side of the load For example:Load location = 1 Load width = 1In this document, we will represent load with L to illustrate the load location and width. However,Distributed loadThe weight of the load implies a force. The width of the load implies a distribution of force over area, pressure.When simulating, the load will only aect the body of water which are under loadLoad on Column 0 has no eect in this model Load on Column 1 has eect in this model Load on Column 2 has eect in this modelFor simplication, you may assume that where a column is not all bedrock, the load will aect it.All columns aectedHint: You should focus on load width of 1 to simulate rst before moving to distributed loadsLoad type and timingConstant load is xed. Every hour will impose a force of Load weight at the load point(s).Linear. At time zero, there is zero load. At time Load timing , there will be 100% of the Load weight at the load point(s). For example, if Load weight=100 and Load timing = 10 . It would take 10 hours for the load to reach 100kN.This aects the rate of consolidation.Custom load are user specied times and load weights to be used in the simulation. For example, the user may specify:The user may alternatively specify sparse time sequences:For the simulation, you may assume that the times not specied will use the same value as the previous time.The only error checking you need for custom data is where there are missing pairs of time/load values. Otherwise, you may assume that the custom data is correct.A group of connected soil particles as a body of waterParticles of clay that are adjacent will share the same pressure and push of water throughout.Therefore, the simulation requires knowing which particles constitute a group, or a body of water.Example: 1 body of water. All clay particles C are adjacent to all other clay C particles. A pressure acting on any clay particle will be transmissible throughout the body of water.Example: 3 bodies of water. There are bedrock particles creating a barrier between the clay particles.Important:You do not have to calculate a body of waterYou do not have to consider the case where a load is applied to 2 or more bodies of water.This is calculated for you using the function leak_points, fluid_body_particles = find_leak_points(start_particle)Every hour of the simulation the body of water will lose an amount of water related to the load applied.The formula for calculating the water moved in 1 hour relates to how much load is applied at the time, how much is applicable to the soil (exclude bedrock), and the rate of water movement out of soil particles (constant).water_moved = CLAY_COMPRESSIBILITY_RATE x load_applicableConsistency checking between parameters and soilHaving both parameters and soil data, we can test whether these conditions are satised before proceeding.Load over soilLoad geometry must be positioned entirely over soil (Load geometry cannot be overhanging the edge)Example of not permitted:Load not overhangingLoad must be placed over compressible soil particles (e.g. Clay) Example of not permitted:Simulation examplesExample 1Consider a column of clay soil with a force applied vertically.Let the load L be 100kNThe water volume and capacity for clay is 0.4 in this example.The rate of water movement from clay is 0.001 per hour for every 1kN of force.The sides of the column are empty, meaning water can leak there innitelyThere are 4 leak points in this example Void (V) particles Initial conditions can be represented as so:Initial conditions, height of middle column = 3Initial conditions, as numeric values of water capacity:where i is inniteInitial conditions, as numeric values of water volume:After 1 hourThere is 0.1 of water removed per hour on the entire soil mass. The soil pressure is even throughout, and 0.1 water move to the 4 leak points. Water leaked = 0.1 / 4 = 0.025 capacity (always the same)water volume0.1 water units removed from the soil in this hour 0.1 total water units removed since t=0 After 2 hours water volume0.1 water units removed from the soil in this hour 0.2 total water units removed since t=0 After 3 hours water volume0.1 water units removed from the soil in this hour 0.3 total water units removed since t=0After 4 hours water volume0.1 water units removed from the soil in this hour 0.4 total water units removed since t=0 After 5 hours water volume0.1 water units removed from the soil in this hour 0.5 total water units removed since t=0 After 6 hours water volume0.1 water units removed from the soil in this hour 0.6 total water units removed since t=0 After 7 hours water volume0.1 water units removed from the soil in this hour 0.7 total water units removed since t=0 After 8 hours water volume0.1 water units removed from the soil in this hour 0.8 total water units removed since t=0 Final result height of middle column = 2.20.8 units of water has been removed from the soil.Example 2So long as there is a lower force area, water can be pushed out.Consider two columns of clay soil surrounded by bedrock with a vertical force applied on the left column only.Let the load L be 100kNThe water volume and capacity for clay is 0.4 in this example.The rate of water movement from clay is 0.001 per hour for every 1kN of force.There is one leak point in this example Void (V) particle. water ows toward this point.Initial conditions can be represented as so:Initial conditions5 columns:height of column 1 = 4height of column 2 = 4height of column 3 = 4height of column 4 = 4Initial conditions, as numeric values of water capacity:Initial conditions, as numeric values of water volume:After 1 hour capacity (always the same)Water volume decreases by 0.1 from all particles sharing this force. 7 particles: 0.1 / 7 = 0.0140.1 water units removed from the soil in this hour 0.1 total water units removed since t=0After 2 hours water volume0.1 water units removed from the soil in this hour 0.2 total water units removed since t=0 After 3 hours water volume0.1 water units removed from the soil in this hour 0.3 total water units removed since t=0…After 28 hours water volume0.1 water units removed from the soil in this hour 2.8 total water units removed since t=0 Final result height of column 2 = 2.8height of column 3 = 3.6 (cavity collapses)height of column 4 = 2.82.8 units of water has been removed from the soil.Example 3This example will demonstrate the load linearly increasing to the maximum weight.Consider a column of clay soil with a force applied vertically.Let the load L be 2450kNLet the load timing be 10 hoursThe water volume and capacity for clay is 0.4 in this example.The rate of water movement from clay is 0.001 per hour for every 1kN of force. There are 3 leak points in this example Void (V) particles Initial conditions can be represented as so:Initial conditions t=05 columns:height of column 1 = 4height of column 2 = 4height of column 3 = 4height of column 4 = 4 height of column 5 = 4Initial conditions, as numeric values of water capacity:Initial conditions, as numeric values of water volume:After 1 hour t=1Water volume decreases by 0.245 from all particles sharing this force.12 particles: 0.245 / 12 = 0.020416667 loss each0 0.380 0.380 0.380 0.380 0.08170 0.380 0.380 0.380 0.380 0.08170 0.380 0.380 0.380 0.380 0.08170 0 0 0 0 00.245 water units removed from the soil in this hour 0.245 total water units removed since t=0 After 2 hoursForce applied at this time is: (2/10) * 2450 = 490 water_moved = ( 0.1 * 490 ) / 100 = 0.49Water volume decreases by 0.490 from all particles sharing this force.12 particles: 0.490 / 12 = 0.040833333 loss each0 0.339 0.339 0.339 0.339 0.2450 0.339 0.339 0.339 0.339 0.2450 0.339 0.339 0.339 0.339 0.2450 0 0 0 0 00.490 water units removed from the soil in this hour 0.735 total water units removed since t=0 After 3 hoursForce applied at this time is: (3/10) * 2450 = 735 water_moved = ( 0.001 * 735 ) = 0.735Water volume decreases by 0.735 from all particles sharing this force.12 particles: 0.735 / 12 = 0.06125 loss each0.735 water units removed from the soil in this hour 1.47 total water units removed since t=0 After 4 hoursForce applied at this time is: (4/10) * 2450 = 980 water_moved = ( 0.001 * 980 ) = 0.98Water volume decreases by 0.98 from all particles sharing this force.12 particles: 0.98 / 12 = 0.081666667 loss each0.98 water units removed from the soil in this hour 2.45 total water units removed since t=0 After 5 hoursForce applied at this time is: (5/10) * 2450 = 1225 water_moved = ( 0.001 * 1225 ) = 1.225Water volume decreases by 1.225 from all particles sharing this force.12 particles: 1.225 / 12 = 0.102083333 loss each0 0.094 0.094 0.094 0.094 0.8160 0.094 0.094 0.094 0.094 0.8160 0.094 0.094 0.094 0.094 0.8160 0 0 0 0 01.225 water units removed from the soil in this hour 3.675 total water units removed since t=0 After 6 hoursForce applied at this time is: (6/10) * 2450 = 1470 water_moved = ( 0.001 * 1470 ) = 1.47Water volume decreases by 1.47 from all particles sharing this force.12 particles: 1.47 / 12 = 0.1225 loss each0 0.000 0.000 0.000 0.000 0.8160 0.000 0.000 0.000 0.000 0.8160 0.000 0.00 0.000 0.000 0.8160 0 0 0 0 01.125 water units removed from the soil in this hour (remainder) 4.8 total water units removed since t=0Final result heights:4.8 units of water has been removed from the soil in 6 hours.Example 4This example will demonstrate the custom load.Consider the scenario where sand columns are used to consolidate faster:Load custom data is: 0,200, 15,550, 25,977, 99,1489The water volume and capacity for clay is 0.4 in this example.The rate of water movement from clay is 0.001 per hour for every 1kN of force.There are 16 leak points in this example Void (V) particlesThere are 39 soil particles in this example Clay (C)There is only one body of waterSand columns are emulated as void and are positioned between clay columns.Initial conditions can be represented as so:Initial conditions t=0 heights:Column 1 2 3 4 5 6 7 8 9 10 11 12 13——————————————–6, 6, 2, 6, 6, 2, 6, 6, 2, 6, 2, 6, 6Hours 1-14Load is 200 for all these hours based on the custom data t=0, L=100t=1. heights: [6, 5.974, 1.995, 5.974, 5.974, 1.995, 5.974, 5.974, 1.995, 5.974, 1.995, 5.974, 6] t=2. heights: [6, 5.949, 1.99, 5.949, 5.949, 1.99, 5.949, 5.949, 1.99, 5.949, 1.99, 5.949, 6]t=3. heights: [6, 5.923, 1.985, 5.923, 5.923, 1.985, 5.923, 5.923, 1.985, 5.923, 1.985, 5.923, 6]t=4. heights: [6, 5.897, 1.979, 5.897, 5.897, 1.979, 5.897, 5.897, 1.979, 5.897, 1.979 , 5.897, 6]t=5. heights: [6, 5.872, 1.974, 5.872, 5.872, 1.974, 5.872, 5.872, 1.974, 5.872, 1.974, 5.872, 6]t=6. heights: [6, 5.846, 1.969, 5.846, 5.846, 1.969, 5.846, 5.846, 1.969, 5.846, 1.969, 5.846, 6]t=7. heights: [6, 5.821, 1.964, 5.821, 5.821, 1.964, 5.821, 5.821, 1.964, 5.821, 1.964, 5.821, 6]t=8. heights: [6, 5.795, 1.959, 5.795, 5.795, 1.959, 5.795, 5.795, 1.959, 5.795, 1.959, 5.795, 6]t=9. heights: [6, 5.769, 1.954, 5.769, 5.769, 1.954, 5.769, 5.769, 1.954, 5.769, 1.954, 5.769, 6]t=10. heights: [6, 5.744, 1.949, 5.744, 5.744, 1.949, 5.744, 5.744, 1.949, 5.744, 1.949, 5.744, 6]t=11. heights: [6, 5.718, 1.944, 5.718, 5.718, 1.944, 5.718, 5.718, 1.944, 5.718, 1.944, 5.718, 6]t=12. heights: [6, 5.692, 1.938, 5.692, 5.692, 1.938, 5.692, 5.692, 1.938, 5.692, 1.938, 5.692, 6]t=13. heights: [6, 5.667, 1.933, 5.667, 5.667, 1.933, 5.667, 5.667, 1.933, 5.667, 1.933, 5.667, 6]t=14. heights: [6, 5.641, 1.928, 5.641, 5.641, 1.928, 5.641, 5.641, 1.928, 5.641, 1.92 8, 5.641, 6]Hours 15-24Load is 550 for all these hours based on custom data t=15, L=550t=15. heights: [6, 5.615, 1.923, 5.615, 5.615, 1.923, 5.615, 5.615, 1.923, 5.615, 1.923, 5.615, 6]t=16. heights: [6, 5.545, 1.909, 5.545, 5.545, 1.909, 5.545, 5.545, 1.909, 5.545, 1.909, 5.545, 6]t=17. heights: [6, 5.474, 1.895, 5.474, 5.474, 1.895, 5.474, 5.474, 1.895, 5.474, 1.895, 5.474, 6]t=18. heights: [6, 5.404, 1.881, 5.404, 5.404, 1.881, 5.404, 5.404, 1.881, 5.404, 1.881, 5.404, 6]t=19. heights: [6, 5.333, 1.867, 5.333, 5.333, 1.867, 5.333, 5.333, 1.867, 5.333, 1.867, 5.333, 6]t=20. heights: [6, 5.263, 1.853, 5.263, 5.263, 1.853, 5.263, 5.263, 1.853, 5.263, 1.853, 5.263, 6]t=21. heights: [6, 5.192, 1.838, 5.192, 5.192, 1.838, 5.192, 5.192, 1.838, 5.192, 1.838, 5.192, 6]t=22. heights: [6, 5.122, 1.824, 5.122, 5.122, 1.824, 5.122, 5.122, 1.824, 5.122, 1.824, 5.122, 6]t=23. heights: [6, 5.051, 1.81, 5.051, 5.051, 1.81, 5.051, 5.051, 1.81, 5.051, 1.81, 5.051, 6]t=24. heights: [6, 4.981, 1.796, 4.981, 4.981, 1.796, 4.981, 4.981, 1.796, 4.981, 1.79 6, 4.981, 6]Hours 25-37Load is 977 for all these hours based on custom data t=25, L=977t=25. heights: [6, 4.91, 1.782, 4.91, 4.91, 1.782, 4.91, 4.91, 1.782, 4.91, 1.782, 4.91, 6]t=26. heights: [6, 4.785, 1.757, 4.785, 4.785, 1.757, 4.785, 4.785, 1.757, 4.785, 1.757, 4.785, 6]t=27. heights: [6, 4.66, 1.732, 4.66, 4.66, 1.732, 4.66, 4.66, 1.732, 4.66, 1.732, 4.66, 6]t=28. heights: [6, 4.534, 1.707, 4.534, 4.534, 1.707, 4.534, 4.534, 1.707, 4.534, 1.707, 4.534, 6]t=29. heights: [6, 4.409, 1.682, 4.409, 4.409, 1.682, 4.409, 4.409, 1.682, 4.409, 1.682, 4.409, 6]t=30. heights: [6, 4.284, 1.657, 4.284, 4.284, 1.657, 4.284, 4.284, 1.657, 4.284, 1.657, 4.284, 6]t=31. heights: [6, 4.159, 1.632, 4.159, 4.159, 1.632, 4.159, 4.159, 1.632, 4.159, 1.632, 4.159, 6]t=32. heights: [6, 4.033, 1.607, 4.033, 4.033, 1.607, 4.033, 4.033, 1.607, 4.033, 1.607, 4.033, 6] t=33. heights: [6, 4.0, 1.6, 4.0, 4.0, 1.6, 4.0, 4.0, 1.6, 4.0, 1.6, 4.0, 6]Final result15.6 units of water has been removed from the soil in 33 hours.Your tasksPlease see the following functions for you to complete. They describe the necessary input and output.[ ] Complete the code necessary to load and parse the simulation parameters le.BCCSBBBB[ True, False, False, False ][ ] Complete the code for the check_simulation_data functiondef check_simulation_data(config):check the simulation parameters and soil data are compatible- load location must be within the columns of soil defined- load width cannot overhang last soil columninput: config variables for simulation parameters and soil output: on success, return True, otherwise return False[ ] Complete the code for the calculate_applicable_load functiondef calculate_applicable_load(config, particles2d, current_load):Calculate how much of the load will be applied based on whether there are bedroFormula for your idea: load = load * ( #non-bedrock-cols / width + #bedrock-cols / width )input:current_load, the number of kN for the given time instance (externally config data with Load location and dimensions. particle2d – 2D grid of particles at present output: the kN (single float) applied to the body of water[ ] Complete the code for the calculate_current_load functiondef calculate_current_load(config, hours_passed):caclulate the amount of weight to be applied at hours_passed time.- Where the load type is constant. config.load_weight is returned.- Where the load type is linear, a calculation is needed based onhours_passed and load_timing. If the hours_passed exceeds load_timing, then the full load_weight is used- Where the load type is custom, the calculation follows the pairsof time,load values in config.load_custom_data. config.load_custom_data is assumed to be in time sorted order with no duplicates. The intermediate values of custom data use the last known times load value. If the hours_passed is before all time/load pairs, then the load is zero.input: config information config.load_weight, config.load_type, config.load_timing, co hours_passed – representing the current time in the simulation. must be a posit output: on success, the load applied (single float) is returned (without considering th on failure, -1.0 is returned[ ] Complete the partially completed code for the simulation_start() function. Refer to the scaold code provided.Sta will run tests on your code. The functions will be called to evalute the output to your functions. You are to ensure the correct data is returned or set in memory as described by the function. Test loading the conguration le for simulation parametersHow do I begin?It is always good to start with the simplest possible simulation to run. Small number of particles, very well dened input and outcome. Pick a simple scenario. Here is a suggested one.Create a simple congurationThe conguration les: basic_params.inbasic_soil.inExpectationsCan you predict the expected outcome?Height should be 0.6 + 0.6 + 0 + 1 = 2.2 Time taken?1 clay has 0.4 watertotal water for 2 clay is thus 0.8 waterCLAY_COMPRESSIBILITY_RATE = 0.001 hence it would take 8 hoursCode for the basic simulation scenarioNo need to write code for:simulate.py summarise_sim_data()Expected to return this list of stringssummarise_soil_data()Expected to return this list of stringsEasy implementation for the basic simulation scenariocheck_simulation_data() – always returns True calculate_applicable_load() – always returns current_load calculate_current_load() – always returns config.load_weight sim_loader.pyconfig.soil_depth = 4config.soil_keys = [ C,Clay, B,Bedrock, , V,Void] config.soil_data = [ [C], [C], [V], [B] ] return Truesim_particles2d.py get_bedrock_columns() – always returns [ False ] calculate_heights()height = 0 height += (1 – particles2d[0][0].capacity) + particles2d[0][0].water height += (1 – particles2d[1][0].capacity) + particles2d[1][0].water # for particles2d[2][0], skip adding height of void particle # for particles2d[3][0], always add height 1 for bedrock particle height += 1 return [height]sim_results.py init() – use suggested variables get_consolidation_time() – returnsself.consolidation_time get_total_water_removed() – returns self.total_water_removedget_height_data() – returns self.heights_data get_load_data() – returns self.load_data Hardest partRun the code:python3 simulate.py tests/basic_params.in tests/basic_soil.in results.txt Check your resultsThe results le should look sim_param: basic_params.in soil_data: basic_soil.inConsolidation time: 8Total water removed: 0.7999999999999999t=0. load: [0, 100, 100, 100, 100, 100, 100, 100, 100] heights: [[0], [2.9], [2.8], [2 .7], [2.6], [2.5], [2.4000000000000004], [2.3], [2.2]]t=1. load: [0, 100, 100, 100, 100, 100, 100, 100, 100] heights: [[0], [2.9], [2.8], [2.7], [2.6], [2.5], [2.4000000000000004], [2.3], [2.2]]t=2. load: [0, 100, 100, 100, 100, 100, 100, 100, 100] heights: [[0], [2.9], [2.8], [2.7], [2.6], [2.5], [2.4000000000000004], [2.3], [2.2]]t=3. load: [0, 100, 100, 100, 100, 100, 100, 100, 100] heights: [[0], [2.9], [2.8], [2.7], [2.6], [2.5], [2.4000000000000004], [2.3], [2.2]]t=4. load: [0, 100, 100, 100, 100, 100, 100, 100, 100] heights: [[0], [2.9], [2.8], [2.7], [2.6], [2.5], [2.4000000000000004], [2.3], [2.2]]t=5. load: [0, 100, 100, 100, 100, 100, 100, 100, 100] heights: [[0], [2.9], [2.8], [2.7], [2.6], [2.5], [2.4000000000000004], [2.3], [2.2]]t=6. load: [0, 100, 100, 100, 100, 100, 100, 100, 100] heights: [[0], [2.9], [2.8], [2.7], [2.6], [2.5], [2.4000000000000004], [2.3], [2.2]]t=7. load: [0, 100, 100, 100, 100, 100, 100, 100, 100] heights: [[0], [2.9], [2.8], [2 .7], [2.6], [2.5], [2.4000000000000004], [2.3], [2.2]]What next?Now you can pick which part to increase in complexity.How about checking the le format values for this basic simulation scenario are correct or rejected? (test your code!)How about changing the number of clay particles from 2 — 3 ? but ideally how can you change it from 2 — N particles!How about a dierent shape of soil?How about a dierent load location?How about changing from Constant to Linear Load Type? etc.Take small steps. Test as you go using the previous as well as new scenarios. Use scenarios where you already know or can conrm the outcome!Code SubmissionYour code submission must be made via Ed in this lesson.To make a submission, you will need to press the -Mark- button.You may submit as many times as you wish without penalty.You are able to view previous submissions from the code submission section.Every submission you make includes the README.md and the python .py les The following rules apply to your code submission:Only the le simulate.py will be started by the automarker Only the last submission will be graded.Only the nal README.md le of the last submission will be graded by your tutorSubmission after the due date will incur a late penalty as described in the unit of study outline. Your submission must be able to compile and run within the Ed environment provided.After each submission, the marking system will automatically check your code against the public test cases.The Python version is that which is presently being used on Ed system:Please ensure you carefully follow the assignment description. Your program output must exactly match the output shown in the examples. Late is late!The computer does not discriminate about what is late. There are two les for submission all python les .pyREADME.mdThey are both in your Ed workspace. Make sure these are the ones for your submission.Changes to these les after the deadline will incur a penalty for both (not individually).Marking criteriaThis assignment is 20% of your nal course grade.The grade you will receive is based on the number of test cases passed as well as manual grading by your tutor.We have provided you with some sample test cases but these do not test all the functionality described in the assignment. It is important that you thoroughly test your own code.Automatic tests 15 / 20These are marked by a computer.There are public test casesThere are hidden test casesThere are private test casesManual grading 5 / 20The manual grading from your tutor will consider the style, layout and comments you provide in your code. Your tutor will not be debugging or running your code against any test cases.edit the README.md le to describe the parts you have completed and the general structure of your code. Maximum 1000 words. See scaold le directory in Ed.Explain how each of these modules and their functions are used as part of the simulation:sim_cong.py sim_loader.py sim_particle.py sim_particles2d.py sim_results.py simulate.pyJustify the choice of testing tool and type of tests that you have conducted to verify your work. Additional Python les and logs that were created to run these tests must be included in your submission.in your python code les .py:Please ensure your code is comprehensible for the purposes of marking. We recommend that your code adheres to the PEP 8 style guide https://www.python.org/dev/peps/pep0008/Please use comments or docstrings for sections of code to explain the sections purpose. e.g. the following block of code will -search for-, -calculate-, -get input for options- etc.Academic declarationBy submitting this assignment you declare the following:I declare that I have read and understood the University of Sydney Academic Dishonesty and Plagiarism in Coursework Policy, and except where specically acknowledged, the work contained in this assignment or project is my own work, and has not been copied from other sources or been previously submitted for award or assessment.I understand that failure to comply with the the Academic Dishonesty and Plagiarism in CourseworkPolicy, can lead to severe penalties as outlined under Chapter 8 of the University of Sydney By-Law 1999 (as amended). These penalties may be imposed in cases where any signicant portion of my submitted work has been copied without proper acknowledgement from other sources, including published works, the internet, existing programs, the work of other students, or work previously submitted for other awards or assessments.I realise that I may be asked to identify those portions of the work contributed by me and required to demonstrate my knowledge of the relevant material by answering oral questions or by undertaking supplementary work, either written or in the laboratory, in order to arrive at the nal assessment mark.I acknowledge that the School of Computer Science, in assessing this assignment, may reproduce it entirely, may provide a copy to another member of faculty, and or communicate a copy of this assignment to a plagiarism checking service or in house computer program, and that a copy of the assignment may be maintained by the service or the School of Computer Science for the purpose of future plagiarism checking.Warning: Any attempts to deceive or disrupt the marking system will result in an immediate zero for the entire assignment. Negative marks can be assigned if you do not properly follow the assignment description, or your code is unnecessarily or deliberately obfuscated.

Order from Australian Expert Writers
Best Australian Academic Writers

QUALITY: 100% ORIGINAL PAPERNO PLAGIARISM – CUSTOM PAPER

Assignment status: Already Solved By Our Experts

YOU MAY ALSO READ ...  65188 – need help with these

(USA, AUS, UK & CA Ph. D. Writers)

CLICK HERE TO GET A PROFESSIONAL WRITER TO WORK ON THIS PAPER AND OTHER SIMILAR PAPERS, GET A NON PLAGIARIZED PAPER FROM OUR EXPERTS

Order from Australian Expert Writers
Best Australian Academic Writers

QUALITY: 100% ORIGINAL PAPER – NO PLAGIARISM – CUSTOM PAPER