• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EST 12:37
CET 18:37
KST 02:37
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
RSL Revival - 2025 Season Finals Preview8RSL Season 3 - Playoffs Preview0RSL Season 3 - RO16 Groups C & D Preview0RSL Season 3 - RO16 Groups A & B Preview2TL.net Map Contest #21: Winners12
Community News
ComeBackTV's documentary on Byun's Career !8Weekly Cups (Dec 8-14): MaxPax, Clem, Cure win4Weekly Cups (Dec 1-7): Clem doubles, Solar gets over the hump1Weekly Cups (Nov 24-30): MaxPax, Clem, herO win2BGE Stara Zagora 2026 announced15
StarCraft 2
General
When will we find out if there are more tournament ComeBackTV's documentary on Byun's Career ! Weekly Cups (Dec 8-14): MaxPax, Clem, Cure win RSL Revival - 2025 Season Finals Preview Weekly Cups (Dec 1-7): Clem doubles, Solar gets over the hump
Tourneys
$5,000+ WardiTV 2025 Championship RSL Offline Finals Info - Dec 13 and 14! Master Swan Open (Global Bronze-Master 2) Winter Warp Gate Amateur Showdown #1: Sparkling Tuna Cup - Weekly Open Tournament
Strategy
Custom Maps
Map Editor closed ?
External Content
Mutation # 504 Retribution Mutation # 503 Fowl Play Mutation # 502 Negative Reinforcement Mutation # 501 Price of Progress
Brood War
General
BGH Auto Balance -> http://bghmmr.eu/ FlaSh on: Biggest Problem With SnOw's Playstyle How Rain Became ProGamer in Just 3 Months screp: Command line app to parse SC rep files [BSL21] RO8 Bracket & Prediction Contest
Tourneys
Small VOD Thread 2.0 [Megathread] Daily Proleagues [BSL21] WB SEMIFINALS - Saturday 21:00 CET [BSL21] RO8 - Day 2 - Sunday 21:00 CET
Strategy
Game Theory for Starcraft Current Meta Simple Questions, Simple Answers Fighting Spirit mining rates
Other Games
General Games
PC Games Sales Thread Stormgate/Frost Giant Megathread Nintendo Switch Thread Path of Exile General RTS Discussion Thread
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Deck construction bug Heroes of StarCraft mini-set
TL Mafia
Mafia Game Mode Feedback/Ideas Survivor II: The Amazon Sengoku Mafia TL Mafia Community Thread
Community
General
US Politics Mega-thread Russo-Ukrainian War Thread Things Aren’t Peaceful in Palestine The Games Industry And ATVI YouTube Thread
Fan Clubs
White-Ra Fan Club
Media & Entertainment
Anime Discussion Thread [Manga] One Piece Movie Discussion!
Sports
2024 - 2026 Football Thread Formula 1 Discussion
World Cup 2022
Tech Support
Computer Build, Upgrade & Buying Resource Thread
TL Community
TL+ Announced Where to ask questions and add stream?
Blogs
The (Hidden) Drug Problem in…
TrAiDoS
I decided to write a webnov…
DjKniteX
James Bond movies ranking - pa…
Topin
Thanks for the RSL
Hildegard
Customize Sidebar...

Website Feedback

Closed Threads



Active: 1949 users

MATLAB experts needed

Blogs > clazziquai
Post a Reply
clazziquai
Profile Blog Joined October 2007
6685 Posts
Last Edited: 2008-10-27 15:08:46
October 27 2008 02:19 GMT
#1
Ok so I basically finished the problem set with the exception of the last two questions, aka the hardest ones TT

#1 Sea.Really Fan / #1 Nesh Fan / Terran Forever~
micronesia
Profile Blog Joined July 2006
United States24746 Posts
Last Edited: 2008-10-27 02:26:43
October 27 2008 02:25 GMT
#2
1: The outer loop cycles through each of the members of the matrix. The inner loop compares the member highlighted currently by the outer loop in each direction, with the condition that it only does it if the direction is on the matrix (like you can't look up from the top row).

2:
x=0
counter=0
While (x<.8 and x>.85)
{
<x=rand(1)>
If x>.8 or x<.85 then counter++
}
Report

I don't know the exact syntax, but something like that?

edit: for 2 be careful of if they are considering .8 and .85 as valid answers or not (inclusive or exclusive conditions?)
ModeratorThere are animal crackers for people and there are people crackers for animals.
Darth_Ihsahn
Profile Joined June 2007
Mexico138 Posts
Last Edited: 2008-10-27 02:52:41
October 27 2008 02:51 GMT
#3
If x>.8 or x<.85 then counter++

Isn't necessary (Actually it's wrong). Just counter++
What does not kill you makes you stronger.
overpool
Profile Joined April 2008
United States191 Posts
Last Edited: 2008-10-27 03:09:15
October 27 2008 03:08 GMT
#4
On October 27 2008 11:25 micronesia wrote:
1: The outer loop cycles through each of the members of the matrix. The inner loop compares the member highlighted currently by the outer loop in each direction, with the condition that it only does it if the direction is on the matrix (like you can't look up from the top row).

Good answer, but it's easier to just choose two arbitrary directions to compare in (like right and down), and then only test (length-1) rows and (height-1) columns. (Note: I've never used MATLAB so I'm making assumptions about its capabilities.)
yay i love tl events
JDPingpong
Profile Joined June 2008
United States57 Posts
Last Edited: 2008-10-30 18:30:11
October 27 2008 05:29 GMT
#5
here is the correct syntax for the 2nd question.


*edit*

The | symbol in the while statement means or.
clazziquai
Profile Blog Joined October 2007
6685 Posts
Last Edited: 2008-10-27 21:05:30
October 27 2008 06:49 GMT
#6

How about #1 anyone? That one is still weird I can't get anything to work -_-
#1 Sea.Really Fan / #1 Nesh Fan / Terran Forever~
clazziquai
Profile Blog Joined October 2007
6685 Posts
Last Edited: 2008-10-27 15:09:07
October 27 2008 07:14 GMT
#7
thanks!
#1 Sea.Really Fan / #1 Nesh Fan / Terran Forever~
JDPingpong
Profile Joined June 2008
United States57 Posts
Last Edited: 2008-10-30 18:30:34
October 27 2008 14:38 GMT
#8
Its pretty crude, but it gets the job done.

*edit*

This is a great problem when starting out with MATLAB. It teaches you how to index stuff. When doing the for loop, you need to store each value of the tuition into cell of a matrix. I don't have much time to explain, i'm on class break, but take a look over it and see if you can get comfortable with the indexing in the for loop. Its a skill you have to have when using MATLAB. If you are confused anywhere, just ask. I'll check this thread. As for problem 1 in the OP, i'll take a look at it later tonight. It'll take a little more time to figure out, but i think i can help.
Chromyne
Profile Joined January 2008
Canada561 Posts
October 27 2008 18:42 GMT
#9
On October 27 2008 11:19 clazziquai wrote:
Ok so I basically finished the problem set with the exception of the last two questions, aka the hardest ones TT


That's unfortunate, I would have helped but I had to do a pre-lab and study for a midterm. Hope it' doesn't mar your grade too much.
Soli Deo gloria.
Raithed
Profile Blog Joined May 2007
China7078 Posts
October 27 2008 18:48 GMT
#10
haha.
clazziquai
Profile Blog Joined October 2007
6685 Posts
October 27 2008 20:57 GMT
#11
On October 28 2008 03:42 Chromyne wrote:
Show nested quote +
On October 27 2008 11:19 clazziquai wrote:
Ok so I basically finished the problem set with the exception of the last two questions, aka the hardest ones TT


That's unfortunate, I would have helped but I had to do a pre-lab and study for a midterm. Hope it' doesn't mar your grade too much.


The whole assignment is out of 1 point, so it's not that big of a deal :D
#1 Sea.Really Fan / #1 Nesh Fan / Terran Forever~
Please log in or register to reply.
Live Events Refresh
Big Brain Bouts
17:00
#102
YoungYakov vs Jumy
TriGGeR vs Spirit
IndyStarCraft 726
RotterdaM537
Liquipedia
OSC
14:00
King of the Hill #234
SteadfastSC94
Liquipedia
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
IndyStarCraft 726
RotterdaM 537
Lowko522
SteadfastSC 94
Liquid`VortiX 87
BRAT_OK 47
MindelVK 23
DivinesiaTV 11
StarCraft: Brood War
Britney 24057
Rain 1978
Bisu 1964
Stork 518
Horang2 479
Shuttle 356
Larva 135
Mini 124
firebathero 118
Hyun 100
[ Show more ]
Aegong 69
Mind 59
Zeus 58
Killer 53
JYJ 50
910 49
ggaemo 46
Dewaltoss 39
Mong 36
Shinee 22
soO 18
JulyZerg 17
GoRush 15
sorry 15
ajuk12(nOOB) 11
Sacsri 11
SilentControl 8
Dota 2
Gorgc6412
singsing4032
qojqva3390
Counter-Strike
Foxcn96
Other Games
FrodaN775
hiko529
crisheroes353
XaKoH 127
KnowMe97
Trikslyr66
Chillindude31
Organizations
StarCraft 2
ComeBackTV 681
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 14 non-featured ]
StarCraft 2
• poizon28 21
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
Dota 2
• lizZardDota240
League of Legends
• Nemesis3394
Other Games
• tFFMrPink 1
Upcoming Events
The PiG Daily
3h 24m
SHIN vs ByuN
Reynor vs Classic
TBD vs herO
Maru vs SHIN
TBD vs Classic
CranKy Ducklings
16h 24m
WardiTV 2025
17h 24m
Reynor vs MaxPax
SHIN vs TBD
Solar vs herO
Classic vs TBD
SC Evo League
18h 54m
Ladder Legends
1d 1h
BSL 21
1d 2h
Sziky vs Dewalt
eOnzErG vs Cross
Sparkling Tuna Cup
1d 16h
Ladder Legends
1d 23h
BSL 21
2 days
StRyKeR vs TBD
Bonyth vs TBD
Replay Cast
2 days
[ Show More ]
Wardi Open
2 days
Monday Night Weeklies
2 days
WardiTV Invitational
4 days
Replay Cast
5 days
WardiTV Invitational
5 days
ByuN vs Solar
Clem vs Classic
Cure vs herO
Reynor vs MaxPax
Liquipedia Results

Completed

Acropolis #4 - TS3
RSL Offline Finals
Kuram Kup

Ongoing

C-Race Season 1
IPSL Winter 2025-26
KCM Race Survival 2025 Season 4
YSL S2
BSL Season 21
Slon Tour Season 2
CSL Season 19: Qualifier 1
WardiTV 2025
META Madness #9
eXTREMESLAND 2025
SL Budapest Major 2025
ESL Impact League Season 8
BLAST Rivals Fall 2025
IEM Chengdu 2025
PGL Masters Bucharest 2025
Thunderpick World Champ.
CS Asia Championships 2025
ESL Pro League S22

Upcoming

CSL Season 19: Qualifier 2
CSL 2025 WINTER (S19)
BSL 21 Non-Korean Championship
Acropolis #4
IPSL Spring 2026
Bellum Gens Elite Stara Zagora 2026
HSC XXVIII
Big Gabe Cup #3
OSC Championship Season 13
ESL Pro League Season 23
PGL Cluj-Napoca 2026
IEM Kraków 2026
BLAST Bounty Winter 2026
BLAST Bounty Winter Qual
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2025 TLnet. All Rights Reserved.