Find Jobs
Hire Freelancers

Box Area - Python

$10-30 USD

In Progress
Posted almost 5 years ago

$10-30 USD

Paid on delivery
Bounding Boxes Positions A rectangle in a 2D plane with non-zero area is called a non-degenerate rectangle. A degenerate rectangle in a 2D plane is effectively a single segment or a point. In this problem we will consider only non-degenerate rectangles. Axis aligned rectangle is a rectangle each of which sides is parallel to x or y coordinate axis. Let A and B be two axis aligned rectangles with non-zero area. Depending on their location in the plane, A and B can be in various relative positions. We will divide all possible relative positions of two axis aligned rectangles into 8 cases listed below. 1. A and B are identical. 2. The boundary of one rectangle lies completely in the interior of the other rectangle. 3. The interior of one rectangle lies completely in the interior of the other rectangle and the borders of the rectangles share at least one point. 4. A lies completely outside of B. 5. The interiors of A and B do not intersect and both rectangles share at least one common point on their borders. 6. Exactly one corner point of one rectangle lies in the interior of the other rectangle and simultaneously exactly one corner point of the other rectangle lies in the interior of the first rectangle. 7. For at least one of the rectangles it holds that exactly two of its corner points lie outside the other rectangle. 8. The borders of the rectangles instersect one another in exactly four distinct points. Note that cases 1. - 8. list all possibilites, that is, the relative position of any two axis aligned rectangles in a plane always falls into one of the categories 1. - 8. Also note that each pair of cases is mutually exclusive, i.e. mutual position of any two rectangles fall into exactly one case 1. - 8. 1 The task A set of pairwise distinct points in the plane is given. Consider each pair of distinct triples of points which bounding boxes are non-degenerate and decide to which case 1. - 8. the relative position of the two bounding boxes belongs. Count how many pairs fall into each of the cases 1. - 8. Two triples of points are distinct if they differ in at least one point. Input The first input line contains one integer N, the number of input points. Next, there are N lines, each contains one point coordinates. Each line contains x and y coordinate separated by space. It holds 4 ≤ N ≤ 20. All coordinates are non-negative and less than 15. Output The output contains eight lines, each line corresponds to one of the cases 1. - 8. listed above. The cases are listed in ascending order. The lines contains one integer denoting the number of the case and another integer separated by space and denoting the number of pairs of non-degenerate boundig boxes of points triples which mutual position falls into this particular case. Example 1 Input 6 1 4 2 1 3 4 4 3 6 2 7 5 Output 1 4 2 4 3 70 4 2 5 18 6 14 7 78 8 0 Example 2 Input 4 1 1 3 6 7 2 4 3 Output 1 0 2 0 3 3 4 0 5 0 6 0 7 3 8 0 Example 3 Input 16 1 1 1 2 1 3 1 4 2 1 2 2 2 3 2 4 3 1 3 2 3 3 3 4 4 1 4 2 4 3 4 4 Output 1 5808 2 208 3 56624 4 4576 5 27984 6 968 7 42704 8 256 P.S. You should improve and use code in Attachment
Project ID: 20022379

About the project

9 proposals
Remote project
Active 5 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
9 freelancers are bidding on average $29 USD for this job
User Avatar
I have experience using R for statistical analysis and machine learning and have worked on various data science projects such as recommender systems with NLP components, data mining with associative rules, etc. I also have a background in systems administration meaning that setting up, configuring and maintaining such systems as Hadoop environments, Spark clusters and cloud services are part of my forte. This means that I am able design and implement complex data science pipelines quite efficiently. Thus, I believe I am a good candidate to assist you with your tasks. Hoping to work with you on this project.
$80 USD in 7 days
4.9 (33 reviews)
5.1
5.1
User Avatar
Hi, I have 5+years Experience in Website/Software Design & Website Development. I'm an Expert in: -Frontend & Backend Development -Python -Data Science -Machine Learning -JVM technologies -Jquery, PHP -Ionic - Hybrid Mobile Applications -Angular, Node.js -Ruby on Rails -C++ Who Knows the value of time. Very hard working and always delivers the work on time. I will finish your tasks in a timely and efficient manner, I aspire to help others reach their goals through the use of my knowledge and experience, I am available 24 hours support. I am available for the weekend also. If you are looking for website design and development I am the right person for you
$25 USD in 1 day
4.9 (9 reviews)
4.1
4.1
User Avatar
Hi, this is a very interesting problem and I'm pretty sure I can solve it. I am a frequent projecteuler user, which is a site that provides this type of programming problems. I can definitely do this task in the most optimised way. Please contact me if you are interested. I will also explain the program to you
$50 USD in 3 days
5.0 (9 reviews)
3.6
3.6
User Avatar
Good day! I'm a licensed full stack programming developer and designer. I have many experiences in python image processing by using python openCV package. I have many experiences in c#,c++,c,java programming. I had read your project description carefully. I'm interested in your project, please feel free to check my clients reviews, my profile and if you are interested too, we can discuss more details. Thank you very much.
$25 USD in 1 day
5.0 (1 review)
2.6
2.6
User Avatar
I am a Python developer with 4+ years of experience that specializes in multi-platform applications using PyQt, PySide/PyQt,Scrapy, BeautifulSoup 4,,django, Pillow, Matplotlib, Xml, json, and csv modules, Celery I am also working to be more of a Full-Stack developer, so that means I have more experience than indicated by just my Python background. I enjoy working with passionate people who know what it is they need and where they are headed. I've worked with individual people and with organizations in teams of 3+ people from all over the world. As a developer, I make a point to write my code in a consistent style adhering to the PEP8 style document. For other languages,I also make an ?effort to write good quality tests and documentation for all of the code I write. Kindly reply me soon so we can discuss more about this. Thanky you
$20 USD in 7 days
4.5 (12 reviews)
3.0
3.0
User Avatar
Hello Sir/ Ma’am We are a group of Software Engineers (Programmers) having 10+ years of experience. Expert in JAVA, C, C++ , C# , Python, ANDROID,IOS, MATLAB, IONIC. Done 40+ projects here on FREELANCER.COM. Please check our profile for reference. The bid is negotiable and we can talk about the price. Thank you
$10 USD in 1 day
5.0 (1 review)
2.1
2.1
User Avatar
I offer this cheap rate, since I am new to this website! Very experienced programmer offering good service.
$10 USD in 1 day
0.0 (0 reviews)
0.0
0.0
User Avatar
Hello I have years of experience in Python programming. I can help in the code optimization and can complete the work with 100% satisfaction.
$25 USD in 2 days
0.0 (1 review)
0.0
0.0
User Avatar
Hello! I have read your description of a project. I'm a full stack web developer. I want to let you know that I have great experience in web development. I can professionally work on your project. I'm interested in your project. looking forward. thank you
$20 USD in 3 days
0.0 (0 reviews)
0.0
0.0

About the client

Flag of CZECH REPUBLIC
Prague, Czech Republic
5.0
4
Payment method verified
Member since Jun 10, 2019

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.