Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 14 Next capture
2021 2022 2023
4 captures
13 Jun 22 - 14 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Morphus74 · May 15 at 06:18 PM · physicsmath

How do you define angle/velocity for a projectile, if you know final height and distance to reach

I have a weapons that have a min/max angle, and min/max velocity.

My target height is known, and the distance also.

I know how to compute my maximum distance to see if I can reach, but is there a way base on a range of possible velocity/angle to determine the best value by minimizing time?

Thank

Comment
Add comment · Show 4
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image elenzil · May 16 at 06:17 PM 1
Share

interesting. I think a shortcut to minimize time would be to minimize maximum altitude attained by the projectile.

avatar image Morphus74 elenzil · May 17 at 07:46 PM 0
Share

interesting :) will see if that can bring me somewhere

avatar image elenzil Morphus74 · May 17 at 08:55 PM 1
Share

I think, equivalently, you can minimize time by maximizing velocity in the direction of the target. That's probably better, because it's more general. Once you've decided a speed or angle, you can find angle or speed via math that's ... just demonstrated here - I can't find where I have the source code for that, what was I thinking ? If you need help with that math I can help tho.

Show more comments

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by zigtrig-troy · May 17 at 08:04 PM

@Morphus74 I will answer the question asked in the title. I don't really understand what you wrote after that.

Suppose the projectile is a point mass and there is no air resistance. Suppose you know the total distance the projectile will travel before hitting the ground (assuming the ground is flat), and call that R (for range). Suppose you know the maximum height the projectile ever gets above the ground, and call that H. Then, if the angle between the ground and the initial direction of motion is theta, then theta = arctan(4 H/R). And if the initial speed of the projectile is v, then v = sqrt( g R / s) where s = sin( 2 theta ).

Comment
Add comment · Show 2 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Morphus74 · May 17 at 08:07 PM 0
Share

Thank for answer...

Issue is that I don't know the final height... only criteria I have is - Total Distance - Angle between x and y degree - Velocity between x and y unit/second

So the question is how to you find an Angle/Velocity in the range allowed that allow to reach the final distance.

For example What is the best Angle/Velocity if 1. Target is at 200 unit 2. Angle must be between 20-60 Degrees 3. Velocity is between 10-50 unit per second

avatar image zigtrig-troy · May 17 at 08:16 PM 0
Share

The range R, the initial speed v, and the initial angle theta are related by the equation R = (v^2) (sin(2 theta)) / g, where g is the acceleration due to gravity (9.8 m/s^2). Therefore if you know R and theta, you can calculate v. Or if you know R and v, you can calculate theta. (Just do some algebra/trigonometry to rearrange that R = ... equation.)

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

226 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Calculating trajectory of elliptical orbit? 2 Answers

Calculate Initial Velocity to Reach Destination Based Off Time 1 Answer

Calculate jump velocity given horizontal distance and speed 2 Answers

Is there any Math I'm missing for this project I'm working on? 0 Answers

Reflection Angle - Change objects rotation 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges