How to autoscale a shape?
|
12-30-2014, 03:21 PM
(This post was last modified: 12-30-2014 03:22 PM by Han.)
Post: #2
|
|||
|
|||
RE: How to autoscale a shape?
(12-30-2014 01:48 PM)Giancarlo Wrote: Hello, The HP Prime's screen is 320:240 = 4:3. Suppose your X values are in \( [a,b] \) and your Y values are in \( [c,d] \). You can either keep the X-range at \( [a,b] \) and then scale the Y-range to \[ \left[ \frac{c+d}{2}- \frac{1}{2}\left( \frac{3}{4}(b-a)\right), \frac{c+d}{2}+ \frac{1}{2}\left( \frac{3}{4}(b-a)\right) \right]. \] Or you can keep the Y-range at \( [c,d] \) and scale the X-range \[ \left[ \frac{a+b}{2}- \frac{1}{2}\left( \frac{4}{3}(d-c)\right), \frac{a+b}{2}+ \frac{1}{2}\left( \frac{4}{3}(d-c)\right) \right]. \] I purposely left the math unsimplified so you can check the derivation yourself. The decision as to which axis to scale can be made by determining whether \( \frac{3}{4}(b-a) > (d-c) \). That way, you will maintain the 4:3 ratio and ensure that all points are displayed. Graph 3D | QPI | SolveSys |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
How to autoscale a shape? - Giancarlo - 12-30-2014, 01:48 PM
RE: How to autoscale a shape? - Han - 12-30-2014 03:21 PM
RE: How to autoscale a shape? - Giancarlo - 12-30-2014, 06:34 PM
|
User(s) browsing this thread: 1 Guest(s)