I need help in using if statement

I need help in using if statement

Anonymous
Not applicable
1,539 Views
14 Replies
Message 1 of 15

I need help in using if statement

Anonymous
Not applicable

Hi everyone

 

I'm student doing master degree in BIM

 

just i want to know how to control the floors area. for example: I don't want the second floor area to be more than 50% of the first floor area.

 

could anybody help me with this.

0 Likes
1,540 Views
14 Replies
Replies (14)
Message 2 of 15

JasonLLINDNER
Advocate
Advocate
How do you want or what do you expect Revit to do if say the second floor area is 70% of the first?

I hope you are not expecting Revit to Remodel the 2 floor on it's own because it won't

0 Likes
Message 3 of 15

Anonymous
Not applicable
Hi Jason

I mean putting restrictions for the designer not to exceed the maximum area which is 50% of the first floor area.
0 Likes
Message 4 of 15

JasonLLINDNER
Advocate
Advocate
So an area schedule with a yes/no calculated value = if (Area2>0.5*Area1, 2>1, 2<1)

To check a box and uncheck in a schedule or add conditional formatting to color the cells

Is that what u mean
0 Likes
Message 5 of 15

Keith_Wilkinson
Advisor
Advisor

Revit doesn't work like that - you can model things where you want, add rooms etc, produce area plans and Revit will report all that data for you in the form of a schedule.

 

As @JasonLLINDNER has said you can add a calculated value into a schedule to tell you if one area is bigger than another but that's about it.


Out of curiosity and for some clarity, what floor areas are you talking about - rooms, nett, gross?



"Give a man a fish and you feed him for a day; teach a man to fish and you feed him for a lifetime."
Maimonides
0 Likes
Message 6 of 15

Anonymous
Not applicable
I mean the total floor area includes all the rooms.

What about revit dynamo? Can we do it with it?

0 Likes
Message 7 of 15

Alfredo_Medina
Mentor
Mentor

Even though this is very unusual, there are ways to do it. If you have Revit 2017, you could use the new global parameters to indicate the width and length of a floor. Then, for the floor of the second floor, you could specify that the length and width must be half of the length and width of the first floor, using formulas in parameters. That would do the job. Of course this gets difficult if the shape of the floor is not a simple shape. 

 

If you have Revit 2016 or older, you would need to do this with a mass family, with parameters that establish that relation of 2nd floor being half of the 1st floor, then load the mass family into the project, and then create mass floors from the mass, then create floors from the mass floors. 




Alfredo Medina _________________________________________________________________ ______
Licensed Architect (Florida) | Freelance Instructor | Profile on Linkedin
0 Likes
Message 8 of 15

RDAOU
Mentor
Mentor

 

@Anonymous

 

You cannot place restrictions which will prevent the designer from modeling or designing a bigger floor area!!! The only Thing you can do is report it as suggested above, a scheduled calc. value or some sort of conditional formating...

 

You can use Dynamo to a certain extent (Such as generating a 3D graphical/geometrical representation chart) but it is really nothing Close to what you have in mind...it still won't prevent the designer from exceeding that floor area and/or modeling extra geometries...what sort of designer is this? you tell him Area shouldn't exceed X and he provides 2x X

 

I am not sure what Alfredo is suggesting...but it is worth noting that the Overall length and Width of a floor doesn't Warrant the desired % or Ratio ...well unless your layout is a square or a rectangle. Even then, how would one restrict the designer to those boundaries!!! Even with formulas, scripts and macros there is no way to restrict the designer from doing whatever and wherever!!!

 

 PS: you should have Global Param in 2016 past R2 UPD4

YOUTUBE | BIM | COMPUTATIONAL DESIGN | PARAMETRIC DESIGN | GENERATIVE DESIGN | VISUAL PROGRAMMING
If you find this reply helpful kindly hit the LIKE BUTTON and if applicable please ACCEPT AS SOLUTION


0 Likes
Message 9 of 15

ToanDN
Consultant
Consultant

@Anonymous wrote:
I mean the total floor area includes all the rooms.

What about revit dynamo? Can we do it with it?


The most you can do is get a visual warning when the sum are of the second floor is more than 1/2 that of the first floor.  This can be done via a schedule (or two schedules side by side) that shows the sum area for each floor.  You can even create a calculated value to divide the sum area of the first floor area in half just in case some designer is really thick and incapable do a simple math.  Format the schedule with big text and instruction to clarify the intent and make it the startup view of your project.  Every time one opens the project the information is right on his face so that he cannot miss it.

 

Speaking of Dynamo.  Theoretically if you use Area and Area plan to calculate floor area, you can harvest the area value of one floor and assign it to a shared parameter in the project.  Create a special Area tag for the second floor referencing this shared parameter along with the actual Area.  When you tag the second floor with this special tag, it will show the two values so that a designer can compare them and make adjustment to the design.

 

 

 

 

0 Likes
Message 10 of 15

Seychellian
Advocate
Advocate

I was hoping that someone to assist me with a formula.....

 

I am unable to set a visibility parameter to a void which I would like to control its cutting properties from the project environment. So instead I have set a length parameter to it so that when the length is set to 0 it will cut the object and  when set to anything over 250 it misses the object (anything in-between and it half cuts the object).

 

This works however, when I load the family into the project I would like the parameter to be a visibility parameter as setting a value to the length parameter is not intuitive at all. 

 

Is it possible to there set up a formula that says IF the visibility paramater is "on" the length parameter should be 0 and if it is off it should be 250? I have no idea how I would format that.

 

Thanks!

0 Likes
Message 11 of 15

ToanDN
Consultant
Consultant
Yes it can be done:

- create a Yes/No parameter and name it Cut
- create a Length to control the length of the Void and name it Void Length.
- enter formula for Void length: if (Cut, 250, 1) - meaning if the Cut box is checked, the void will be 250 mm long, enough to and cut the host; if the Cut box is unchecked, the void is only 1 mm long, too short to cut anything (you cannot use 0 for void length).


Message 12 of 15

Seychellian
Advocate
Advocate
Thanks for this. I will try it out when I am back in the office. Could you possibly just explain the logic of that formula. What is Revit formulating when it reads (Cut, 250, 1)?
0 Likes
Message 13 of 15

ToanDN
Consultant
Consultant
The syntax is: if( Y/N parameter, value 1, value 2) The meaning: if the Y/N parameter is true then use value 1, if not then use value 2. https://www.revitforum.org/tutorials-tips-tricks/1046-revit-formulas-everyday-usage.html
0 Likes
Message 14 of 15

Keith_Wilkinson
Advisor
Advisor

If you are looking to learn about Revit forumlas the best place to start, IMO, is here;

 

https://www.revitforum.org/tutorials-tips-tricks/1046-revit-formulas-everyday-usage.html

 

Enjoy.



"Give a man a fish and you feed him for a day; teach a man to fish and you feed him for a lifetime."
Maimonides
0 Likes
Message 15 of 15

Seychellian
Advocate
Advocate

Thanks it worked 🙂

 

I feel stupid  using Revit. So much of this stuff isn't intuitive to me. 

0 Likes