Square Box of an Isometric / Formula to Calculate Proper Scale

Hello,

I've had this problem for a long time, but never really cared to deal with it. I know it's all math, but I was hoping someone has run across this, or would be able to put something together for me quickly.

Basically, I'm auto-generating drawing with Driveworks, and one of my views is an isometric view, I would like it to fit nicely into a pre-defined square area (maybe 3" x 4"). For that we would change the scale of course...but I'm after a formula, that will calculate me the proper scale that will make that specific isometric view fit perfectly in that 3" x 4" frame.

I know how to get the square box of my assembly (with all 8 points in space)...through API...but I haven't seen anything that will give me a square box of the actual isometric view. If I could find a way of getting the square box of the isometric view...that would be fantastic!

I would be greatly appreciated if anyone could help with this.

Cheers

Filipe

SolidworksGeneral
Answers 10
FV
FV 2010-12-08 Best Answer

BumpadiBump....anyone?

DG
DG 2010-12-09

Use this formula

New Scale = (New Height/Existing Height) * Existing Scale

FV
FV 2010-12-09

Hi Deepak, thanks for your suggestion.

I don't think I explained well enough.

That is the correct formula for calculating the scale assuming I know the height, which is the problem I have right now.

Since my view is in isometric, I need a formula that will get me that projected height/width of the view while the model is in isometric (based on the actual dimensions of the model)...

I can think of one way, how this would work...(through API).

1st I would get the views' width/height and current scale

2nd I would formulate with those values a new scale for that same view to fit in an "imaginary frame" as the boundaries of the view on the drawing

I would like to avoid having to make a macro for this though, as I would like to embed it into my driveworks rules (which can't access view widths or anything that comes after the model being generated). I'm basically looking for a mathematical formula that will get me the width/height of the view based on the actual box size of the model.

Here, you see my assembly in isometric view with the box limits (in grey), and what I'm trying to achieve is the red line...

Basically, I want to make sure this view...no matter what size the assembly takes, will always fit within the space on my fabrication drawing sheet...

Sorry if I make it sound more confusing than it really is...but I think with these pictures, the idea is better transmitted.

Filipe

comment imagecomment imagecomment imagecomment image
SF
SF 2010-12-09

Filipe,

Call the horizontal width of your iso view H. Call the vertical height of  your iso view V. Call the width of your bounding box between the rails X. Call the width of your bounding box along the rails Y. Call the height of your bounding box Z. The angle, 30 degrees, between the X bounding box edge and horizontal is equal to the angle between the Y bounding box edge and horizontal. Call the scale of your iso view S. Then:

H=S*(X*cos(30)+Y*cos(30))

V=S*(X*sin(30)+y*sin(30)+Z)

If your maximum allowable H is Hmax and your maximum allowable V is Vmax, calcuate your scale based on the maximum width and height:

Sh=Hmax/(X*cos(30)+Y*cos(30))

Sv=Vmax/(X*sin(30)+Y*sin(30)+Z)

The required scale is the smaller of Sh and Sv.

Jerry Steiger

FV
FV 2010-12-09

Perfect!!! Thank you so much Jerry!

This is exactly what I was looking for...

I can't thank you enough, nice formula! 

Regards,

Filipe

SF
SF 2010-12-09

Filipe,

You're welcome! I would have answered when you first posted, but I thought you were asking how to fit the actual isometric view, not the isometric bounding box.

The calculations only work if it is truly an insometric view. You would have to change the angles for dimetric and trimetric views.

Jerry Steiger

FV
FV 2010-12-09

Jerry,

I understand the trig behind it... I just wasn't 100% sure if of the angular layout of the isometric.

I have one question though....in this formula:

Sv=Vmax/(X*sin(30)+Y*sin(30)+Z)

is Z not projected as well?

Edit: I guess not...since it is normal to the view (or on a parallel plane)...right?

Thank you once again.

DG
DG 2010-12-10

Cool, thanks for sharing it Jerry

Filipe, will it be good to share the final DWX formula

FV
FV 2010-12-10

Hey Jerry,

So I've been working with this and trying to understand this a little better.

I was testing out your formulas and the values wouldn't add up...so I decided to look into this a little deeper...

I noticed you are calculating everything based on the bound box dimensions, but on the isometric, the dimensions are projected as well...first you need to get the projected dimension...

The formula for the angle of projection would be: atan(sin(45)) which is approx. 35.264 degrees this is essentially the angular dimension between the "isometric plane" and the xy/xz/zy planes. I can illustrate further on this if you are interested.

In conclusion, the final formulas would be written like so:

<p>Pa = atan(sin(45))</p><p></p><p>Px = X * cos(Pa)</p><p>Py = Y * cos(Pa)</p><pre ___default_attr="plain" jivemacro="code"><p>Pz = Z * cos(Pa)</p>

Sh = Hmax / ( Px * cos(30) + Py * cos(30) )

Sv = Vmax / ( Px * sin(30) + Py * sin(30) + Pz )

I really appreciate your help, I feel I've learnt a lot about isometric views and projecting them. This was a good mental exercise!

Attached is an assembly...that may or may not help you understand the concept. I say maybe not...just because I've been known for doing things the most complicated way, and my logic may not be very easy to follow.

Cheers, and thanks once again!

SF
SF 2010-12-12

Filipe,

You're right, I'm wrong!

I'm not sure that your final equations are correct, but they are definitely better than mine, and they seem to be right on a quick perusal.

Isn't this a great place to learn?

Jerry Steiger